LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Booting Debian 6 with no bootloader, no liveCD, and no bootable partition (https://www.linuxquestions.org/questions/linux-general-1/booting-debian-6-with-no-bootloader-no-livecd-and-no-bootable-partition-913552/)

franklinb 11-14-2011 06:46 PM

Booting Debian 6 with no bootloader, no liveCD, and no bootable partition
 
Last night I decided to reinstall Debian and cover the old Windows partition completely. I used the executable installer at http://goodbye-microsoft.com to install it. The installation completed, but when I attempted to install grub, it coughed up an error. Then I realized I had no bootable partition. So I went back to the partition configuration step, and the installer froze and I couldn't do anything. So I rebooted the computer and now have no bootable partition and no grub.

I do, however, have some old live CD's of Puppy Linux 4.12 and DSLinux (dunno which version). When I try to make the partition bootable in DSL, it says it can't read the drive. When I try in Puppy, I can view the files on the drive (so I know Debian is installed), but it won't let me just adjust the boot flag either.

Is it possible to adjust the boot flag and install grub via the Puppy CD?

I can also use PXE to load a bootloader, if that helps. I tried using grldr to boot it, but I'm not sure if that mounted the partition correctly. I'm also not sure if I can boot that way without a boot partition.

jlinkels 11-14-2011 07:59 PM

AFAIK you don't need the boot flag on you partition.

No GRUB is more serious. Great that you can boot in something else.

Boot
Mount the Debian disk below the /mnt directory, for example:
Code:

mkdir /mnt/sda1
mount /dev/sda1 /mnt/sda1

(Assuming you have a mnt directory and Debian is installed on sda1... you get the picture.

If Debian consists of more partitions, mount them as well in the directory tree below /mnt/sda1.

Now the trick:
Code:

chroot /mnt/sda1
and install grub with grub-install /dev/sda

While writing I realize your kernel version might not be compatible with the installed Debian version.

Recommended is to download a Debian live USB (rescue version), boot from the USB and follow the instructions above.

jlinkels

Brains 11-17-2011 04:21 AM

Debian uses grub2, hopefully the live CD you have uses grub2 also. But probably does not matter. This article has got me out of this bind many a times, look at section 12.


All times are GMT -5. The time now is 06:11 AM.