运行apt-get更新和升级时发生Ubuntu 12.04服务器错误

我运行apt-get update && apt-get upgrade 。 一切正常,但最终结束了以下错误。

任何人都可以帮我解决这个问题。 我知道一点关于Ubuntu服务器,但我相对比较新。 非常感谢

错误如下:

 update-initramfs: Generating /boot/initrd.img-3.2.0-23-generic cryptsetup: WARNING: failed to detect canonical device of /dev/md1 cryptsetup: WARNING: could not determine root device from /etc/fstab W: mdadm: the array /dev/md1 with UUID c9807851:b5d3a910:3fb6082e:e5593158 W: mdadm: is currently active, but it is not listed in mdadm.conf. if W: mdadm: it is needed for boot, then YOUR SYSTEM IS NOW UNBOOTABLE! W: mdadm: please inspect the output of /usr/share/mdadm/mkconf, compare W: mdadm: it to /etc/mdadm/mdadm.conf, and make the necessary changes. W: mdadm: the array /dev/md3 with UUID 7495b34b:eb547028:3fb6082e:e5593158 W: mdadm: is currently active, but it is not listed in mdadm.conf. if W: mdadm: it is needed for boot, then YOUR SYSTEM IS NOW UNBOOTABLE! W: mdadm: please inspect the output of /usr/share/mdadm/mkconf, compare W: mdadm: it to /etc/mdadm/mdadm.conf, and make the necessary changes. Processing triggers for resolvconf ... 

这与apt-get没什么关系,很可能应该没有问题。 您需要更新您的mdadmconfiguration。

尝试这个:

 mdadm --detail --scan >> /etc/mdadm/mdadm.conf 

然后编辑/etc/mdadm/mdadm.conf以删除重复的条目并清理它。

然后你可以通过重新安装你的linux内核来检查它是否工作(或者你可以执行update-initramfs):

 apt-get --reinstall install linux-image-3.2.0-23-generic 

顺便说一句,如果在启动过程中需要使用UUID raid,那么这只会是一个问题。 否则你的系统仍然可以正常启动。 虽然你可能不得不进入故障恢复控制台,但是如果/ home位于RAID中,并且在启动过程中无法进行安装,它将使你进入恢复login,你可以手动启动RAID。