Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to install nodejs 6.x/8.x for debian jessie #532

Closed
Marksion08 opened this issue Sep 25, 2017 · 33 comments
Closed

Fail to install nodejs 6.x/8.x for debian jessie #532

Marksion08 opened this issue Sep 25, 2017 · 33 comments

Comments

@Marksion08
Copy link

I tried to install nodejs 6.x/8.x for debian 8, after followed many way to, but this problem still.
It showed me as below:

Confirming "jessie" is supported...

Your distribution, identified as "jessie", is not currently supported, please contact NodeSource at https://github.com/nodesource/distributions/issues if you think this is incorrect or would like your distribution to be considered for support

BTW: debian 8 jessie was download from the official-side.

PLS tell me if there was any wrong, I was fresh in Debian.
Thanks & Regards,
Marksion

@wolfflow
Copy link

Got the same thing with wheezy.
Your distribution, identified as "wheezy", is not currently supported, please contact NodeSource at https://github.com/nodesource/distributions/issues if you think this is incorrect or would like your distribution to be considered for support

@rajudev
Copy link

rajudev commented Oct 1, 2017

This issue is affecting me as well for Debian Jessie.
`root@debian-jessie:~# curl -sL https://deb.nodesource.com/setup_8.x | bash -

Installing the NodeSource Node.js v8.x repo...

Populating apt-get cache...

Confirming "n/a" is supported...

Your distribution, identified as "n/a", is not currently supported, please contact NodeSource at https://github.com/nodesource/distributions/issues if you think this is incorrect or would like your distribution to be considered for support

root@debian-jessie:~#
`

@rajudev
Copy link

rajudev commented Oct 1, 2017

Same issues with 7.x or 6.x release

@rajudev
Copy link

rajudev commented Oct 1, 2017

Apparently I have found a solution for this.
Do not use the nodesource script for this. Instead do manually what the script tries to do automatically.

For your particular version of Debian/Ubuntu add the respective line to your sources.list file
release name can be any of these
deb https://deb.nodesource.com/node_8.x/ <release name> main
add the repository key
curl --silent https://deb.nodesource.com/gpgkey/nodesource.gpg.key | sudo apt-key add -
and then do apt update and apt install nodejs

Let me know, if this was helpful to you. Thanks

@ARET-METAL
Copy link

Buenas tardes a mi me presenta el mismo error que a ustedes y no me soluciona lo que recomendaste rajudev

@rajudev
Copy link

rajudev commented Oct 6, 2017

@ARET-METAL Apologies,I don't understand your language. Would be great if you can repeat the message in English.

@ARET-METAL
Copy link

I'm having problems installing taiga in debian jessie in dependencies and nodejs they will have an installation manual, thanks

@ARET-METAL
Copy link

npm -v
ERROR: npm is known not to run on Node.js v0.10.29
You'll need to upgrade to a newer version in order to use this
version of npm. Supported versions are 4, 6, 7, 8. You can find the
latest version at https://nodejs.org/

@rajudev
Copy link

rajudev commented Oct 9, 2017

@ARET-METAL Have you resolved your issue within the last three days? If it is still there I can still help.

@rajudev
Copy link

rajudev commented Oct 9, 2017

@ARET-METAL Since you are already having npm installed, although an older version.
You can just do sudo npm install -g npm to update your current version of npm

@Marksion08
Copy link
Author

@rajudev While tried to added responsitory key the errors showed: "gpg: no valid OpenPGP data found."
Should I need to install something?

@rajudev
Copy link

rajudev commented Oct 10, 2017

@Marksion08 You need add the the keys for the repository.
do curl --silent https://deb.nodesource.com/gpgkey/nodesource.gpg.key | sudo apt-key add -
hopefully this should solve your issue.

@JoSchmutz
Copy link

JoSchmutz commented Oct 10, 2017

Hi,
make sure your machine clock is set at the right time and date. That was the problem for me:
sudo date --set YEAR-MONTH-DATE
When the raspberry boots, the date and time are set to 26 Sept 2016. Which is exactly the date from which issue was raised.
Hope it works for you guys

@krokofant
Copy link

Expanding on @JoSchmutz solution is to make sure that the RPis datetime is updated automatically:
sudo apt-get install ntpdate and restart and try again

@kenshinji
Copy link

Same issue here, I installed nodejs v0.10.29 through sudo apt-get install nodejs after I tried curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -, I was intend to install the latest version though.

@chrislea
Copy link
Contributor

chrislea commented Nov 3, 2017

I think the problem is you're passing the -E flag to sudo and not bash. Can you please try the following:

curl -sL https://deb.nodesource.com/setup_8.x | sudo bash -E -
sudo apt-get install nodejs

and let us know what happens?

@kenshinji
Copy link

@chrislea it doesn't work :(

@chrislea
Copy link
Contributor

chrislea commented Nov 3, 2017

@kenshinji okay can you please run

curl -sL https://deb.nodesource.com/setup_8.x | sudo bash -E -x -

and past the full output here? Thanks.

@JoSchmutz
Copy link

You should run
sudo date --set 17-11-03
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
Then
sudo apt install nodejs

@jo-argon7
Copy link

I've just (re)done the installation on Debian jessie and it does not work !! bad version of node and unable to run npm !!

