LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Unable to install nodejs on a fresh installation (https://www.linuxquestions.org/questions/linux-newbie-8/unable-to-install-nodejs-on-a-fresh-installation-4175655000/)

grumpy_nl 06-02-2019 07:32 AM

Unable to install nodejs on a fresh installation
 
Nothing else is installed yet, this the fourth installation im trying in 6 days.

Installation amd64 from usb is no problem, all install well.
Start terminal
su

then, keep getting keyring errors
+ curl -sLf -o /dev/null 'https://deb.nodesource.com/node_12.x/dists/stretch/Release'

## Adding the NodeSource signing key to your keyring...

+ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add -
gpg: [don't know]: invalid packet (ctb=0a)
gpg: keydb_get_keyblock failed: Value not found
gpg: [don't know]: invalid packet (ctb=0a)
gpg: /tmp/apt-key-gpghome.dF3IXWpkgB/pubring.gpg: copy to '/tmp/apt-key-gpghome.dF3IXWpkgB/pubring.gpg.tmp' failed: Invalid packet
gpg: error writing keyring '/tmp/apt-key-gpghome.dF3IXWpkgB/pubring.gpg': Invalid packet
gpg: [don't know]: invalid packet (ctb=0a)
gpg: error reading '-': Invalid packet
gpg: import from '-' failed: Invalid packet
Error executing command, exiting

What to do, 6 days spending on a install is a bit much, not one time yet running without problems.

hydrurga 06-02-2019 08:33 AM

Hi grumpy_nl, and welcome to LQ.

Which distro (and version) are you running?

smallpond 06-02-2019 09:07 AM

Did you configure GPG?

https://wooledge.org/~greg/crypto/node41.html

grumpy_nl 06-02-2019 01:07 PM

Quote:

Originally Posted by hydrurga (Post 6001263)
Hi grumpy_nl, and welcome to LQ.

Which distro (and version) are you running?


https://cdimage.debian.org/debian-cd...64-netinst.iso

grumpy_nl 06-02-2019 01:11 PM

Quote:

Originally Posted by smallpond (Post 6001274)

Trying this now.

grumpy_nl 06-02-2019 01:22 PM

Quote:

Originally Posted by grumpy_nl (Post 6001321)
Trying this now.


Same result after that installation
sudo apt-get update
sudo apt-get -y install curl dirmngr apt-transport-https lsb-release ca-certificates vim
curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -




+ curl -sLf -o /dev/null 'https://deb.nodesource.com/node_12.x/dists/stretch/Release'

## Adding the NodeSource signing key to your keyring...

+ curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add -
gpg: [don't know]: invalid packet (ctb=0a)
gpg: keydb_get_keyblock failed: Value not found
gpg: [don't know]: invalid packet (ctb=0a)
gpg: /tmp/apt-key-gpghome.5lrwTh1rhc/pubring.gpg: copy to '/tmp/apt-key-gpghome.5lrwTh1rhc/pubring.gpg.tmp' failed: Invalid packet
gpg: error writing keyring '/tmp/apt-key-gpghome.5lrwTh1rhc/pubring.gpg': Invalid packet
gpg: [don't know]: invalid packet (ctb=0a)
gpg: error reading '-': Invalid packet
gpg: import from '-' failed: Invalid packet
Error executing command, exiting

Contrapak 06-02-2019 01:36 PM

Why don't you install Node using the distro's package manager?

grumpy_nl 06-02-2019 01:46 PM

Quote:

Originally Posted by Contrapak (Post 6001330)
Why don't you install Node using the distro's package manager?

Because everyweher i look and google it says
# Using Debian, as root
curl -sL https://deb.nodesource.com/setup_12.x | bash -
apt-get install -y nodejs

Furthermore, i havn't installed anything else except for sudo and curl

Contrapak 06-02-2019 03:24 PM

Maybe this video might help.

grumpy_nl 06-02-2019 03:42 PM

Quote:

Originally Posted by Contrapak (Post 6001352)
Maybe this video might help.

Followed it and same keyring problem.

grumpy_nl 06-02-2019 05:33 PM

This solved it
 
cd /etc/apt
sudo mv trusted.gpg trusted.gpg.bak

Now i have node11 installed

hydrurga 06-02-2019 05:56 PM

Great to hear. If you want, you can mark the thread as "Solved" (see "Thread Tools" at the top of the thread).

Contrapak 06-02-2019 07:38 PM

Quote:

Originally Posted by grumpy_nl (Post 6001376)
cd /etc/apt
sudo mv trusted.gpg trusted.gpg.bak

Now i have node11 installed

Hah! The simplest solutions are the best.


All times are GMT -5. The time now is 10:12 AM.