On 2011/04/06 18:25 (GMT-0500) Sunny composed:
I have very bad problem here. I have opensuse 10.0 machine. After hw issue, the /boot partition got corrupted.
I made an image of all the partitions to a new hdd. All of them pass fsck without any problems, and all the files are there.
But /boot fails fsck, and after repair vmlinux is lost, initrd is lost etc. I have an image of the partition, so I can play with it as much as I can.
Is this a laptop? How did you partition the new HD/with what tool? How did you make that image? Maybe your image and the location you're trying to restore it to do not match? Is the new HD bigger? Maybe its legacy geometry does not match that from the old. Maybe it's not located the same number of sectors from the start of the disk. It could be helpful for us to know what fdisk -l currently reports, and even better if you had that info from the old HD.
Is there a way I can rebuild /boot, like if I boot a live cd, then chroot maybe to the original / partition, etc.
Yes. If it was here I would create the /boot from scratch, then copy the required files from the saved image, somewhat like what I do with a new HD. I always partition and install bootloader before installing any Linux operating system. Typically I use a Knoppix CD to mkfs.ext2 my /boot partition, then copy the Knoppix library of Grub files to the new partition's grub directory, then run the Grub shell to manually install Grub to that partition's boot sector. Asssuming the /boot partition is the first primary at the head of the HD: # grub grub> root (hd0,0) grub> setup (hd0,0) grub> quit # Recreated this way there should be no reason for fsck to fail when you try to boot. More details that may be helpful: http://fm.no-ip.com/PC/install-doz-after.html -- "The wise are known for their understanding, and pleasant words are persuasive." Proverbs 16:21 (New Living Translation) Team OS/2 ** Reg. Linux User #211409 ** a11y rocks! Felix Miata *** http://fm.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org