Operating Systems's

Status
Not open for further replies.

godsownman

Padawan
I have recently connected a 2nd HDD and loaded Linux on it. After loading linux on it I faced a problem.

The problem is that this particular HDD is too be used on more than 1 computer.

But what happens is that when it is disconnected I cannot load windows also. But on reconnecting it I can load any one.

I get an error " GRUB boot loader error " !

What I feel is the problem is that since I loaded linux after I loaded windows the MBR file got rewritten and now for that reason I need to have the 2nd hdd connected, to it even to start my computer and work in the windows environment.

I know this may sound a bit confusing but what I want to say is that when the 2nd HDD is connected I can choose which OS I want to load. BUT with the HDD disconnected I cannot work on the computer at all. The error I get is LIKE the 'BSOD' ( blue screen of death) but its not a blue screen.

Can somebody please help me.

What I feel the 2 solutions are

:) Either I load windows after I load the Linux OS

:) Somebody please tell me how to instruct the comp to load windows by default without my intervention.


Thanks for the patience and the solution.
 

siriusb

Cyborg Agent
You got the problem right, alright. But installing windows after u install linux is not an option. Windows is deliberately made stupid so that it don't care what bootloader is in the mbr.
One solution that I know of is to run "fixmbr". Then, either, u can resinstall linux and ask it to install boot information only it's partition. Or use a linux boot floppy to boot into linux from then on.
 
OP
godsownman

godsownman

Padawan
how should I boot to linux using a floppy.

And in that case how am i supposed to use my comp.

Please somebody help .

When I installed linux it asked me if it should write in the MBR.

Suppose I say no then what will be the outcome.
 

ujjwal

Padawan
Basically GRUB (which is the linux boot loader) has a portion of itself located on your linux partition (which is on the 2nd hard disk), so when you transfer the hard disk, you are not able to start GRUB.

What you can do is to use the Windows loader to start grub, instead of the other way round, so you can load windows even when the hard disk has been taken to the other computer. Check the 2nd page of the Linux Tips & Tricks thread in the Open Source for info. You could also create a GRUB boot floppy to carry around with which to load your OS. Check this for info -

*www.gnu.org/software/grub/manual/html_node/Creating-a-GRUB-boot-floppy.html
 
OP
godsownman

godsownman

Padawan
Please tell me any other method of working any simpler method.

Can I not edit the MBR .

Can somebody please help me with that.


siriusb,

you told me to use "fixmbr" how does one use it.

If it is to be used in CMD it does not work.
 
D

Deleted member 5901

Guest
That's it. I am putting you on a warning for a month.In the meantime, if you ever advertise your forums even once, I will ban you for good.

ctrl_alt_del
 

ujjwal

Padawan
You should boot into your Windows XP cd (assuming that version of windows), select recovery console, and type "fixmbr".
 
OP
godsownman

godsownman

Padawan
Instead of selecting the MBR if I select the 1st boot record of the partition will it make a major difference to my computer.

Will it solve my problem and will i have the choice of loading Windows or Linux as an when I wish .

And most of all ,

be able to remove the HDD where linux is loaded without upsetting the windows installation.
 

ujjwal

Padawan
Allright, first as you wanted more info about fixmbr, have a look at this link. Now, using fixmbr will erase the linux boot loader from the master boot record, so for now you will not be able to boot into linux. But you can make the windows XP loader boot linux (check first post), and as no portion of the Windows boot loader resides on the second hard disk, there should not be a problem.
 
OP
godsownman

godsownman

Padawan
ujjwal said:
What you can do is to use the Windows loader to start grub, instead of the other way round, so you can load windows even when the hard disk has been taken to the other computer. Check the 2nd page of the Linux Tips & Tricks thread in the Open Source for info. You could also create a GRUB boot floppy to carry around with which to load your OS. Check this for info -

*www.gnu.org/software/grub/manual/html_node/Creating-a-GRUB-boot-floppy.html

Ujjwal,

sorry to bother you but can you please give me the exact link to that topic.

I cant seem to find it.

Please.
 
OP
godsownman

godsownman

Padawan
I found this is it this ior is it another one.

What does he mean by the first line ,

"For all those who do not want to install both windows and linux but do not want to overwrite their windows MBR."

amol_dan said:
For all those who do not want to install both windows and linux but do not want to overwrite their windows MBR.

