LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   windows after linux (https://www.linuxquestions.org/questions/linux-newbie-8/windows-after-linux-92294/)

spank 09-13-2003 05:37 AM

windows after linux
 
I had to reinstall XP on a box with linux and I lost the boot manager. how can I reactivate it. Now it boots only in xp

spank 09-13-2003 05:39 AM

ps: my manager was grub

XavierP 09-13-2003 05:45 AM

firstly, boot off your linux bootdisk - either the floppy or cd 1

once you are at the prompt type:
/sbin/grub-install

To install GRUB in the MBR, type:

code: grub-install /dev/hda

spank 09-13-2003 08:58 AM

i didn`t make a boot disk... how can I make one ? If I boot over my distro CD I would have to mount my linux part... and so on. Better if I can make a boot disk. How can I make one ?
THX

Mathieu 09-13-2003 09:41 AM

If you did not make a Linux boot disk, you will have to boot from the CD.

Since you are using RedHat, follow the steps from this document.
http://www.redhat.com/docs/manuals/l...mode-boot.html

Then as XavierP mentioned, re-install GRUB back into the MBR.
Code:

/sbin/grub-install /dev/hda

spank 09-13-2003 12:43 PM

I did that but it gives me an error that something isn't in /var/....

XavierP 09-13-2003 12:54 PM

You'll have to give more info than that. What is the full detail of the error?

spank 09-13-2003 01:46 PM

/usr/share/grub/i386red-hat/stage1 : Not Found.

I have mounted my linux partition on /mnt/linux

Mathieu 09-13-2003 02:25 PM

On your Linux partition, you should have the /usr/share/grub/i386-redhat directory.
This directory contains boot files and support files for different filesystems. ( stage1, stage2, e2fs_stage1_5, etc).

If these files are not present, copy them from the /boot/grub directory.
More precisely, copy stage1, stage2 and any files that end with 1_5

spank 09-13-2003 03:55 PM

I had a clue what they are for...
I have this dir but it`s situated in /mnt/linux/usr/share/grub/i386-redhat the mounded partition.
I can't copy them in /usr/share/grub/i386-redhat because on the boot disk that dir is read-only and I can't change it with chmod

spank 09-14-2003 07:49 AM

somebody ? anybody ?

spank 09-14-2003 08:12 AM

can somebody give me a cat of lilo.conf... i`ll try to install lilo.
THX

Demonbane 09-14-2003 09:29 AM

k I've made a grub bootdisk for you, download it at
http://ryantsai.ozforces.com.au/grubdisk.img
then use dd to write it, ie

dd if=grubdisk.img of=/dev/fd0

or alternatively you can use something like winimage (www.winimage.com) for windows
then boot with it, after u get the grub prompt first do:

root (hd0,0)

if you linux(or your /boot partition if its separate) is installed in first hdd first partition, (hd0,1) for first hdd second partition, so on and so forth. It'll also tell you the partition type, so if it says ext3/reiserfs whatever you use for your linux partition then you got it right.
after thats done do a:

setup (hd0)
This will install grub back into MBR

If you use (hd0,0) it instead will install grub into bootsector of first patition of first hdd, useful if u want to use other bootmanagers in MBR.
Lastly you can either type reboot or you can try booting your linux now, use:
kernel /boot/vmlinuz-<kernel version>
initrd /boot/initrd-<kernel version>.img
then type "boot"
note you can use tab for auto filename completion, and initrd is used in redhat but not in some other distros.


All times are GMT -5. The time now is 03:02 PM.