执行 apt-get install samba smbfs 时出现以下错误。我该如何进行故障排除和修复?
Errors were encountered while processing:
samba
E: Sub-process /usr/bin/dpkg returned an error code (1)
The entire output from apt-get is pasted below.
The following NEW packages will be installed
samba smbfs
0 upgraded, 2 newly installed, 0 to remove and 34 not upgraded.
Need to get 1350kB/5645kB of archives.
After this operation, 16.1MB of additional disk space will be used.
Get: 1 http://ftp.uk.debian.org lenny/main smbfs 2:3.2.5-4lenny6 [1350kB]
Fetched 1350kB in 2s (479kB/s)
Preconfiguring packages ...
Selecting previously deselected package samba.
(Reading database ... 108352 files and directories currently installed.)
Unpacking samba (from .../samba_2%3a3.2.5-4lenny6_i386.deb) ...
Selecting previously deselected package smbfs.
Unpacking smbfs (from .../smbfs_2%3a3.2.5-4lenny6_i386.deb) ...
Processing triggers for man-db ...
Setting up samba (2:3.2.5-4lenny6) ...
Generating /etc/default/samba...
Starting Samba daemons: nmbd failed!
invoke-rc.d: initscript samba, action "start" failed.
dpkg: error processing samba (--configure):
subprocess post-installation script returned error exit status 1
Setting up smbfs (2:3.2.5-4lenny6) ...
Errors were encountered while processing:
samba
E: Sub-process /usr/bin/dpkg returned an error code (1)
这对我有用
启动 nmbd 时发生错误。Samba 已安装,但由于某种原因无法启动。您可以使用以下命令以 root 身份手动运行 nmbd:
这将在屏幕上产生调试输出。这将有助于理解它失败的原因;如果它不能帮助您在此处发布输出。
好吧...查看 samba / nmbd 日志。它们可能会有所帮助 [ /var/log/samba/ ]
是否有可能在该系统上较早地安装了 samba.. 并且留下了混乱的配置文件?
我在最后几分钟遇到了同样的问题 - 并发现了我自己的问题。因此,我想提出“我的”解决方案:从我的旧安装中
/etc/init.d/samba
,有一个没有被apt-get remove --purge
. 删除它并重新安装 samba 工作正常。问候
巴斯蒂