LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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 01-14-2006, 01:50 PM   #1
spx2
Member
 
Registered: Dec 2005
Distribution: debian
Posts: 160

Rep: Reputation: 30
boot problem,windows reinstall?


i have windows xp,windows 2000,linux mandrake.
first on mbr it has lilo
i have
linux mandrake option
windows option
if i go to windows it gives me windows boot menu
between w2k and wxp.
now i want to reinstall w2k.
wouldnt this erase lilo ?
i think so.
what workarounds or solutions to this problem are there ?
i will provide any information necessary.
thank you
 
Old 01-14-2006, 02:16 PM   #2
saman007uk
Member
 
Registered: Dec 2003
Location: ~root
Distribution: Debian
Posts: 364

Rep: Reputation: 33
Backup the MBR using "dd", install Win 2000 and then restore the MBR. Then add the corresponding settings for booting Wind 2000 to your favourite boot manager.

MBR can be backed up using:
Code:
dd if=/dev/hda of=backup.file count=1 bs=448
And resored using:
Code:
dd of=/dev/hda if=backup.file bs=448 count=1
You should use a live CD to restore the backup.

Last edited by saman007uk; 01-14-2006 at 02:22 PM.
 
Old 01-14-2006, 02:49 PM   #3
spx2
Member
 
Registered: Dec 2005
Distribution: debian
Posts: 160

Original Poster
Rep: Reputation: 30
it seems i dont have any windows 2000 at hand...
i would like to try to reinstall over the old windows 2000
a new windows xp
would the configuration i have to do change in this casE ?
 
Old 01-14-2006, 03:13 PM   #4
saman007uk
Member
 
Registered: Dec 2003
Location: ~root
Distribution: Debian
Posts: 364

Rep: Reputation: 33
Quote:
Originally Posted by spx2
it seems i dont have any windows 2000 at hand...
i would like to try to reinstall over the old windows 2000
a new windows xp
would the configuration i have to do change in this casE ?
No, it's the same.
 
Old 01-14-2006, 03:46 PM   #5
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,140

Rep: Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123
Quote:
Originally Posted by saman007uk
Backup the MBR using "dd", install Win 2000 and then restore the MBR.
Certainly one option, however you'd best use 446 as the blocksize - 448 will get the first 2 bytes of the partition table as well. Bounds errors eventually cause unforseen errors ...

Or you could just re-install the loader from the (Linux) install CD in recovery mode.
 
Old 01-15-2006, 12:13 AM   #6
spx2
Member
 
Registered: Dec 2005
Distribution: debian
Posts: 160

Original Poster
Rep: Reputation: 30
how would i reinstall boot loader in recovery mode ? exactly...
i have mandrake 10.0 official 3 cds
ubuntu 5.1 one cd
and damnsmalllinux live cd..
could anyone give some steps for this ?
 
Old 01-15-2006, 12:20 AM   #7
spx2
Member
 
Registered: Dec 2005
Distribution: debian
Posts: 160

Original Poster
Rep: Reputation: 30
syg00 if partition looks like this

|------------------------------|--------------------------------
i imagine that the || zone is taken by 448 parameter
now if i do 446 its like this
|----------------------------|----------------------------------
so the difference from the first is that it doesnt take in account byte 447 and 448 otherwise its the
same.
wouldnt you agree with this ?
so its not about the FIRST 2 bytes
 
Old 01-15-2006, 03:05 AM   #8
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,140

Rep: Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123
Quote:
Originally Posted by spx2
how would i reinstall boot loader in recovery mode ? exactly...
Depends on the distro - have a look in the fora/wiki for the distro of choice.
Will be better than we can describe from the "outside".
Quote:
Originally Posted by spx2
so the difference from the first is that it doesnt take in account byte 447 and 448 otherwise its the
same.
wouldnt you agree with this ?
so its not about the FIRST 2 bytes
Read what I said - we were discussing the MBR, not a partition.
The MBR has an exact structure - 446 bytes for loader code, 64 bytes for partition table, 2 bytes for signature bytes.
Bytes 447 and 448 are the first two bytes of the partition table - and are potentialy very important to the health of a system.
 
Old 01-15-2006, 09:50 AM   #9
spx2
Member
 
Registered: Dec 2005
Distribution: debian
Posts: 160

Original Poster
Rep: Reputation: 30
i would like to use a disk to store this info on
would there be any distro to fit on one disk ?
it would suffice to have commands like ls,cp,mv,dd and maybe some ed or nano or maybe
vi for editing
and kernel and all that stuff plugged in there
what distro on a single diskette ?
ok ok...ill use a live cd altough the question above remains open

thank you very much for the explanation on mbr
i understood something new about it now...
i was planning on reading about it but i didnt felt
much like it so i left that ... for another time
 
Old 01-15-2006, 10:53 AM   #10
saman007uk
Member
 
