LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-01-2007, 10:49 AM   #1
ankz.upadhyay
LQ Newbie
 
Registered: Mar 2007
Location: Manchester
Distribution: Linux Mandriva 2007, Windows XP
Posts: 13

Rep: Reputation: 0
Exclamation Linux on Dual Machine - Loading


Hi Folks

I have installed Linux on Windows Machine with appropriate partition. So the scenario like ............ I have installed Linux on windows pre installed.

Now I had to format my windows partition for some reason, so I did that with my windows disk and installed on different partition than Linux.

Now the problem I am getting is that I am able to get into Linux OS. Before I used to get option whether to load which OS at the start of my pc but now computer just load windows at default. I reckon that when I installed Windows again, it has overwrite the boot loading setting or something ....


I am not sure of how to deal with this. This is kind of urgent for me folks as I am doing Linux project at college.

Cheers.
 
Old 06-01-2007, 10:58 AM   #2
Brocolli
Member
 
Registered: May 2007
Distribution: PCLinuxOS 2007
Posts: 34

Rep: Reputation: 15
Although I am also a newbie, I have experienced this problem before. When you reinstalled windows, your grub installation which is on the master boot record (mbr) was overwritten. You need to reinstall grub. In my case (mepis 6), I boot with the livecd and from there reinstalled grub. I have also done this in fedora 6. I boot with the first cd and then type ' linux rescue '. I can give you the exact details for fedora 6, but I have seen that you're using mandriva.
 
Old 06-01-2007, 01:38 PM   #3
Gzou
Member
 
Registered: Apr 2006
Location: Quebec, Canada
Distribution: Xubuntu, Zenwalk, Slax, Gentoo
Posts: 39

Rep: Reputation: 16
Brocolli's right, when installing windows it automatically erases the MBR and puts a new one which doesn't point towards grub, leaving you only with windows when booting up

No matter what distro you've got, to fix the problem you're going to need to boot up your computer from a linux livecd. The Madriva CD should do (if you've still got it around) otherwise another Live CD like knoppix will work aswell.

Now, I've never installed Mandriva on my machine, but I have already accidentally screwed up my MBR. So madriva might have a program on their CD that can arrange grub. otherwise, here generic steps to getting grub up and working.

1. Boot up your computer from the live CD and get to a terminal (console) and make sure you have root privileges

2. Find out on what partition linux is residing and it's partition type (if you have no clue the command "parted -l" or "fdisk -l" can help)

3. mount the linux partition if it's not already mounted. to check is it is mounted, type "mount" and look in the list to see if your linux partition shows up.

Ex: fdisk -l showed me that my linux partition is /dev/hda1. So when typing mount I'm looking for :

/dev/hda1 on /mnt/hda1
or
/dev/hda1 on /media/hda1

If it doesn't show up then it isn't mounted. if it does show up then you can skip to step 5

4. before mounting a partition we need to create a directory as a mount point then mount it like so:

mkdir /mnt/hda1
mount -t filetype /dev/hda1 /mnt/hda1

where filetype is the file type of your partition that you discovered at step 2 (for xeample : xfs or reiserfs are file types)

5. Now we need to mount a proc, bind dev, and chroot to the linux partition.

mount -t proc none /mnt/hda1/proc
mount -o bind /dev /mnt/hda1/dev
chroot /mnt/hda1 /bin/bash

6. If you are sure that your grub is properly set up, then you can go to step 7. otherwise, you can check the configuration using a text editor to open /boot/grub/menu.lst.

Ex: vim /boot/grub/menu.lst
or
nano /boot/grub/menu.lst

7. type "grub-install /dev/hda", reboot, and it should work !
 
Old 06-01-2007, 06:49 PM   #4
ankz.upadhyay
LQ Newbie
 
Registered: Mar 2007
Location: Manchester
Distribution: Linux Mandriva 2007, Windows XP
Posts: 13

Original Poster
Rep: Reputation: 0
Lightbulb

Hey mate

This is excellent reply.

Fortunately I have got all 4 CDs of Linux Mandriva 2007 but unformtunately haven't got any Live CD so I have to find a way with installation cds.

If you could kind enough to tell me steps to do with installation cd then it would be great.

Thanks very much.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Windows on to linux machine dual boot chplat Fedora 2 01-18-2005 04:12 AM
How to dual boot a linux machine rwalkerphl Linux - Newbie 1 10-12-2004 11:35 PM
INstalling Dual boot with Linux first on the Machine Butterbroetchen Linux - General 2 06-23-2004 07:09 PM
Want dual boot Linux on XP machine marshouser Linux - Newbie 2 08-13-2003 10:23 PM
Best way to set up dual XP/Linux machine? The Burninator Linux - General 10 02-01-2003 07:08 PM


All times are GMT -5. The time now is 04:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration