Ubuntu
GParted 搞砸了我的分區
執行
testdisk
我實際上可以看到我的所有文件/dev/sda1
!我想在安裝 Debian 的同時安裝 Windows 以玩一些遊戲。為此,我必須啟動 Ubuntu Live 12.1 DVD 並使用 GParted(我正在調整包含所有內容的主分區的大小)。
調整大小成功完成。然後我嘗試重新啟動到我的 Debian 以備份我的數據,不幸的是,我之前忘記了這樣做。
GRUB 載入良好,但係統無法正常啟動!它會嘗試配置“ramdisk”或類似的東西;那麼這只是一個提示,僅此而已。
現在我再次啟動到 Ubuntu,檢查我的縮小分區。本質上,它已損壞,但我無法真正理解錯誤消息。
這是 GParted 報導的:
GParted 0.12.1 --enable-libparted-dmraid Libparted 2.3 Check and repair file system (ext3) on /dev/sda1 00:11:35 ( ERROR ) calibrate /dev/sda1 00:00:00 ( SUCCESS ) path: /dev/sda1 start: 2,048 end: 1,232,117,759 size: 1,232,115,712 (587.52 GiB) check file system on /dev/sda1 for errors and (if possible) fix them 00:11:35 ( ERROR ) e2fsck -f -y -v /dev/sda1 ext2fs_check_desc: Corrupt group descriptor: bad block for block bitmap e2fsck: Group descriptors look bad... trying backup blocks... Block bitmap for group 4700 is not in group. (block 154014812) Relocate? yes Inode bitmap for group 4700 is not in group. (block 154014813) Relocate? yes Pass 1: Checking inodes, blocks, and sizes Error allocating 1 contiguous block(s) in block group 4700 for block bitmap: Could not allocate block in ext2 filesystem Error allocating 1 contiguous block(s) in block group 4700 for inode bitmap: Could not allocate block in ext2 filesystem /dev/sda1: ***** FILE SYSTEM WAS MODIFIED ***** /dev/sda1: ********** WARNING: Filesystem still has errors ********** e2fsck 1.42.5 (29-Jul-2012) e2fsck: aborted ========================================
這是的輸出
dmesg | tail
:[ 1702.169848] EXT3-fs error (device sda1): ext3_check_descriptors: Block bitmap for group 4700 not in group (block 154014812)! [ 1702.170231] EXT3-fs (sda1): error: group descriptors corrupted [ 1889.324746] CPU3: Package power limit notification (total events = 50) [ 1889.324749] CPU1: Package power limit notification (total events = 50) [ 1889.324750] CPU2: Package power limit notification (total events = 50) [ 1889.324752] CPU0: Package power limit notification (total events = 50) [ 1889.335756] CPU2: Package power limit normal [ 1889.335757] CPU3: Package power limit normal [ 1889.335759] CPU1: Package power limit normal [ 1889.335760] CPU0: Package power limit normal
如何修復我的分區?我能恢復我的數據嗎?
以下是我執行的一些附加命令:
須藤 fsck.ext3 -cf /dev/sda1
e2fsck 1.42.5 (29-Jul-2012) ext2fs_check_desc: Corrupt group descriptor: bad block for block bitmap fsck.ext3: Group descriptors look bad... trying backup blocks... Block bitmap for group 4700 is not in group. (block 154014812) Relocate<y>? yes Inode bitmap for group 4700 is not in group. (block 154014813) Relocate<y>? yes fsck.ext3: e2fsck_read_bitmaps: illegal bitmap block(s) for /dev/sda1 /dev/sda1: ***** FILE SYSTEM WAS MODIFIED *****
須藤 e2fsck -b 32768 /dev/sda1
e2fsck 1.42.5 (29-Jul-2012) Block bitmap for group 4700 is not in group. (block 154014812) Relocate<y>? yes Inode bitmap for group 4700 is not in group. (block 154014813) Relocate<y>? yes /dev/sda1 was not cleanly unmounted, check forced. Pass 1: Checking inodes, blocks, and sizes Error allocating 1 contiguous block(s) in block group 4700 for block bitmap: Could not allocate block in ext2 filesystem Error allocating 1 contiguous block(s) in block group 4700 for inode bitmap: Could not allocate block in ext2 filesystem e2fsck: aborted /dev/sda1: ***** FILE SYSTEM WAS MODIFIED ***** /dev/sda1: ********** WARNING: Filesystem still has errors **********
須藤分開 -l
Model: ATA Hitachi HTS54757 (scsi) Disk /dev/sda: 750GB Sector size (logical/physical): 512B/4096B Partition Table: msdos Number Start End Size Type File system Flags 1 1049kB 631GB 631GB primary ext3 boot 2 742GB 750GB 7985MB primary linux-swap(v1) Warning: Unable to open /dev/sr0 read-write (Read-only file system). /dev/sr0 has been opened read-only. Error: Can't have a partition outside the disk!
分區表條目狀態為“msdos” - 這應該是這樣嗎?
嘗試重新啟動到實時環境,並且沒有任何系統分區
fsck.ext3 -pcf
在相關驅動器上執行。如果fsck.ext3
不可用,則e2fsck -pcf
可以正常工作。使用的標誌將告訴
fsck.ext3
行為如下:-p, Automatic repair (no questions) -c, Check for bad blocks and add them to the badblock list -f Force checking even if filesystem is marked clean
如果這不起作用,請執行並使用該
fdisk /dev/sda
選項來驗證partition table
. 我相信這個選項是v