This trick can help a bit provided you have windows 2k or XP

When installing linux, choose to install boot loader on the root partition or /boot partition(if any).

When you boot into linux mount your windows C drive to some directory e.g. /mnt/C

Launch a terminal, su to root, change to the directory where C drive is mounted.

Type this command.

dd if=/dev/<drive where boot loader is istalled> of=bootsect.lnx bs=512 count=1

e.g.

dd if=/dev/hda3 of=bootsect.lnx bs=512 count=1

Then come back to windows.

Add this line to boot.ini file

C:\BOOTSECT.LNX="<Your distribution name>"
 

kalpik

In Pursuit of "Happyness"
Try this link: *wiki.ubuntu.com//WindowsDualBootHowTo

I guess you are using Ubuntu Linux. Well even if u arnt, the trick works for other distros too!
 

ujjwal

Padawan
Hi,

That line means that this guide is intended for those who want to use their Windows boot loader, and not any other, to dual boot linux & windows.

By the way, which parts of the guide are you facing problems with?
 
OP
godsownman

godsownman

Padawan
Type this command.

dd if=/dev/<drive where boot loader is istalled> of=bootsect.lnx bs=512 count=1

e.g.

dd if=/dev/hda3 of=bootsect.lnx bs=512 count=1



This is the line that confuses me .

This is to be after I load Ubuntu right cause I have already loaded Ubuntu and I dont want to do it again.

After I do these steps what will I actually achieve.

Thanks.,

Also there is another option of not writtitng the MBR and writing the boot loader on the 1st sector of the partition.

By doing this what will I achive will I be able to load any OS as an when I wish and also remove the HDD when ever reqd.

Thanks a lot and sorry to bother you all repeatedly.
 

ujjwal

Padawan
You don't need to run the installation process again, but you need to install grub again on the /boot or / partitition. If the partition is, say, /dev/hdb1, you can run

Code:
grub-install /dev/hdb1

To find out which is the partition you need, type "mount" and check where /boot or / is mounted.

Now, you can use dd to copy the boot loader to a file, as mentioned by the guide.
 
OP
godsownman

godsownman

Padawan
Ujjwal will doing this enable me to remove the HDD and also will it remove whatever it added to the MBR.

Do I need to repair the MBR after that.
 

hafees

In the zone
I have recently connected a 2nd HDD and loaded Linux on it. After loading linux on it I faced a problem.

The problem is that this particular HDD is too be used on more than 1 computer.

But what happens is that when it is disconnected I cannot load windows also. But on reconnecting it I can load any one.

I get an error " GRUB boot loader error " !

What I feel is the problem is that since I loaded linux after I loaded windows the MBR file got rewritten and now for that reason I need to have the 2nd hdd connected, to it even to start my computer and work in the windows environment.

I know this may sound a bit confusing but what I want to say is that when the 2nd HDD is connected I can choose which OS I want to load. BUT with the HDD disconnected I cannot work on the computer at all. The error I get is LIKE the 'BSOD' ( blue screen of death) but its not a blue screen.

Can somebody please help me.

I think you have made your /boot partition in the other drive(the drive that u disconnected). In the /boot partition is where grub is installed. The MBR tries to call grub but it will not be there if u remove the other hard drive and will result in the error u just described.
The solution is make /boot partition in the drive that u use permanently.
To create a /boot mount point, first create some freespace on ur 1 st hard disk ( by 1st i mean the disk you use regularly). preferably from the begining of disk space (u can use partition magic to get some free space by moving ur first partition. All you need is a 15 MB (minimum) or 75 MB (recommended) free space. when u install linux, instead of auto partition assign mount points manually. and make this free space ( the 15 MB space in the begining of ur hard disk - I said beginning coz, it may not be bootable if ur free space is after the first 8 GB. This is a limitation that many bios have) as ur /boot mount point. You are free to create other mount points (like /, /home, linux swap etc) in any other drives. By doing so, grub will be installed in the 1 st drive. So even if u disconnect the 2nd drive grub can work properly. Ofcourse grub will fail if u select an operating system installed in your other drive.

If you want to know more details about installation pls ask here.
 
OP
godsownman

godsownman

Padawan
Can somebody tell me what will happen if I was to disconnect the 1st HDD and then load Linux will my problem be solved.

Will I be able to remove the HDD.

Thanks
 
Status
Not open for further replies.
Top Bottom