Disclaimer

The views expressed on this blog are my own and do not necessarily reflect the views of my employer.

Sunday, April 13, 2008

Reinstall solaris grub menu

ohhh no !!!!! my fedora update killed my solaris grub menu !! I have a multiboot system where I was using fedora's grub . Yestarday , I applied "yum -y update" to update my system . But, after that I was facing a strange problem. After switching on my laptop when I select solaris and press the return key it was showing me something like :

Solaris XDE 9/07
rootnoverify (hd0,1)
chainloader =1
GRUB

and after a moment boot prompt was coming again ,i.e solaris grub menu was not coming up.

Anyway, before fedora update , /etc/grub.conf was looking like :

#boot=/dev/sda
default=0
timeout=15
splashimage=(hd0,4)/grub/splash.xpm.gz
hiddenmenu
title Fedora 7 (2.6.21-1.3194.fc7)
root (hd0,4)
kernel /vmlinuz-2.6.21-1.3194.fc7 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
initrd /initrd-2.6.21-1.3194.fc7.img
title Solaris XDE 9/07
rootnoverify (hd0,1)
chainloader +1
title Windows XP SP3
rootnoverify (hd0,0)
chainloader +1

after fedora update it became :

#boot=/dev/sda

default=0
timeout=15
splashimage=(hd0,4)/grub/splash.xpm.gz
hiddenmenu
title Fedora (2.6.23.15-80.fc7)
root (hd0,4)
kernel /vmlinuz-2.6.23.15-80.fc7 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
initrd /initrd-2.6.23.15-80.fc7.img
title Fedora 7 (2.6.21-1.3194.fc7)
root (hd0,4)
kernel /vmlinuz-2.6.21-1.3194.fc7 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
initrd /initrd-2.6.21-1.3194.fc7.img
title Solaris XDE 9/07
rootnoverify (hd0,1)
chainloader +1
title Windows XP SP3
rootnoverify (hd0,0)
chainloader +1

I couldn't get how fedora update can affect solaris grub menu , anyway I decided to reinstall solaris grub. To do so , I insert my installation dvd , restart my system and choose single user shell during sxde installation.
I mount my system in /a and execute the following command :

/sbin/installgrub -m /boot/grub/stage1 /boot/grub/stage2 /dev/rdsk/c0d0s0

(in your system it maybe /dev/rdsk/c1d0s0).

In this way , solaris grub recovered .I just added the following lines in solaris /boot/grub/menu.lst to boot linux from solaris grub menu :

title Fedora (2.6.23.15-80.fc7)
root (hd0,4)
kernel /vmlinuz-2.6.23.15-80.fc7 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
initrd /initrd-2.6.23.15-80.fc7.img

click here to check out my discussion with jlliagre in http://www.linuxquestions.org/.

Update :: This method is also applicable for SXDE 1/08 grub menu reinstallation.

No comments:

Post a Comment