Re: how to boot a hard disk kernel from a live CD?



On Wed, 31 Jan 2007 12:10:56 -0600, Cameron Fitzhugh wrote:

I have a CD that I can boot from and start up the Linux kernel from the CD.
Then I can mount and access Linux partitions on the hard disk.

The computer is not set up for dual booting -- if I just boot the computer,
it goes directly to XP.

The kernel on the CD doesn't have the right drivers for the X system on this
computer, so I can't start up X-Windows. But there's a kernel generated for
this computer in /boot on one of the Linux partitions, so if I could boot
it, I would be able to run KDE. The /boot directory also contains grub.

Is there a way, after I've booted the live CD, to tell it to re-boot using
the Linux kernel and the root directory on the hard disk?

Thanks,
Cameron

Your options are simple. (1) Either setup your hard disk as a dual boot,
or else, (2) create a grub bootable floppy/CD. An external boot disk has
the advantage that it could be safer; you are less likely to break
something by changing the bootloader. BTW, grub setup isn't too difficult
if you're careful. A dual boot system has the advantage that the bootstrap
process will be slightly quicker using a magnetic disk.

Continuing this discussion, and assuming you want to continue to boot from
an external media, such as a CD or floppy, then you should be aware that
the grub loader is your friend. ;-) For one thing, grub is a very flexible
boot loader, and the examples below illustrate some of of its nice
features.

Grub has an interactive shell which can read files on filesystems to find
your kernel, etc. Here is one example, assuming you have booted using
grub, and have used 'c' to enter its shell:

You can specify a configfile (menu):

grub> root (hd0,2)
grub> configfile /boot/menu.lst

You can specifiy a kernel:

grub> root (hd0,2)
grub> kernel /boot/linux-26


You can chainload to your Windows setup:

grub> rootnoverify (hd0,0)
grub> makeactive
grub> chainloader +1
grub> boot

Caution: Substitute values which are appropriate for your system. Be
careful when making changes to your MBR and partitions, if applicable.

I write about grub quite often, and have a simple bootable grub CD for
download, as explained here:
http://groups.google.com/group/comp.os.linux.setup/msg/602040b59e1eac50

--
Ripley: And you let him in.
http://www.imdb.com/title/tt0078748/quotes

.



Relevant Pages

  • Re: changing default os in grub
    ... > I've just installed a 2.6.8 kernel in Sarge and was ... > hoping the adjustment to grub would return Sarge to ... # Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST ... # This entry automatically added by the Debian installer for an existing ...
    (Debian-User)
  • Re: booting linux using a floppy
    ... which kernel of the list to boot from. ... Note that this will at this point remove your ability to boot into windows. ... I think I recall that you said the grub loader... ... and grub will search for a partition containing grub's stage2 file ...
    (comp.os.linux.misc)
  • Re: Debian bootable on external USB-harddisk
    ... > They are all on the external harddisk since I want to boot from this ... >> fail if you have placed the kernel and initrd on the external ... >> available from BIOS. ... >> grub stage one on the external disk. ...
    (comp.os.linux.setup)
  • Re: Installing grub for a different computer
    ... > root ... > menu - I guess there's only one kernel present). ... Boot with the floppy ... After entering the commands above for root, kernel and initrd grub is ...
    (Fedora)
  • Re: Naming harddisks (Linux)
    ... But I also see that for an USB drive it uses /dev/sdas the ... Does GRUB recognize SCSI drives? ... The first step in understanding the boot process is to ... The bootloader's job is to load the OSs kernel. ...
    (comp.os.linux.misc)