Showing posts with label Red Hat 9. Show all posts
Showing posts with label Red Hat 9. Show all posts

Monday, April 26, 2010

How To Restore GRUB



GNU GRUB (short for GNU GRand Unified Bootloader) is a boot loader package from the GNU Project. GRUB (shortened form of GNU GRUB) is the reference implementation of the Multiboot Specification, which enables a user to have multiple operating systems on their computer, and choose which one to run when the computer starts.

You have windows XP and linux on the same hard disk and you choose GRUB as boot loader.At boot time you see a menu to choose windows or linux.
But one day you reinstall Windows XP and it rewrites your MBR and the menu has gone, now you only can boot windows.

What to do:
Put the redhat boot disk you created on the installation on the floppy drive, boot the system and run grub command

Remember that for grub (hd0,1) means hda (primary controller master), second partition.

Now we need to tell grub where are the grub files:

If you know where they are, type something like:
root (hd0,1)

else if you have no idea, type:
find /boot/grub/stage1
and then the root command with the correct parameters:

setup (hd0)
to install it on hd0, that is MBR of the first HD.

type quit and reboot.
The menu will appear again.
If you want to make some changes to the boot menu, you must edit the file: /boot/grub/menu.lst

A sample menu.lst file is this:

default=0
timeout=5
splashimage=(hd0,1)/boot/grub/splash.xpm.gz

title Red Hat Linux (2.4.18-14)
root (hd0,1)
kernel /boot/vmlinuz-2.4.18-14 ro root=LABEL=/ hdc=ide-scsi
initrd /boot/initrd-2.4.18-14.img
title Red Hat Linux (2.4.18-openmosix3)
root (hd0,1)
kernel /boot/vmlinuz-2.4.18-openmosix3 ro root=/dev/hda2 hdc=ide-scsi
initrd /boot/initrd-2.4.18-openmosix3.img
title WindowsME
rootnoverify (hd0,0)
chainloader +1

Thursday, April 15, 2010

How to configure the IP address in Red Hat Linux 9



1. First, activate the network card adapter
a. Navigate, Start Application> System Tools> Network Device Control
b. Select eth0 and click Activate
Once your network card adapter is activated, you can check your status.

2. Just open a terminal then at the command prompt, key-in,
/sbin/ifconfig to see what the IP address is, and other information on your network card.


There are two sections - eth0 and lo.

  • Eth0 is information about your network card. The second line in the eth0 section shows you the IP address assigned to that network card (in this case it's 192.168.1.2).
  • lo is information about the loopback device (we won't go into this here).
3. To configure your netword card, just key-in:

/usr/sbin/netconfig

You should get a GUI like this....




If you wish to continue, press ENTER.

You will get a window where you can enter the address you want....




Check Use dynamic if you want your IP address assigned automatically. I recommend leaving it unchecked at this stage.
Type in an IP address
The netmask of 255.255.255.0 should work
Enter the IP address of the gateway you use, if you use one.
Enter the IP address of the DNS nameserver you wish to use.
Thats it.