linux 文件系统修复:The root filesystem on /dev/sda1 requires a manual fsck

原创 linuxfsck

今天早上为了解决 Ubuntu 上的中文文件乱码问题,根据网上的教程一顿操作,然后重启,竟然起不来了。

我的 VM 没有做快照,以为要完了,上面搭了一堆测试环境呢,这也是提醒我以后做重要操作得给虚拟机建快照节点。

说问题:虚拟机重启后没有到登录提示,停止在一处检查后面,光标在 (initramfs) _ 后面一直闪。看一下停止之前的错误信息,大致如下:

dev/sda1: Inodes that were part of a corrupted orphan linked list found.
/dev/sda1: UNEXPECTED INCONSISTENCY:; RUN fsck MANUALLY
        (i.e., without -a or -p options)
fsck exited with status code 4
The root filesystem on /dev/sda1 requires a manual fsck
modprobe: module ehci-orion not found in modules.dep

BusyBox v1.22.1 (Debian 1:1.22.0-9+deb8u1) built-in shell (ash)
Enter 'help' for a list of built-in commands.

/bin/sh: can't access tty; job control turned off
(initramfs) _

出错原因:磁盘检测不能通过,可能是因为系统突然 断电 或其它 未正常关闭系统 导致。

在错误信息里说了解决的办法了, The root filesystem on /dev/sda1 requires a manual fsck,意思是可能需要手动检查和维护分区 /dev/sda1

那我们直接在 (initramfs) 提示后面输入检查。

(initramfs) fsck /dev/sda1

后面有一些确认,全部 y 确认就可以了。如果幸运的话,像我的情况,做完重启,直接就可以进入登录了。

如果觉得这对你有用,请随意赞赏,给与作者支持
评论 0
最新评论