nodejs-legacy无法安装

时间:2015-12-11 21:07:00

标签: node.js ubuntu-14.04

我正在尝试在ubuntu中安装nodejs-legacy但是它提供了错误。请帮助。 我还从所有来源删除了nodejs留下的所有痕迹 在本地system.i也做了: sudo apt-get install autoclean sudo apt-get install nodejs-legacy

不起作用

请建议

The following NEW packages will be installed:
  nodejs-legacy
0 upgraded, 1 newly installed, 0 to remove and 9 not upgraded.
Need to get 14.6 kB of archives.
After this operation, 122 kB of additional disk space will be used.
Get:1 http://in.archive.ubuntu.com/ubuntu/ trusty/universe nodejs-legacy all 0.10.25~dfsg2-2ubuntu1 [14.6 kB]
Fetched 14.6 kB in 0s (18.4 kB/s)      
(Reading database ... 261633 files and directories currently installed.)
Preparing to unpack .../nodejs-legacy_0.10.25~dfsg2-2ubuntu1_all.deb ...
Unpacking nodejs-legacy (0.10.25~dfsg2-2ubuntu1) ...
dpkg: error processing archive /var/cache/apt/archives/nodejs-legacy_0.10.25~dfsg2-2ubuntu1_all.deb (--unpack):
 trying to overwrite '/usr/share/man/man1/node.1.gz', which is also in package nodejs 0.10.37-1chl1~trusty1
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Errors were encountered while processing:
 /var/cache/apt/archives/nodejs-legacy_0.10.25~dfsg2-2ubuntu1_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
manish@manish-Lenovo-IdeaPad-Z510:/var/cache/apt/archives$ whereis nodejs
nodejs:
manish@manish-Lenovo-IdeaPad-Z510:/var/cache/apt/archives$ which nodejs
manish@manish-Lenovo-IdeaPad-Z510:/var/cache/apt/archives$ 

3 个答案:

答案 0 :(得分:2)

sudo dpkg -i /var/cache/apt/archives/nodejs-legacy_0.10.25〜dfsg2-2ubuntu1_all.deb

答案 1 :(得分:1)

通过强制覆盖这些命令为我工作。

mv music/artist/arai/blue.ogg music/artist/arai/music.ogg

答案 2 :(得分:0)

似乎有一个已安装的软件包nodejs,其中有一些文件与node-legacy软件包重叠。

您是否尝试先卸载nodejs软件包?