【问题标题】:EC2 Instance, "General error mounting filesystems"EC2 实例,“安装文件系统的一般错误”
【发布时间】:2014-10-21 14:32:51
【问题描述】:

我有一个运行 Ubuntu 12.04 LTS 的 AWS 微型实例,昨晚当我通过 SSH 登录时,我执行了 apt-get update 并且它给了我一个错误(我不记得是哪个)。所以我想我会给我的实例重新启动。今天早上,它说我的实例未能通过 Instance Sstaus Check,我无法通过 SSH 连接到它。我的系统日志的底部如下。有没有办法保存这个,如果没有,无论如何保存数据?

谢谢!

Loading, please wait...
[35914369.823672] udevd[81]: starting version 175
Begin: Loading essential drivers ... done.
Begin: Running /scripts/init-premount ... done.
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.
Begin: Running /scripts/local-premount ... done.
[35914370.187877] EXT4-fs (xvda1): mounted filesystem with ordered data mode. Opts: (null)
Begin: Running /scripts/local-bottom ... done.
done.
Begin: Running /scripts/init-bottom ... done.
[35914373.347844] init: mountall main process (183) terminated with status 1
General error mounting filesystems.
A maintenance shell will now be started.
CONTROL-D will terminate this shell and reboot the system.
Give root password for maintenance
(or type Control-D to continue): 

【问题讨论】:

标签: linux ubuntu amazon-web-services ssh amazon-ec2


【解决方案1】:

这取决于文件系统的损坏程度。

您可以在 AWS 中启动一个新实例,然后将 EBS 卷附加到您的新实例。这可能会帮助您恢复数据。

不要终止实例,否则您可能会完全丢失文件系统。

【讨论】:

    【解决方案2】:

    在执行 apt-get update/upgrade 或 yum update/upgrade 之前,始终使用正在运行的实例的“创建 AMI”选项。这样,如果您的系统在重启后(更新后)无法启动,您可以使用刚刚创建的 AMI 启动“之前”版本(即可启动)实例。

    在这种情况下,Ubuntu 可能尝试安装新的内核和/或 ram 文件系统 (ramfs),并且由于这是一个具有内核和 ramfs 依赖项的 AWS 虚拟机,标准 Ubuntu 构建可能不满足这些依赖项和您的虚拟机现在是 toast。

    如前所述,如果您需要从无法启动的系统中恢复数据,请将其 EBS 卷挂载到工作系统。它可能会抱怨它正在使用中。如果是这样,并且要保留 EBS 卷,您必须选中允许您在终止之前保留该卷的选项。实例终止的默认设置是销毁它的 EBS 卷,因为假设您从之前(或定期)创建的 EBS 支持的 AMI 启动。

    【讨论】:

      猜你喜欢
      • 2021-01-06
      • 1970-01-01
      • 2020-11-29
      • 1970-01-01
      • 2016-10-16
      • 2018-07-12
      • 2019-12-29
      • 2017-04-17
      • 2015-01-20
      相关资源
      最近更新 更多