Win7 and dual Ubuntu 9.10 partitions
I have a Windows Vista box upgraded to Win7 and then installed two (yes two) instances of Ubuntu 9.10 on the same box.
I don't need one of them (it had a corrupted install ISO disk) and want to remove the partition using fdisk or parted or similar utility. How do I know which instance of Ubuntu is used for each partition I selected when I reboot the box? There are two different versions displayed and I always select the newer one but how do I know if I remove the right one or not?? Also, when I restart in Win7, the BIOS/OS wants to check the disk everytime and now I've started skipping this check (it takes several mins). thx. |
first the question to be asked is .. are both instances of linux on the same partition ? or is it on a different partition?
also type cat /boot/grub/grub.cfg in the terminal and post the output here |
asookazian@asookazian-desktop:/opt/eclipse:11:22 AM:$cat /boot/grub/grub.cfg
# # DO NOT EDIT THIS FILE # # It is automatically generated by /usr/sbin/grub-mkconfig using templates # from /etc/grub.d and settings from /etc/default/grub # ### BEGIN /etc/grub.d/00_header ### if [ -s /boot/grub/grubenv ]; then have_grubenv=true load_env fi set default="0" if [ ${prev_saved_entry} ]; then saved_entry=${prev_saved_entry} save_env saved_entry prev_saved_entry= save_env prev_saved_entry fi insmod ext2 set root=(hd0,7) search --no-floppy --fs-uuid --set e9d21885-b231-41b8-9892-8f0883fd04f8 if loadfont /usr/share/grub/unicode.pf2 ; then set gfxmode=640x480 insmod gfxterm insmod vbe if terminal_output gfxterm ; then true ; else # For backward compatibility with versions of terminal.mod that don't # understand terminal_output terminal gfxterm fi fi if [ ${recordfail} = 1 ]; then set timeout=-1 else set timeout=10 fi ### END /etc/grub.d/00_header ### ### BEGIN /etc/grub.d/05_debian_theme ### set menu_color_normal=white/black set menu_color_highlight=black/white ### END /etc/grub.d/05_debian_theme ### ### BEGIN /etc/grub.d/10_linux ### menuentry "Ubuntu, Linux 2.6.31-20-generic" { recordfail=1 if [ -n ${have_grubenv} ]; then save_env recordfail; fi set quiet=1 insmod ext2 set root=(hd0,7) search --no-floppy --fs-uuid --set e9d21885-b231-41b8-9892-8f0883fd04f8 linux /boot/vmlinuz-2.6.31-20-generic root=UUID=e9d21885-b231-41b8-9892-8f0883fd04f8 ro quiet splash initrd /boot/initrd.img-2.6.31-20-generic } menuentry "Ubuntu, Linux 2.6.31-20-generic (recovery mode)" { recordfail=1 if [ -n ${have_grubenv} ]; then save_env recordfail; fi insmod ext2 set root=(hd0,7) search --no-floppy --fs-uuid --set e9d21885-b231-41b8-9892-8f0883fd04f8 linux /boot/vmlinuz-2.6.31-20-generic root=UUID=e9d21885-b231-41b8-9892-8f0883fd04f8 ro single initrd /boot/initrd.img-2.6.31-20-generic } menuentry "Ubuntu, Linux 2.6.31-14-generic" { recordfail=1 if [ -n ${have_grubenv} ]; then save_env recordfail; fi set quiet=1 insmod ext2 set root=(hd0,7) search --no-floppy --fs-uuid --set e9d21885-b231-41b8-9892-8f0883fd04f8 linux /boot/vmlinuz-2.6.31-14-generic root=UUID=e9d21885-b231-41b8-9892-8f0883fd04f8 ro quiet splash initrd /boot/initrd.img-2.6.31-14-generic } menuentry "Ubuntu, Linux 2.6.31-14-generic (recovery mode)" { recordfail=1 if [ -n ${have_grubenv} ]; then save_env recordfail; fi insmod ext2 set root=(hd0,7) search --no-floppy --fs-uuid --set e9d21885-b231-41b8-9892-8f0883fd04f8 linux /boot/vmlinuz-2.6.31-14-generic root=UUID=e9d21885-b231-41b8-9892-8f0883fd04f8 ro single initrd /boot/initrd.img-2.6.31-14-generic } ### END /etc/grub.d/10_linux ### ### BEGIN /etc/grub.d/20_memtest86+ ### menuentry "Memory test (memtest86+)" { linux16 /boot/memtest86+.bin } menuentry "Memory test (memtest86+, serial console 115200)" { linux16 /boot/memtest86+.bin console=ttyS0,115200n8 } ### END /etc/grub.d/20_memtest86+ ### ### BEGIN /etc/grub.d/30_os-prober ### menuentry "Dell Utility Partition (on /dev/sda1)" { insmod fat set root=(hd0,1) search --no-floppy --fs-uuid --set 07d7-0907 drivemap -s (hd0) ${root} chainloader +1 } menuentry "Windows 7 (loader) (on /dev/sda3)" { insmod ntfs set root=(hd0,3) search --no-floppy --fs-uuid --set dce817b3e8178b42 chainloader +1 } ### END /etc/grub.d/30_os-prober ### ### BEGIN /etc/grub.d/40_custom ### # This file provides an easy way to add custom menu entries. Simply type the # menu entries you want to add after this comment. Be careful not to change # the 'exec tail' line above. ### END /etc/grub.d/40_custom ### |
Quote:
[sudo] password for asookazian: Disk /dev/sda: 320.1 GB, 320072933376 bytes 255 heads, 63 sectors/track, 38913 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0xd8000000 Device Boot Start End Blocks Id System /dev/sda1 1 5 40131 de Dell Utility /dev/sda2 6 1311 10485760 7 HPFS/NTFS /dev/sda3 * 1311 26258 200386344 7 HPFS/NTFS /dev/sda4 26259 38913 101651287+ 5 Extended /dev/sda5 32145 38631 52106796 83 Linux /dev/sda6 38632 38913 2265133+ 82 Linux swap / Solaris /dev/sda7 26259 31897 45295204+ 83 Linux /dev/sda8 31898 32144 1983996 82 Linux swap / Solaris Partition table entries are not in disk order |
It seems both instances refer to the same partition /dev/sda7 to be sure you can do
Code:
/bin/ls -lF /dev/disk/by-uuid/ |
I tried to delete /dev/sda5 and /dev/sda6. Results:
Code:
asookazian@asookazian-desktop:/dev:10:53 PM:$sudo fdisk /dev/sda |
asookazian@asookazian-desktop:/dev:10:59 PM:$sudo fdisk -l
Disk /dev/sda: 320.1 GB, 320072933376 bytes 255 heads, 63 sectors/track, 38913 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0xd8000000 Device Boot Start End Blocks Id System /dev/sda1 1 5 40131 de Dell Utility /dev/sda2 6 1311 10485760 7 HPFS/NTFS /dev/sda3 * 1311 26258 200386344 7 HPFS/NTFS /dev/sda4 26259 38913 101651287+ 5 Extended /dev/sda5 26259 31897 45295204+ 83 Linux /dev/sda6 31898 32144 1983996 82 Linux swap / Solaris |
Please help! I restarted Ubuntu and now seeing the following on the screen:
GRUB loading. error: no such partition grub rescue> ls (hd0) (hd0,6) (hd0,5) (hd0,3) (hd0,2) (hd0,1) I have valuable docs/pics on my Win7 partition that are not backed up! Any way to fix this or undo the deleting of the partitions? I only care about the Win7 currently. Should I boot using Ubuntu 9.10 ISO?? then what? |
Quote:
You can try Super GRUB: http://www.supergrubdisk.org/wiki/Boot_Problems Regards, --Andrew |
Can't undo delete, but your windows files are fine; even if you can't boot an operating system from HD you can still rescue them if need be... (Mount /dev/sda3 [or whatever the windows partition is] from a live CD.)
So GRUB is trying to boot the partition you deleted. Look in your /boot/grub/grub.cfg, there is a line that reads: set root=(hd0,7) I'm looking at the one in the header, line 15 or so, not the occurence of the same line in the menu entries. If that were changed to set root=(hd0,3) then it should try to boot windows instead. Boot from Ubuntu Live CD, mount the un-deleted Ubuntu partiton and make the change in /boot/grub/grub.cfg To check if that works, startup normally, grub rescue> set root=(hd0,3) grub rescue> boot And hopefully Windows will boot. When you say you only care about Windows, does that mean you want to see the end of the Ubuntu partitions altogether, or just that you want them repaired but don't have anything of value on them? If the latter, there's a very easy solution: reinstall Ubuntu over the old Linux partition, thus reinstalling GRUB and fixing everything. Edit: Argh; complete brain fail. Don't bother editing /boot/grub/grub.cfg; it won't do anything. Sorry. But Code:
grub rescue> set root=(hd0,3) |
Quote:
Then, re-install the linux as above. you shouldn't lose anything, but copy it anyway, just in case. |
Quote:
Here is the output on Win7 DVD boot: Code:
No boot device available |
When I do a 'cd /boot/grub' and then 'ls -la' I only see 'grubenv' file. Nothing else.
|
When I type:
grub rescue> set root=(hd0,3) grub rescue> boot I get: Unknown command 'boot' Now what? |
#
Insert Win 7 installation DVD and boot from DVD drive. While in some older systems you may have to change boot order through system BIOS, most newer systems allow booting from DVD without changing boot order by simply clicking on any key when prompted to doing so. # Step 2 Choose your default "Language", "Time", and "keyboard Input" on the first window and click next. # Step 3 You're now presented with 3 choices. Click on "Repair Your Computer" to gain access to the System Recovery window. Now choose "Command Prompt" in order to run the desired utility which is called "bootsect.exe". Bootsect is located inside the boot folder so change your directory to boot. Now run "bootsect /nt60 C:\" if you had Win 7 initially installed in the C partition. Alternatively, you can run "bootsect /nt60 SYS" or "bootsect /nt60 ALL" to repair the system partition or all partitions. Eject the DVD, and restart computer. Your computer should now boot Win 7 again. |
All times are GMT -5. The time now is 08:16 PM. |