Re: rescue grub -- help!
On 3/24/06, David Liontooth [EMAIL PROTECTED] wrote: I cloned a drive, starting with the MBR: dd if=/dev/hda of=/dev/hdc bs=446 count=1 However, after installing the cloned drive in the new machine, all I get is a scrolling GRUB filling the screen. I downloaded an amd64 netboot CD, mounted / and /boot in /target, Did you do a mount -o bind /dev /target/dev ? [...] In the installer shell, I get ~ # df Filesystem 1k-blocks Used Available Use% Mounted on tmpfs 102400 30248 72152 30% / /dev/cdroms/cdrom0 86390 86390 0 100% /cdrom /dev/ide/host0/bus0/target0/lun0/part2 7740384 3197252 4149944 44% /target /dev/ide/host0/bus0/target0/lun0/part197826 9736 82871 11% /target/boot So /dev is not bind mounted in target, try bind mounting it So it's using devfs, which I thought was deprecated? http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=274511 AFAIK Sarge CD uses devfs, but the etch installer uses udev, quote from that bugreport: d-i uses the device naming scheme originally used by devfs (although we use udev now). What do I tell grub-installer? Use devfs naming, /dev/ide/host0/, see where is the equivalent of hda. [...] klogd[245]: segfault at 003e rip 002a9568b94e rsp 007fbfffe2a0 error 6 How did this segfault happen? [...] What can I do? All I want is to rewrite the MBR, the installation itself is fine. If the netboot CD isnt working for you, could you try using a LiveCD, like Knoppix?
unable to open initial console (was: rescue grub -- help!)
Hi Török, Thank you, that's very helpful. I ended up just installing a new Debian on a different partition; once that was done, the installer agreed to rewrite the MBR, and my old installation showed up in grub. I would much prefer being allowed to rewrite the MBR without first having to install another OS. Once I got that far, I could boot into the OS I'm trying to rescue; however, I now ran into the dreaded warning: unable to open initial console. This is also /dev/ related, and this suggests I have a general dev problem with the partition I cloned. Now that I have a parallel partition that is fully operational, is there a way I can repopulate my /dev directory from chroot, or through a script? Using mount -o bind /dev /root2/dev, I can now chroot into /root2 and see I have a complete /dev directory, so that for instance I can mount /dev/hda1 on a chrooted /boot. How do I make this happen when I boot directly into that partition? I added this to /etc/fstab: devpts /dev/pts devpts mode=0620,gid=5 0 0 But it didn't solve the problem. This seems to be a well-defined problem that should have a straightforward solution. I appreciate your help with this; the partition I'm trying to rescue is in a stable functional state that is no longer possible to duplicate. Dave Török Edvin wrote: On 3/24/06, David Liontooth [EMAIL PROTECTED] wrote: I cloned a drive, starting with the MBR: dd if=/dev/hda of=/dev/hdc bs=446 count=1 However, after installing the cloned drive in the new machine, all I get is a scrolling GRUB filling the screen. I downloaded an amd64 netboot CD, mounted / and /boot in /target, Did you do a mount -o bind /dev /target/dev ? [...] In the installer shell, I get ~ # df Filesystem 1k-blocks Used Available Use% Mounted on tmpfs 102400 30248 72152 30% / /dev/cdroms/cdrom0 86390 86390 0 100% /cdrom /dev/ide/host0/bus0/target0/lun0/part2 7740384 3197252 4149944 44% /target /dev/ide/host0/bus0/target0/lun0/part197826 9736 82871 11% /target/boot So /dev is not bind mounted in target, try bind mounting it So it's using devfs, which I thought was deprecated? http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=274511 AFAIK Sarge CD uses devfs, but the etch installer uses udev, quote from that bugreport: d-i uses the device naming scheme originally used by devfs (although we use udev now). What do I tell grub-installer? Use devfs naming, /dev/ide/host0/, see where is the equivalent of hda. [...] klogd[245]: segfault at 003e rip 002a9568b94e rsp 007fbfffe2a0 error 6 How did this segfault happen? [...] What can I do? All I want is to rewrite the MBR, the installation itself is fine. If the netboot CD isnt working for you, could you try using a LiveCD, like Knoppix? -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: rescue grub -- help!
Hi David, I am a little bit curious why you have chosen to clone the drive with dd? I have always used a different route for cloning a system (see also Duping a Drive Under Linux, http://linuxgazette.net/issue64/tag/12.html): 1. Partition the new drive as necessary; 2. Mount the partitions in the right order under your existing system (for instance in /mnt); 3. Copy the complete system with cp -ax; 4. Use grub to install it to the MBR of the new drive; 5. Transfer the drive to your new system. This route has an additional advantage: you can change the size of any partition if necessary, and even use a totally different partition layout! I never encountered any problems on this route. Regards, Clemens On Friday 24 March 2006 05:00, David Liontooth wrote: I cloned a drive, starting with the MBR: dd if=/dev/hda of=/dev/hdc bs=446 count=1 However, after installing the cloned drive in the new machine, all I get is a scrolling GRUB filling the screen. I downloaded an amd64 netboot CD, mounted / and /boot in /target, and issued chroot /target Everything in there works fine -- the applications run. (I'm sitting at another computer at this point with remote access to the installer). But what I was counting on working, namely grub-install /dev/hda which used to work on i386, maybe a year or two ago, now gives me /dev/hda: Not found or not a block device. If I do df, chroot sees only this: Filesystem 1K-blocks Used Available Use% Mounted on sysfs 7740384 3197252 4149944 44% /sys df: `/dev/pts': No such file or directory tmpfs 7740384 3197252 4149944 44% /dev In the installer shell, I get ~ # df Filesystem 1k-blocks Used Available Use% Mounted on tmpfs 102400 30248 72152 30% / /dev/cdroms/cdrom0 86390 86390 0 100% /cdrom /dev/ide/host0/bus0/target0/lun0/part2 7740384 3197252 4149944 44% /target /dev/ide/host0/bus0/target0/lun0/part197826 9736 82871 11% /target/boot So it's using devfs, which I thought was deprecated? What do I tell grub-installer? When I chrooted to /target, it rewrote /etc/fstab (why?), like this: # /etc/fstab: static file system information. # # file system mount point type options dump pass proc/proc procdefaults0 0 /dev/hda2 / ext3defaults,errors=remount-ro 0 1 /dev/hda1 /boot ext3defaults0 2 /dev/hda5 noneswapsw 0 0 /dev/hdc/media/cdrom0 iso9660 ro,user,noauto 0 0 In dmesg, I get NFORCE3-250: :00:08.0 (rev a2) UDMA133 controller ide0: BM-DMA at 0xf000-0xf007, BIOS settings: hda:DMA, hdb:DMA ide1: BM-DMA at 0xf008-0xf00f, BIOS settings: hdc:DMA, hdd:DMA klogd[245]: segfault at 003e rip 002a9568b94e rsp 007fbfffe2a0 error 6 hda: WDC WD800BB-75CAA0, ATA DISK drive ide0 at 0x1f0-0x1f7,0x3f6 on irq 14 hdc: HITACHI DVD-ROM GD-7000, ATAPI CD/DVD-ROM drive Obviously /dev/hda is seen, since the chroot is running on it. What can I do? All I want is to rewrite the MBR, the installation itself is fine. Dave -- --- Clemens Bergmann Schwertlilienweg 14 68259 Mannheim [EMAIL PROTECTED] --- -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Re: rescue grub -- help!
[EMAIL PROTECTED] wrote: Hi David, I am a little bit curious why you have chosen to clone the drive with dd? I have always used a different route for cloning a system (see also Duping a Drive Under Linux, http://linuxgazette.net/issue64/tag/12.html): Looks good, and better suited to my purpose. What I did basically didn't work out. I could have played it safer and done a single massive dd, but I needed a bit more flexibility. Dave 1. Partition the new drive as necessary; 2. Mount the partitions in the right order under your existing system (for instance in /mnt); 3. Copy the complete system with cp -ax; 4. Use grub to install it to the MBR of the new drive; 5. Transfer the drive to your new system. This route has an additional advantage: you can change the size of any partition if necessary, and even use a totally different partition layout! I never encountered any problems on this route. Regards, Clemens On Friday 24 March 2006 05:00, David Liontooth wrote: I cloned a drive, starting with the MBR: dd if=/dev/hda of=/dev/hdc bs=446 count=1 However, after installing the cloned drive in the new machine, all I get is a scrolling GRUB filling the screen. I downloaded an amd64 netboot CD, mounted / and /boot in /target, and issued chroot /target Everything in there works fine -- the applications run. (I'm sitting at another computer at this point with remote access to the installer). But what I was counting on working, namely grub-install /dev/hda which used to work on i386, maybe a year or two ago, now gives me /dev/hda: Not found or not a block device. If I do df, chroot sees only this: Filesystem 1K-blocks Used Available Use% Mounted on sysfs 7740384 3197252 4149944 44% /sys df: `/dev/pts': No such file or directory tmpfs 7740384 3197252 4149944 44% /dev In the installer shell, I get ~ # df Filesystem 1k-blocks Used Available Use% Mounted on tmpfs 102400 30248 72152 30% / /dev/cdroms/cdrom0 86390 86390 0 100% /cdrom /dev/ide/host0/bus0/target0/lun0/part2 7740384 3197252 4149944 44% /target /dev/ide/host0/bus0/target0/lun0/part197826 9736 82871 11% /target/boot So it's using devfs, which I thought was deprecated? What do I tell grub-installer? When I chrooted to /target, it rewrote /etc/fstab (why?), like this: # /etc/fstab: static file system information. # # file system mount point type options dump pass proc/proc procdefaults0 0 /dev/hda2 / ext3defaults,errors=remount-ro 0 1 /dev/hda1 /boot ext3defaults0 2 /dev/hda5 noneswapsw 0 0 /dev/hdc/media/cdrom0 iso9660 ro,user,noauto 0 0 In dmesg, I get NFORCE3-250: :00:08.0 (rev a2) UDMA133 controller ide0: BM-DMA at 0xf000-0xf007, BIOS settings: hda:DMA, hdb:DMA ide1: BM-DMA at 0xf008-0xf00f, BIOS settings: hdc:DMA, hdd:DMA klogd[245]: segfault at 003e rip 002a9568b94e rsp 007fbfffe2a0 error 6 hda: WDC WD800BB-75CAA0, ATA DISK drive ide0 at 0x1f0-0x1f7,0x3f6 on irq 14 hdc: HITACHI DVD-ROM GD-7000, ATAPI CD/DVD-ROM drive Obviously /dev/hda is seen, since the chroot is running on it. What can I do? All I want is to rewrite the MBR, the installation itself is fine. Dave -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
rescue grub -- help!
I cloned a drive, starting with the MBR: dd if=/dev/hda of=/dev/hdc bs=446 count=1 However, after installing the cloned drive in the new machine, all I get is a screen-full of scrolling GRUB filling the screen. I downloaded a netboot CD, mounted / and /boot in /target, and issued chroot /target Everything in there works fine -- the applications run. (I'm sitting at another computer at this point with remote access to the installer). But what I was counting on working, namely grub-install /dev/hda which used to work on i386, maybe a year or two ago, now gives me /dev/hda: Not found or not a block device. If I do df, chroot sees only this: Filesystem 1K-blocks Used Available Use% Mounted on sysfs 7740384 3197252 4149944 44% /sys df: `/dev/pts': No such file or directory tmpfs 7740384 3197252 4149944 44% /dev In the installer shell, I get ~ # df Filesystem 1k-blocks Used Available Use% Mounted on tmpfs 102400 30248 72152 30% / /dev/cdroms/cdrom0 86390 86390 0 100% /cdrom /dev/ide/host0/bus0/target0/lun0/part2 7740384 3197252 4149944 44% /target /dev/ide/host0/bus0/target0/lun0/part197826 9736 82871 11% /target/boot So it's using devfs, which I thought was deprecated? What do I tell grub-installer? When I chrooted to /target, it rewrote /etc/fstab (why?), like this: # /etc/fstab: static file system information. # # file system mount point type options dump pass proc/proc procdefaults0 0 /dev/hda2 / ext3defaults,errors=remount-ro 0 1 /dev/hda1 /boot ext3defaults0 2 /dev/hda5 noneswapsw 0 0 /dev/hdc/media/cdrom0 iso9660 ro,user,noauto 0 0 In dmesg, I get NFORCE3-250: :00:08.0 (rev a2) UDMA133 controller ide0: BM-DMA at 0xf000-0xf007, BIOS settings: hda:DMA, hdb:DMA ide1: BM-DMA at 0xf008-0xf00f, BIOS settings: hdc:DMA, hdd:DMA klogd[245]: segfault at 003e rip 002a9568b94e rsp 007fbfffe2a0 error 6 hda: WDC WD800BB-75CAA0, ATA DISK drive ide0 at 0x1f0-0x1f7,0x3f6 on irq 14 hdc: HITACHI DVD-ROM GD-7000, ATAPI CD/DVD-ROM drive Obviously /dev/hda is seen, since the chroot is running on it. What can I do? All I want is to rewrite the MBR, the installation itself is fine. Installation and rescue is my one continuing nightmare with Debian -- once you're up and running, you're in paradise, but getting there continues to be difficult. Dave -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
rescue grub -- help!
I cloned a drive, starting with the MBR: dd if=/dev/hda of=/dev/hdc bs=446 count=1 However, after installing the cloned drive in the new machine, all I get is a scrolling GRUB filling the screen. I downloaded an amd64 netboot CD, mounted / and /boot in /target, and issued chroot /target Everything in there works fine -- the applications run. (I'm sitting at another computer at this point with remote access to the installer). But what I was counting on working, namely grub-install /dev/hda which used to work on i386, maybe a year or two ago, now gives me /dev/hda: Not found or not a block device. If I do df, chroot sees only this: Filesystem 1K-blocks Used Available Use% Mounted on sysfs 7740384 3197252 4149944 44% /sys df: `/dev/pts': No such file or directory tmpfs 7740384 3197252 4149944 44% /dev In the installer shell, I get ~ # df Filesystem 1k-blocks Used Available Use% Mounted on tmpfs 102400 30248 72152 30% / /dev/cdroms/cdrom0 86390 86390 0 100% /cdrom /dev/ide/host0/bus0/target0/lun0/part2 7740384 3197252 4149944 44% /target /dev/ide/host0/bus0/target0/lun0/part197826 9736 82871 11% /target/boot So it's using devfs, which I thought was deprecated? What do I tell grub-installer? When I chrooted to /target, it rewrote /etc/fstab (why?), like this: # /etc/fstab: static file system information. # # file system mount point type options dump pass proc/proc procdefaults0 0 /dev/hda2 / ext3defaults,errors=remount-ro 0 1 /dev/hda1 /boot ext3defaults0 2 /dev/hda5 noneswapsw 0 0 /dev/hdc/media/cdrom0 iso9660 ro,user,noauto 0 0 In dmesg, I get NFORCE3-250: :00:08.0 (rev a2) UDMA133 controller ide0: BM-DMA at 0xf000-0xf007, BIOS settings: hda:DMA, hdb:DMA ide1: BM-DMA at 0xf008-0xf00f, BIOS settings: hdc:DMA, hdd:DMA klogd[245]: segfault at 003e rip 002a9568b94e rsp 007fbfffe2a0 error 6 hda: WDC WD800BB-75CAA0, ATA DISK drive ide0 at 0x1f0-0x1f7,0x3f6 on irq 14 hdc: HITACHI DVD-ROM GD-7000, ATAPI CD/DVD-ROM drive Obviously /dev/hda is seen, since the chroot is running on it. What can I do? All I want is to rewrite the MBR, the installation itself is fine. Dave -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]