Registered: Dec 2003
Location: ~root
Distribution: Debian
Posts: 364

Rep: Reputation: 33
Quote:
Originally Posted by spx2
i would like to use a disk to store this info on
would there be any distro to fit on one disk ?
it would suffice to have commands like ls,cp,mv,dd and maybe some ed or nano or maybe
vi for editing
and kernel and all that stuff plugged in there
what distro on a single diskette ?
ok ok...ill use a live cd altough the question above remains open

thank you very much for the explanation on mbr
i understood something new about it now...
i was planning on reading about it but i didnt felt
much like it so i left that ... for another time
You could store the backup file in a floppy or write it to a cd. It can be stored using:
Code:
dd of=/dev/hda if=backup.file bs=446 count=1
If you are just installing windows on an existing partition and are not going to change the location of the Linux OS, that all you need to do to restore the boot manager.
 
Old 01-15-2006, 01:37 PM   #11
Dtsazza
Member
 
Registered: Oct 2005
Location: Oxford, UK
Distribution: Debian Etch (w/ dual-boot XP for gaming)
Posts: 282

Rep: Reputation: 31
Quote:
Originally Posted by spx2
i would like to use a disk to store this info on
would there be any distro to fit on one disk ?
Well, that really depends on the size of your disk, though methinks it might be a bit personal to ask a man that...

If you mean floppy disks, it's hard to get a full distribution on there, naturally, but there are some fully-featured rescue-style disks out there. Tom's Root Boot is "The most GNU/Linux on one floppy disk" and it certainly has a lot of features - including ls, cp, mv, dd and much more. It eschews pico/nano though, since it includes vi as its default editorand presumably including two would be wasteful (it's worth learning vi to at least a "being able to use it" standard anyway). I've heard of a few others too, but Tom's does seem to be the most fully featured, and the one that comes up most often.

If you were thinking of business-card sized CDs, there are a few distros that will fit on one of these (with a 50Mb limit, IIRC). Again, it seems to be generally accepted that Damn Small Linux (DSL) is one of, if not the, best. Though you mention you already have one of their live CDs, so you can judge for yourself, and Google is always there if you fancy checking out other options!
 
Old 01-15-2006, 03:10 PM   #12
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Rep: Reputation: 113Reputation: 113
I think the whole matter can be simplified by using Lilo itself.

Log in Mandrake as root, click terminal, pop in a floppy and type
Code:
lilo -b /dev/fd0
After Lilo has been nuked by Win2k and you can access Mandrake at all time using the floppy. When you want Lilo back to the MBR, just boot up the floppy and type
Code:
lilo -b /dev/hda
(1) Lilo's way allows you access to Mandrake all the time via the bootable floppy.

(2) No need to worry about the 446 or 448 bytes problem. I have to say though it should be 446 because we then have 4x16 byes for the partition table plus 2 spare bytes at the end making up the 512 bytes of the MBR. syg00's point is to avoid hitting the partition table as the consequence can be serious.

Mandrake can be made bootable at any time via any Live CD and so I wouldn't worry if the floppy is lost.
 
Old 01-15-2006, 03:43 PM   #13
spx2
Member
 
Registered: Dec 2005
Distribution: debian
Posts: 160

Original Poster
Rep: Reputation: 30
i had a very rapid change of mind
i want just got a .iso of vector linux and plan on
putting that on the space ill get after formatting
the area where w2k supposed to be.
now how would i do this ?
just saved my partition table on a cd with dd
 
Old 01-15-2006, 03:46 PM   #14
saman007uk
Member
 
Registered: Dec 2003
Location: ~root
Distribution: Debian
Posts: 364

Rep: Reputation: 33
Vector Linux should detect the Mandrake install.
 
Old 01-15-2006, 03:54 PM   #15
saikee
Senior Member
 
Registered: Sep 2005
Location: Newcastle upon Tyne UK
Distribution: Any free distro.
Posts: 3,398
Blog Entries: 1

Rep: Reputation: 113Reputation: 113
You don't need to save the partition table just write down how many of them and the sizes because you can always rebuild it from scratch. I have rebuilt a couple of 60-partition partitions about dozen times without any loss of data.

Vector only needs about 5Gb for a install and it uses Lilo too.
 
  


Reply



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
reinstall windows, reinstall GRUB too? leupi Linux - Software 1 05-07-2005 10:50 AM
reinstall windows boot loader bruse Mandriva 5 02-10-2005 06:22 AM
Keep having to reinstall Windows...dunno what the problem is silentwhispers General 7 11-17-2004 03:17 PM
reinstall windows joejet Linux - General 1 04-06-2004 10:03 AM
How to Reinstall Windows on Dual Boot mrl Linux - Software 2 05-11-2001 11:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:53 PM.

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
Open Source Consulting | Domain Registration