GRUB…? It’s for Linux

Table of Contents

GRUB…? It’s for Linux

GRUB It's for Linux
GRUB It’s for Linux

Still first course installation of Linux and confused to do I uninstall the format’s computer directly, so great it would pass the boot again window that has been installed there was error in the GRUB not found what I of GRUB and try to see what benefits I get from this Zaki math: Good Reading)

GRUB, the Grand Unified Boot Loader, such as LILO, can memboot your Linux system, maintain and treat the booting and loading on your kernel. GRUB has many more features and easy to use, reliable and flexible compared with LILO. Drawing with basic knowledge LILO and partition the disk so you can use the GRUB this well.
In addition to Linux, GRUB can also memboot other Operating System, such as NetBSD, OpenBSD, the GNU Hurd, DOS, Windows 95, 98, Me, NT, and 2000. Although membooting an Operating System is a job that is not normal and interesting, the work is actually quite important. Boot Loader If you do not work well, you can be locked / trapped in your system (can not booting).
For me, GRUB Boot Loader is a reliable, as an example of the GRUB Linux kernel can be read directly from the partition minix, FAT, ext2, or Reiserfs. From my long-winded explain opportunities GRUB and LILO compares with the one we will start using GRUB this way.

I will start with a Linux OS that is currently still use LILO and GRUB not install at all. We can download the tarballs GRUB the latest version of the At the time of writing this article I use GRUB version (grub- Do not afraid to menginstallnya, boot records you will not be changed. We will mengkompile and install GRUB as other programs on umumnya.Kita can make a GRUB bootdisk, once again do not worry. I will tell before we do anything that can change the boot process.
I will put the source code and mengkompilenya in the directory / tmp, and then install everything in the directory / usr. As root, type the command as follows:
# Cd / tmp
# Tar xzvf / direktori/tarball/grub/berada/grub-
# Cd grub-
#. / Configure-prefix = / usr
# Make
# Make install
Now GRUB has been installed and we will start with putting the boot loader on a diskette.

Make Bootdisk
To make bootdisk, we will use some simple steps. First we will create an ext2 file system on a diskette, which will be used, and after that we mount to the system and copy some files to a floppy GRUB and then run the program “GRUB” that keep all the settings on the boot diskette records.
Enter a blank floppy, then type the following command:
# Mke2fs / dev/fd0
which means to make (format) file system ext2 on the diskette. Looks like Figure 1.

Figure 1. Formatting a disk with ext2.

Now we will make some directory and copy critical files (which have been installed at the GRUB is installed)
# Mkdir / mnt / floppy / boot /
# Mkdir / mnt / floppy / boot / grub /
Then copy the files stage1 and stage2 in the directory / usr/share/grub/i386-redhat / (if at the time to install Red Hat 7.2 select options GRUB Loader) and / usr/share/grub/i386-pc / (if it was install directly from the tarball GRUB)
# Cp / usr/share/grub/i386-redhat/stage1 / mnt / floppy / boot / grub
# Cp / usr/share/grub/i386-redhat/stage2 / mnt / floppy / boot / grub
Stay for longer we will have bootdisk working properly.
When you install the appropriate instructions at the top of a tar ball GRUB, the program is interesting that called grub is located in the directory / usr / sbin / grub. It is very interesting, because in fact, this program offers the same functions as the GRUB Boot Loader. Yes! Although Linux is already running, you can run GRUB, and can do the job command interface and the same when you use the GRUB boot disk or menginstallkan GRUB on the MBR in your Hard Disk.
We will use the program for the grub set up the boot sector on the boot disk us. Run grub, it will exit the display as follows …

# / Usr / sbin / grub

GRUB version 0.90 (640K lower / upper memory 3072K)
[Minimal Bash-like line editing is supported. For the first word, TAB lists possible command completions. Anywhere else TAB lists the possible completions of a device / filename. ]

Version of the above depending on the version of the GRUB installed in the system. If we install the tarballs we will see the difference version (Example tarballs this version If we choose the option when installing Red Hat 7.2 version of the GRUB using version 0.90, as we see above.
grub> -> It is a command prompt grub / grub console.
If the grub we console type:
grub> root (fd0)
It will then display the information out as follows:

File type is ext2fs, using whole disk
which means that the devices fd0 File (/ dev/fd0) or floppy all its contents using ext2. The “root” was ask to see the GRUB stage1 and stage2 on fd0 devices, which in defaultya see in the GRUB boot / grub / partition on the disk that you specify (ie the device fd0).
We just copying files to the appropriate directory. Then we will ask to install GRUB Boot Records in the floppy diskette with us using the “setup (device)” in the GRUB console.
grub> setup (fd0)
the view that:

Checking if “/ boot/grub/stage1” exists … yes
Checking if “/ boot/grub/stage2” exists … yes
Checking if “/ boot/grub/e2fs_stage1_5” exists no …
Running “install / boot/grub/stage1 d (fd0) / boot/grub/stage2 p / boot / grub / grub. Conf” Done … Johnson Space Center.

Then the “quit” in the GRUB console to exit. Thus, we already have the GRUB boot disk that we will “play” to experiment more :-).
grub> quit
When you use GRUB Boot Loader as you, first make sure you know the partition where you save the kernel Linuxnya name and the partition that contains the root filesystem “/”. Also make sure you see the LILO configuration, like some of the arguments that the need for mempassingkan arguments to the kernel, such as “append = ide-scsi” to mengemulasikan presence cdwriter as scsi, and the argument – an argument the other. If we already know all this information, we will start quietly.

Starting GRUB
To start the GRUB, we will shutdown the computer, and memboot from the boot disk that was created earlier. But if you want to run it from the system that has been running. You can run grub such as the above, all will be running the same, but you will not be what memboot it from here (because the system is running Linux).
When Memboot from bootdisk that we created earlier, GRUB will seek information from the BIOS and find the file that we have a copy delivered to the bootdisk before. The view will be the same as we run the above:

GRUB version 0.90 (640K lower / upper memory 3072K)
[Minimal Bash-like line editing is supported. For the first word, TAB lists possible command completions. Anywhere else TAB lists the possible completions of a device / filename. ]

Sumber :