【发布时间】:2021-03-02 03:40:16
【问题描述】:
我正在尝试在我的 Chromebook 上安装节点。运行后:
curl -fsSL https://deb.nodesource.com/setup_14.x | bash -
apt-get install -y nodejs
我收到了这个错误:
## Installing the NodeSource Node.js 14.x repo...
## Populating apt-get cache...
+ apt-get update
Reading package lists... Done
E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied)
E: Unable to lock directory /var/lib/apt/lists/
W: Problem unlinking the file /var/cache/apt/pkgcache.bin - RemoveCaches (13: Permission denied)
W: Problem unlinking the file /var/cache/apt/srcpkgcache.bin - RemoveCaches (13: Permission denied)
Error executing command, exiting
我该怎么做才能纠正他的问题并完成节点的安装?
【问题讨论】:
-
您是否以 root 身份登录?否则尝试使用 sudo apt-get install -y nodejs
-
尝试使用 sudo 执行命令
-
我要感谢杰罗姆。安装 nvm 很顺利,他的 npm install 脚本也能正常工作。没有打嗝。
-
在输入感谢信时,我意识到用户在为 StackOverflow 提供服务的同时如何获得声誉。问一个社区有答案的简单问题,我可以参考我提出的问题作为回答其他人问题的材料。我还可以看到如何维护我自己的功能代码的 GitHub 存储库,这也可以帮助我回答我在这里找到的一些问题。当然还有学习编程语言。它帮助人们创造、学习和使技术更容易获得。这是 StackOverflow。干杯!!...
标签: node.js linux installation