![Ubuntu無法啟動,如何修復其ext4系統分割區?](https://rvso.com/image/1267761/Ubuntu%E7%84%A1%E6%B3%95%E5%95%9F%E5%8B%95%EF%BC%8C%E5%A6%82%E4%BD%95%E4%BF%AE%E5%BE%A9%E5%85%B6ext4%E7%B3%BB%E7%B5%B1%E5%88%86%E5%89%B2%E5%8D%80%EF%BC%9F.png)
我的上網本在啟動 Ubuntu 時崩潰了(我在啟動時不小心拔出了 USB 隨身碟),現在無法啟動了。它給出以下錯誤並進入 ash(BusyBox 內建)shell:
mounting /dev on /root/dev failed: No such file or directory.
mounting /sys on /root/sys failed: No such file or directory.
mounting /proc on /root/proc failed: No such file or directory.
Target filesystem doesn't have /sbin/init
No init found. Try passing init= bootarg
我從 Live CD 啟動並嘗試檢查我的 Linux 分割區,但它不起作用:
ubuntu@ubuntu:/media$ sudo e2fsck /dev/sda2
e2fsck 1.41.12 (17-May-2010)
e2fsck: Device or resource busy while trying to open /dev/sda2
Filesystem mounted or opened exclusively by another program?
ubuntu@ubuntu:/media$ sudo fsck.ext4 /dev/sda2
e2fsck 1.41.12 (17-May-2010)
fsck.ext4: Device or resource busy while trying to open /dev/sda2
Filesystem mounted or opened exclusively by another program?
ubuntu@ubuntu:/media$ fuser /dev/sda2
ubuntu@ubuntu:/media$ fuser /dev/sda2 -v
當我嘗試使用“磁碟工具”檢查分割區時,出現以下錯誤:
File system is NOT clean.
安裝分割區也不起作用(它只是掛起)。不過,我可以在 GParted 中看到該分割區,並且可以在同一硬碟上成功安裝存取我的 Windows 分割區(我也可以從該分割區啟動 Windows)。
有什麼方法可以修復分割區或至少保存我的資料嗎?
先致謝!
答案1
我是「目標檔案系統沒有 /sbin/init」的受害者。我嘗試使用 fsck,但由於以下問題而不起作用。
fsck: Device or resource busy while trying to open /dev/sda1
Filesystem mounted or opened exclusively by another program?
所以這是解決方案:
- 從 Live Ubuntu CD 啟動
刪除第一個 inode
sudo debugfs -w /dev/sda1 debugfs 1.41.11 (14-Mar-2010) debugfs: clri <8> debugfs: quit
再次重新啟動到 Live CD 並執行以下操作
sudo fsck -yv /dev/sda1
這次會起作用的。
答案2
使用舊核心啟動併升級到 10.10 為我解決了這個問題。現在我正在檢查我的硬碟並進行更多備份。