linux bootmenu can change or not?, wish to set windows xp as the default 1
linux bootmenu can change or not?, wish to set windows xp as the default 1
|
|
Apr 9 2005, 11:52 AM, updated 21y ago
Show posts by this member only | Post
#1
|
![]()
Junior Member
19 posts Joined: Jan 2003 |
i have two operating in my harddisk, one is windows xp and the other 1 is linux redhat 9.0. after i installed the linux redhat 9.0, the system use the GRUB as the default boot menu, if i want to set windows as the default bootmenu can?because i wish to delete my linux part in my system, so i afraid this will cause problem if the default bootmenu is linux.
|
|
|
|
|
|
Apr 9 2005, 02:00 PM
Show posts by this member only | Post
#2
|
|
Moderator
6,181 posts Joined: Oct 2004 |
#Disclaimer: The steps written here are experimental as I have yet to test it and it is advisable for everyone to back up their important data first as these steps can make one of the operating systems unbootable.
#These steps are taken from an old Linux book which I found in the office. #I won't be held responsible for any loss of data. #Here goes nothing! Note down the RH 9.0 boot partition as it is VERY important for linux to be able to boot. If we FORGOT what our hda number was, from the terminal window, type: df, then determine which hda# is associated with the /boot partition. After that, type this: dd if=/dev/hda1 of=boot.lnx bs=512 count=1 (Assuming the boot partition is at hda1) A file named "boot.lnx" should now have been created in root's home directory. Do an "ls -l boot.lnx" to confirm this. Insert a DOS formatted floppy diskette into the floppy drive and while still in the terminal window, type: mcopy boot.lnx a: (This uses MTOOL's "mcopy" command to copy a file from a Linux partition to a DOS formatted diskette) Remove the diskette and type shutdown -r now Well, if the RH 9.0 has overwritten the MBR then.. We must at least make the MBR native to Windows first... I'm sure that WIndows XP Recovery Console can do that... So after running the recovery console to reset the MBR, boot into Windows XP should be no problem at all. Log onto Windows with Administrator priviledge and go to command prompt and change to C: drive. Insert the DOS floppy diskette that contains the boot.lnx file into the floppy drive and then copy it to C:\ using the DOS copy command or Windows Explorer. Next, we need to edit the BOOT.INI file so that it knows about boot.lnx. Now this is tricky. We have to find out where is the boot.ini file for our Windows. BOOT.INI should be a system file and hidden from view. When we type: attrib boot.ini The attributes of BOOT.INI should be A(archive), S(system), and H(hidden). In order to edit BOOT.INI, we will need to change its attributes first. Type: attrib -s -h boot.ini Now that BOOT.INI has been unprotected, we can either edit it from DOS with EDIT.COM or from Windows with NOTEPAD. If we choose the latter, leave the command prompt window open for the time being since we will need to change BOOT.INI's attributes back to SH later. Inside the editor of our choice, add a line to the end of the file that contains the following: c:\boot.lnx="Red Hat Linux v9.0" (We can name it to any name) Depending on how many copies of Windows you have installed, your BOOT.INI may now look SOMETHING like this: [boot loader] timeout=30 default=multi(0)disk(0)rdisk(0)partition(1)\WINNT [operating systems] multi(0)disk(0)rdisk(0)partition(1)\WINNT="Microsoft Windows XP Professional" /fastdetect c:\boot.lnx="Red Hat Linux v8.0" Save the changes we made to BOOT.INI and then return to the command prompt and type: attrib +s +h boot.ini If we wish to change the order of the selections in the boot manager screen (e.g. to make Linux appear before Windows), just change the order of the relevant lines in BOOT.INI. Likewise, if we wish Linux to be the default selection, change the text after the "default=" line to: default=c:\boot.lnx Reboot the computer and the Windows boot manager should now provide the added option to boot into Linux. Select "Linux" and notice that we will be taken to the Linux boot manager (probably GRUB) screen first. Finally, within GRUB, select "Red Hat Linux (2.4.xx-xx)" and Linux will start its regular boot process. #If we still can boot into Linux and Windows, then..... Cheers! #What do you guys think? This post has been edited by kons: Apr 9 2005, 02:06 PM |
|
|
Apr 9 2005, 02:03 PM
Show posts by this member only | Post
#3
|
|
Moderator
6,181 posts Joined: Oct 2004 |
By the way, if we don't feel like taking the risk.
Using GRUB to boot windows is perfectly SAFE. I've been booting it every single day for 1 year now... My windows still very very healthy. If we want to delete the Linux Partition.. It's fine. After deletion, we can use Windows XP recovery console to recover our MBR! That is much easier. Cheers! |
|
|
Apr 12 2005, 05:21 PM
Show posts by this member only | Post
#4
|
![]() ![]() ![]()
Junior Member
307 posts Joined: Jan 2003 |
if u really want to remove linux, just have partitionmagic, remove linux partition, boot into dos, run fdisk /mbr. this should recover ur original mbr.
it not, just edit the grub file, make the sure that default=0 refers to windows line (usually 0 refer to linux, then 1 refer to windows) |
|
|
Apr 12 2005, 05:41 PM
Show posts by this member only | Post
#5
|
|
Moderator
6,181 posts Joined: Oct 2004 |
QUOTE(badutman @ Apr 12 2005, 05:21 PM) if u really want to remove linux, just have partitionmagic, remove linux partition, boot into dos, run fdisk /mbr. this should recover ur original mbr. If we wish to get rid of any other partition except Windows XP own partition, we can use the disk management utility inside Windows XP. There's no need for Partition Magic.it not, just edit the grub file, make the sure that default=0 refers to windows line (usually 0 refer to linux, then 1 refer to windows) I haven't found out the way to boot into dos from Windows XP, well, actually, we can just boot from Windows XP CD and choose recovery. At the recovery console, just type fixmbr. Cheers! |
|
|
Apr 12 2005, 06:00 PM
Show posts by this member only | Post
#6
|
![]() ![]() ![]()
Junior Member
307 posts Joined: Jan 2003 |
QUOTE(kons @ Apr 12 2005, 05:41 PM) If we wish to get rid of any other partition except Windows XP own partition, we can use the disk management utility inside Windows XP. There's no need for Partition Magic. yayayaa forgot that on that one I haven't found out the way to boot into dos from Windows XP, well, actually, we can just boot from Windows XP CD and choose recovery. At the recovery console, just type fixmbr. Cheers! |
| Change to: | 0.0148sec
0.58
5 queries
GZIP Disabled
Time is now: 24th December 2025 - 12:30 PM |