Problems restoring ext2 partitions

Post here if you found a bug or something really not expected in the program
Post Reply
mydadisalive
Posts: 9
Joined: Sun May 24, 2009 11:50 am

Problems restoring ext2 partitions

Post by mydadisalive » Thu Dec 23, 2010 11:54 am

Hi,

I built a unit-recovery utility based on fsarchiver.
I encountered the following problem with 2 filesystems ( /dev/cciss/c0d0p2 and /dev/cciss/c0d0p3 which corresponds to / and /var).

Surprisingly, the restore did work despite the errors (I had to manually comment the part that exits on errors).

Machine details:
Device Boot Start End #sectors Id System
/dev/cciss/c0d0p1 * 63 401624 401562 83 Linux
/dev/cciss/c0d0p2 401625 117836774 117435150 83 Linux
/dev/cciss/c0d0p3 117836775 235271924 117435150 83 Linux
/dev/cciss/c0d0p4 235271925 286663859 51391935 5 Extended
/dev/cciss/c0d0p5 235271988 259401554 24129567 83 Linux
/dev/cciss/c0d0p6 259401618 276173414 16771797 82 Linux swap / Solaris
/dev/cciss/c0d0p7 276173478 286663859 10490382 83 Linux
Warning: partition 1 does not end at a cylinder boundary
Successfully wrote the new partition table

Machine Type................MULLINS
Kernel release..............2.6.18-164.2.1.el5PAE
Red Hat OS release..........5.4
Master disk release.........swp-RedHat-Linux-OS-5.3.0.0-01
CSP Base(With OS Patches)...4.2.0.1-02

Utility Logs:
Statistics for filesystem 0
* files successfully processed:....regfiles=24726, directories=2608, symlinks=88, hardlinks=0, specials=11
* files with errors:...............regfiles=0, directories=1, symlinks=0, hardlinks=0, specials=0
Tue Dec 21 15:47:09 UTC 2010 Error restoring partition /cciss/c0d0p2. Fsarchiver returned the following error: 1. Exiting.
[errno=22, Invalid argument]: oper_restore.c#213,extractar_restore_attr_xattr(): xattr:lsetxattr(/etc/racoon,security.selinux) failed
[errno=22, Invalid argument]: oper_restore.c#213,extractar_restore_attr_xattr(): xattr:lsetxattr(/etc/racoon/certs,security.selinux) failed
[errno=22, Invalid argument]: oper_restore.c#213,extractar_restore_attr_xattr(): xattr:lsetxattr(/etc/rc.d/init.d/smartd,security.selinux) failed
Statistics for filesystem 0
* files successfully processed:....regfiles=69936, directories=7654, symlinks=2380, hardlinks=3955, specials=1
* files with errors:...............regfiles=1, directories=2, symlinks=0, hardlinks=0, specials=0
Tue Dec 21 16:00:00 UTC 2010 Error restoring partition /cciss/c0d0p3. Fsarchiver returned the following error: 1. Exiting.



Please advice,
Best,
Avichay.

Corbin
Posts: 3
Joined: Fri Nov 11, 2011 9:09 am

Re: Problems restoring ext2 partitions

Post by Corbin » Mon Nov 14, 2011 10:06 am

I have an external USB HD formatted ext2. I accidentally deleted the partition by leaving the drive plugged into a workstation I was doing a new install of XP on. I stopped right after I did the L to delete the partition so hopefully I have a good chance of recovering it as nothing was written to the disk. Any guidance on how I might go about restoring the partition would be much appreciated or am I SOL?

Got lucky, I used the gpart live cd which has a program on it called testdisk. It was actually quite easy to recover and all I have left to do now is run an fsck on it to make sure everything is ok.

Post Reply