title Linux
root (hd0,1)
kernel /zImage root=/dev/hda2 ro
The root parameter indicates that the / should be mapped to the device hd0’s first partition. The next line tells the system to get the kernel at /zImage. Because there’s only one entry, grub doesn’t display a menu. This root parameter doesn’t have an effect on the root file system that the kernel eventually mounts; it’s the root file system for the boot loader itself. The root device format is different than Linux, which can result in confusion. In GRUB, a device has the following format:
(device[bios number][,partition])
Device can be one of the following values: hd for fixed disks, fd for floppy disks, or nd for network drives. The number that follows is the identifier assigned by the computer’s BIOS. You can find this in the BIOS setup for the computer; the assigned numbers start at 0 and work upward. The partition is the logical division of the drive. To find the partitions on a drive, use the sfdisk command:
$ sudo /sbin/sfdisk -l
GRUB allows you to load the kernel from a TFTP server. To do this, you need to configure the IP parameters and use (nd) instead of (hd0,1) as the root device. For example:
ifconfig -address=10.0.0.1 -server=10.0.0.2
kernel (nd)/bzImage
This results in GRUB configuring the adapter to have an IP address of 10.0.0.1 and use the default netmask (255.0.0.0) and contact 10.0.0.2 to download the kernel file bzImage via TFTP to boot the system.
Source of Information : Pro Linux Embedded Systems
No comments:
Post a Comment