今天半夜当当当的被警告信吵醒,部落格主机突然挂点 😱🥶🙀 急忙连线SSH发现也连不上,改用VNC连上后发现机器已经进入了emergency mode 紧急情况模式~~囧 😣
See ‘systemctl status systemd-fsck-root.service’ for details.
[DEPEND] Dependency failed for /sysroot.
[DEPEND] Dependency failed for Initrd Root File System.
[DEPEND] Dependency failed for Reload Configuration from the Real Root.
第一行的提示systemd-fsck-root服务是指File System Check 档案系统检查,用下列两种指令查询系统记录,果不其然是磁盘区有问题了 😱
- systemctl status systemd-fsck-root -l
- journalctl -xe
如图所示,图片中的红字就是代表真的是磁盘区有问题,最坏的状况就是坏轨或是硬盘挂了 🥶
- fsck failed with exit status 4.
- Failed to start File System Check on/dev/disk/OOXX
而在红字的上方,/dev/vda1就是系统侦测到有问题的磁盘区,所以先使用fsck这个指令来做修复的动作~ 🙀
fsck -y /dev/vda1
接下来会刷刷刷的开始跑修复,直到最后看到FILE SYSTEM WAS MODIFIED就可以重开机了,呼~总算是暂时救回一命,暂时轻松一些了,不过这也提醒我要搬家了~ 囧 🤖🤓🤖
ref.
- VMware – “Failed to start file system check on /dev/disk…” error on Photon OS based virtual appliances (2149838)
- Filesystem corruption on cPanel/WHM CentOS7 | Linode Questions
- How to Boot Debian 11 into Rescue / Emergency Mode
- [SOLVED] Trouble shooting Linux CentOS 7 Kernel that won’t load – Spiceworks