问题
I trying to install in debian nodejs
, I am following these steps how-to-install-node-js-on-ubuntu but when I run sudo bash nodesource_setup.sh
the errors below showed for me, anyone help me to solve it ?
W: The repository 'http://ppa.launchpad.net/ubuntu-x-swat/x-updates/ubuntu maverick Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: The repository 'http://ppa.launchpad.net/videolan/stable-daily/ubuntu artful Release' does not have a Release file.
N: Data from such a repository can't be authenticated and is therefore potentially dangerous to use.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: Falhou ao buscar http://ppa.launchpad.net/ubuntu-x-swat/x-updates/ubuntu/dists/maverick/main/binary-amd64/Packages 403 Forbidden
E: Falhou ao buscar http://ppa.launchpad.net/videolan/stable-daily/ubuntu/dists/artful/main/binary-amd64/Packages 404 Not Found
E: Falhou o download de alguns ficheiros de índice. Foram ignorados ou os antigos foram usados em seu lugar.
Error executing command, exiting
回答1:
This is not related to NodeJS's package in any way.
The real issue is stated:
The repository basically_all_your_repos does not have a Release file.
Your ppa entries are corrupted. Delete all ppa entries which throw errors and then run apt-get update
. I'm guessing the installation fails at the beginning, when (sudo) apt-get update is issued. You can check out how to remove ppas here.
回答2:
Try to use NVM to install node js and it helps to checkout different node versions in the same machine for different project.
Check this answer. I clearly listed the commands on how to install node js with NVM on linux.
回答3:
Using Software & Updates Application From https://stackoverflow.com/a/41253291/11032592
- Open the Software Updates application;
- In "Other Software" tab unmark all options;
- In Ubuntu Software tab, "Download from:" choose "Main server" option.
- Click in "Close" button and wait a minute until ubuntu reload apt-get.
- Open terminal --> sudo apt-get clean all
- Open terminal --> sudo apt-get update Done.
来源:https://stackoverflow.com/questions/47251703/error-during-install-node-js-in-debian