无法安装 acroread — ‘dpkg 返回错误代码 (1)’

无法安装 acroread — ‘dpkg 返回错误代码 (1)’

运行后sudo apt-get install acroread,我得到以下输出

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Suggested packages:
  libldap2 libgnome-speech7
The following NEW packages will be installed:
  acroread
0 upgraded, 1 newly installed, 0 to remove and 6 not upgraded.
1 not fully installed or removed.
Need to get 0 B/60.1 MB of archives.
After this operation, 142 MB of additional disk space will be used.
(Reading database ... 237901 files and directories currently installed.)
Unpacking acroread (from .../acroread_9.5.1-1precise1_i386.deb) ...
dpkg: error processing /var/cache/apt/archives/acroread_9.5.1-1precise1_i386.deb (--unpack):
 failed in write on buffer copy for backend dpkg-deb during `./opt/Adobe/Reader9/Browser/intellinux/nppdf.so': No space left on device
No apport report written because MaxReports is reached already
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Processing triggers for bamfdaemon ...
Rebuilding /usr/share/applications/bamf.index...
Processing triggers for desktop-file-utils ...
Processing triggers for gnome-menus ...
Processing triggers for man-db ...
/usr/bin/mandb: can't write to /var/cache/man/1645: No space left on device
Errors were encountered while processing:
 /var/cache/apt/archives/acroread_9.5.1-1precise1_i386.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

答案1

似乎你的空间不够了,要检查你的硬盘,只需运行:

df -h

如果此命令告诉您使用%大约是 99% 左右,使用以下命令进行清理:

apt-get clean && apt-get autoclean

您也可以尝试使用以下命令从系统中删除不需要的软件包:

deborphan | xargs aptitude --purge remove

运行这些命令后,尝试acroread再次安装,就应该没问题了。

答案2

重要的一行是:

/usr/bin/mandb: can't write to /var/cache/man/1645: No space left on device

目录所在的分区/var已没有剩余空间。您可以尝试删除一些不必要的文件。有时目录/var/cache/apt/archives包含大量不需要的包文件。请检查是否可以删除一些文件/var并重试。

相关内容