`***# date
vendredi 3 novembre 2017, 15:44:38 (UTC+0100)
***# apt install nodejs
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances
Lecture des informations d'état... Fait
Les NOUVEAUX paquets suivants seront installés :
nodejs
0 mis à jour, 1 nouvellement installés, 0 à enlever et 0 non mis à jour.
Il est nécessaire de prendre 0 o/12,7 Mo dans les archives.
Après cette opération, 61,0 Mo d'espace disque supplémentaires seront utilisés.
Sélection du paquet nodejs précédemment désélectionné.
(Lecture de la base de données... 36125 fichiers et répertoires déjà installés.)
Préparation du dépaquetage de .../nodejs_8.9.0-1nodesource1_amd64.deb ...
Dépaquetage de nodejs (8.9.0-1nodesource1) ...
Traitement des actions différées (« triggers ») pour man-db (2.7.0.2-5) ...
Paramétrage de nodejs (8.9.0-1nodesource1) ...
***# node -v
v0.6.5
***# npm -v

/usr/lib/node_modules/npm/lib/utils/unsupported.js:27
console.error(`a bug known to break npm. Please update to at least ${r
^

node.js:201
throw e; // process.nextTick error, or 'error' event on first tick
^
SyntaxError: Unexpected token ILLEGAL
at Module._compile (module.js:427:25)
at Object..js (module.js:450:10)
at Module.load (module.js:351:31)
at Function._load (module.js:310:12)
at Module.require (module.js:357:17)
at require (module.js:368:17)
at /usr/lib/node_modules/npm/bin/npm-cli.js:19:21
at Object. (/usr/lib/node_modules/npm/bin/npm-cli.js:92:2)
at Module._compile (module.js:432:26)
at Object..js (module.js:450:10)`

@JoSchmutz
Copy link

@jo-argo7 did you do
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
Before runing apt install nodejs?

@JoSchmutz
Copy link

@jo-argon7 make sure you are on jessie image and not stretch

@jo-argon7
Copy link

jo-argon7 commented Nov 3, 2017

yep, result is in /etc/apt/sources.list.d/nodesource.list
deb https://deb.nodesource.com/node_8.x jessie main
deb-src https://deb.nodesource.com/node_8.x jessie main

@jo-argon7
Copy link

jo-argon7 commented Nov 3, 2017

Debian Jessie confirmed:
# cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 8 (jessie)"
NAME="Debian GNU/Linux"
VERSION_ID="8"
VERSION="8 (jessie)"
ID=debian
HOME_URL="http://www.debian.org/"
SUPPORT_URL="http://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"

@JoSchmutz
Copy link

What do you get with that:

curl -sL https://deb.nodesource.com/setup_7.x | sudo -E bash -

@jo-argon7
Copy link

jo-argon7 commented Nov 3, 2017

I've found another method and it works:
# curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.32.0/install.sh | bash
... open new shell ...
# command -v nvm
... should output "nvm" ...
# nvm install node

and now everything's ok:
# node -v
v9.0.0
# npm -v
5.5.1

@chrislea
Copy link
Contributor

chrislea commented Nov 3, 2017

Again, please run exactly:

curl -sL https://deb.nodesource.com/setup_8.x | sudo bash -E -x -

and paste the full output here. This may help me see what's going on with the installer script.

@jo-argon7
Copy link

output saved in file:
nodesource.installer8.log

@LC43
Copy link

LC43 commented Dec 4, 2017

i'm on debian 9 and had the same "n/a" error :

## Confirming "n/a" is supported...
+ curl -sLf -o /dev/null 'https://deb.nodesource.com/node_8.x/dists/n/a/Release'

## Your distribution, identified as "n/a", is not currently supported, please contact NodeSource at https://github.com/nodesource/distributions/issues if you think this is incorrect or would like your distribution to be considered for support

even tho

$cat /etc/debian_version

9.0

and
$cat /etc/os-release

PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
[..]

so i followed @rajudev advice and added
$cat /etc/apt/sources.list.d/nodesource.list

deb https://deb.nodesource.com/node_8.x jessie main
deb-src https://deb.nodesource.com/node_8.x jessie main

and

curl --silent https://deb.nodesource.com/gpgkey/nodesource.gpg.key | sudo apt-key add -

Did

apt-get update

and finished with

apt-get install nodejs

So now:

$node -v
v8.9.1

@jasompi
Copy link

jasompi commented Dec 24, 2017

This is because the script use lsb_release to determine the codename.

DISTRO=$(lsb_release -c -s)

However, on my Raspbian, lsb_release -c show:
Codename: n/a

I fixed it by download the setup_9.x and manually change the line to:

DISTRO=jessie

@fabpin
Copy link

fabpin commented Sep 16, 2018

Im on debian 8, in Deepin 15.07 64bits and have the same error, when write "npm -v", show thw following issue: bash: npm didn't found the order

@evictor
Copy link

evictor commented Feb 4, 2019

Expanding on @JoSchmutz solution is to make sure that the RPis datetime is updated automatically:
sudo apt-get install ntpdate and restart and try again

This worked for me.

@igsu
Copy link
Contributor

igsu commented Dec 17, 2019

This has ben fixed a while ago.
Closing now.

@igsu igsu closed this as completed Dec 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests