LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Dual Boot Unbuntu and Windows XP (Unbuntu Installed First). (http://www.linuxquestions.org/questions/linux-newbie-8/dual-boot-unbuntu-and-windows-xp-unbuntu-installed-first-712393/)

Mad4Macintosh 03-17-2009 10:22 PM

Dual Boot Unbuntu and Windows XP (Unbuntu Installed First).
 
Hi, I'm new here! :newbie:
I have misunderstood my friends request and installed Unbuntu on his Desktop. Now, He wants to Dual boot Windows!! I Have Customized this Unbuntu Installation and I don't want to erase it. I've searched Multiple Forms but no awnser! :mad: So I want somebody to please give me the exact code I need to dual boot.
Here is my information

Windows XP Pro Installed on extended partion on my internal HD (SDA6) called "Windows".
Any help Would be greatly aprechiated!! :confused::)

Nibbl3r 03-17-2009 11:40 PM

can you post some more information ?

fdisk -l would be good just to verify
Because maybe you have more than one disc and so on. If you know you just have one disc continue

If windows is already installed and you are using Grub

add this line to /boot/grub/menu.lst


title Windows XP
rootnoverify (hd0,6)
chainloader +1

you can normally open menu.lst only with root...

i recommend doing
sudo kate /boot/grub/menu.lst
scroll down and add what i gave you here.. you maybe want to change the 6 to another number while i dont know how many partitions youve got!

hariarr 03-18-2009 12:23 AM

You need to re-install grub
 
Quote:

Originally Posted by Mad4Macintosh (Post 3478927)
Hi, I'm new here! :newbie:
I have misunderstood my friends request and installed Unbuntu on his Desktop. Now, He wants to Dual boot Windows!! I Have Customized this Unbuntu Installation and I don't want to erase it. I've searched Multiple Forms but no awnser! :mad: So I want somebody to please give me the exact code I need to dual boot.
Here is my information

Windows XP Pro Installed on extended partion on my internal HD (SDA6) called "Windows".
Any help Would be greatly aprechiated!! :confused::)

You installed Ubuntu first rite??? and now, when u installed xp, grub (boot loader of ubuntu) gone... so u need 2 re-install grub..

to do this,

1> Boot into a Live CD (any flavour... ubuntu live cd is perfect)

2> open Gnome Terminal

3> type
sudo grub

4> you'll get grub prompt. (somenth lyk grub>)
then type
find /boot/grub/stage1

5> You'll get some output like (hd0,1)
( am assuming that the output is (hd0,1) )

6> type
root (hd0,1)
setup (hd0)
quit




Remove the LiveCD and reboot... you can see the grub bootloader... if u cant see the windows entry in that,

do as nibbl3r says.. it'll work only afrer re-installing grub.....

hariarr 03-18-2009 12:26 AM

NB:-

sudo gedit /boot/grub/menu.lst will be perfect because "kate' is not installed by default...

and add

tittle windows
rootnoverify (hd0,0)
chainloader +1

Mad4Macintosh 03-18-2009 12:47 AM

Thanks for all the help!
 
I will be trying all off these. get back to you soon. :D:D

Mad4Macintosh 03-18-2009 12:54 AM

Another Question
 
exactly were do I insert the code in my boot menu file.
Heres my boot file!

"default 0
timeout 0
hiddenmenu

title Ubuntu 8.10, kernel 2.6.27-11-server
root
kernel /boot/vmlinuz-2.6.27-11-server root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-server
quiet

title Ubuntu 8.10, kernel 2.6.27-11-server (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-11-server root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-11-server

title Ubuntu 8.10, kernel 2.6.27-11-generic
root
kernel /boot/vmlinuz-2.6.27-11-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-generic
quiet

title Ubuntu 8.10, kernel 2.6.27-11-generic (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-11-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-11-generic

title Ubuntu 8.10, kernel 2.6.27-7-generic
root
kernel /boot/vmlinuz-2.6.27-7-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-7-generic
quiet

title Ubuntu 8.10, kernel 2.6.27-7-generic (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-7-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-7-generic

title Ubuntu 8.10, memtest86+
root
kernel /boot/memtest86+.bin
quiet"

hariarr 03-18-2009 06:01 AM

Quote:

Originally Posted by Mad4Macintosh (Post 3479025)
exactly were do I insert the code in my boot menu file.
Heres my boot file!

"default 0
timeout 0
hiddenmenu

title Ubuntu 8.10, kernel 2.6.27-11-server
root
kernel /boot/vmlinuz-2.6.27-11-server root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-server
quiet

title Ubuntu 8.10, kernel 2.6.27-11-server (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-11-server root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-11-server

title Ubuntu 8.10, kernel 2.6.27-11-generic
root
kernel /boot/vmlinuz-2.6.27-11-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-generic
quiet

title Ubuntu 8.10, kernel 2.6.27-11-generic (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-11-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-11-generic

title Ubuntu 8.10, kernel 2.6.27-7-generic
root
kernel /boot/vmlinuz-2.6.27-7-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-7-generic
quiet

title Ubuntu 8.10, kernel 2.6.27-7-generic (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-7-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-7-generic

title Ubuntu 8.10, memtest86+
root
kernel /boot/memtest86+.bin
quiet"


default 0
timeout 5
hiddenmenu

title Ubuntu 8.10, kernel 2.6.27-11-server
root
kernel /boot/vmlinuz-2.6.27-11-server root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-server
quiet

title Ubuntu 8.10, kernel 2.6.27-11-server (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-11-server root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-11-server

title Ubuntu 8.10, kernel 2.6.27-11-generic
root
kernel /boot/vmlinuz-2.6.27-11-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-generic
quiet

title Ubuntu 8.10, kernel 2.6.27-11-generic (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-11-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-11-generic

title Ubuntu 8.10, kernel 2.6.27-7-generic
root
kernel /boot/vmlinuz-2.6.27-7-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro quiet splash
initrd /boot/initrd.img-2.6.27-7-generic
quiet

title Ubuntu 8.10, kernel 2.6.27-7-generic (recovery mode)
root
kernel /boot/vmlinuz-2.6.27-7-generic root=UUID=e9956447-7cf9-42f4-b169-bc3cd2e58975 ro single
initrd /boot/initrd.img-2.6.27-7-generic

title Ubuntu 8.10, memtest86+
root
kernel /boot/memtest86+.bin
quiet

tittle windows
rootnoverify (hd0,0)
chainloader +1

hariarr 03-18-2009 06:02 AM

Hey

did u reinstalled grub???

Is your prob solved???

hariarr 03-18-2009 06:04 AM

Quote:

default 0
timeout 5
hiddenmenu
make timeout to at least 5 (5 secs)
otherwise u cant see the list....

yancek 03-18-2009 09:22 AM

You need to post your fdisk -l output as previously suggested. You indicated xp was on a logical partition in your extended partition and if you do a search at the microsoft site, you will find xp doesn't boot from a logical partition unless its boot files are on a primary partition.

Mad4Macintosh 03-18-2009 09:40 AM

Is there a way I can boot off the partition from inside unbuntu? because I really don't feel like rebooting a bunch of times. :happy:

Mad4Macintosh 03-18-2009 04:03 PM

Help Urgent!!
 
I Put The code at the the bottom of the grub file and, Now I cant even boot Unbuntu! Ive tryed recovery mode, Doesn't work. Ive Tryed Wondows and says I'm missing hal.dll. SOmeone please help me. I'm In a Live CD right know.:mad::(

yancek 03-18-2009 05:29 PM

Are you using the Ubuntu Live CD? If you have the Ubuntu CD, you can load it and then open a terminal window and enter the command "sudo fdisk -l' to get partition information to post here. Without knowing that, there is no way for anyone to accurately give you information.

In your first post, you indicate xp is on sda6 which would be (hd0,5) to Grub. Was xp on this computer before you installed Ubuntu? Did you install xp after Ubuntu? Your post of the menu.lst file shows windows on (hd0,0) which would be sda1, first partition of first drive. Where is it?

Nibbl3r 03-18-2009 11:28 PM

Seriously you gotta answer some of our questions too otherwise we can just give you general advice which will bring you in a situation which you end up beeing stuck!

do the fdisk -l "you also should be able to do this on the livedisk" and post it here..! Simply removing the entries you got in your menu.lst should work out to start ubuntu.

Please post this fdisk -l
Tell us all the things you modified/did during the first time you posted this. Maybe you even considering to post the whole menu.lst again.

The more information the more specific the answers :-)
thank you!

Mad4Macintosh 03-19-2009 03:31 PM

Sorry I've been at work. Here is my info
Disk identifier: 0x48484848

Device Boot Start End Blocks Id System
/dev/sda2 40 19452 155934922+ 5 Extended
/dev/sda5 * 8987 19452 84068145 83 Linux
/dev/sda6 40 8986 71866714+ 7 HPFS/NTFS

Partition table entries are not in disk order
ubuntu@ubuntu:~$


All times are GMT -5. The time now is 08:54 AM.