LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 08-19-2009, 08:45 AM   #1
newb66
LQ Newbie
 
Registered: Aug 2009
Posts: 4

Rep: Reputation: 0
Installed Ubuntu twice, and would like delete one of them


Good day. I have installed Ubuntu 9.04 twice. I want to use first one(/dev/sda1), so I have to delete second one.
But it seems, system read /boot/grub/menu.lst file from OS that was installed second.
How can I properly delete second installed Ubuntu?

Thanks for attention.
 
Old 08-19-2009, 09:10 AM   #2
mr51m0n
LQ Newbie
 
Registered: Nov 2008
Posts: 17

Rep: Reputation: 0
Whats the output of

Code:
fdisk -l
as root?

Whats in /boot/grub/menu.lst ?

mr51m0n
 
Old 08-20-2009, 03:34 AM   #3
newb66
LQ Newbie
 
Registered: Aug 2009
Posts: 4

Original Poster
Rep: Reputation: 0
Command:
Code:
fdisk -l
Result:
Code:
Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00085414

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       18969   152368461   83  Linux
/dev/sda2           18970       19457     3919860    5  Extended
/dev/sda5           19296       19457     1301233+  82  Linux swap / Solaris
/dev/sda6           18970       19273     2441817   83  Linux
/dev/sda7           19274       19295      176683+  82  Linux swap / Solaris

Partition table entries are not in disk order




Quote:
Whats in /boot/grub/menu.lst ?
menu.lst of first installed system:
Code:
title		Ubuntu 9.04, kernel 2.6.28-11-generic
uuid		e73811ca-e605-40f1-aa6d-b062b54a1d14
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=e73811ca-e605-40f1-aa6d-b062b54a1d14 ro quiet splash 
initrd		/boot/initrd.img-2.6.28-11-generic
quiet

title		Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode)
uuid		e73811ca-e605-40f1-aa6d-b062b54a1d14
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=e73811ca-e605-40f1-aa6d-b062b54a1d14 ro  single
initrd		/boot/initrd.img-2.6.28-11-generic

title		Ubuntu 9.04, memtest86+
uuid		e73811ca-e605-40f1-aa6d-b062b54a1d14
kernel		/boot/memtest86+.bin
quiet
menu.lst of second installed system(that need to be removed):
Code:
## ## End Default Options ##

title		Ubuntu 9.04, kernel 2.6.28-11-generic
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=d174aa04-2d37-4b4c-ba5d-623d4f768111 ro quiet splash 
initrd		/boot/initrd.img-2.6.28-11-generic
quiet

title		Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode)
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=d174aa04-2d37-4b4c-ba5d-623d4f768111 ro  single
initrd		/boot/initrd.img-2.6.28-11-generic

title		Ubuntu 9.04, memtest86+
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/memtest86+.bin
quiet

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.
title		Other operating systems:
root


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, kernel 2.6.28-11-generic (on /dev/sda1)
root		(hd0,0)
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=e73811ca-e605-40f1-aa6d-b062b54a1d14 ro quiet splash 
initrd		/boot/initrd.img-2.6.28-11-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode) (on /dev/sda1)
root		(hd0,0)
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=e73811ca-e605-40f1-aa6d-b062b54a1d14 ro single 
initrd		/boot/initrd.img-2.6.28-11-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, memtest86+ (on /dev/sda1)
root		(hd0,0)
kernel		/boot/memtest86+.bin  
savedefault
boot
 
Old 08-20-2009, 03:41 AM   #4
mobinskariya
Member
 
Registered: Sep 2007
Location: Kerala, India
Distribution: ubuntu 10.04
Posts: 367

Rep: Reputation: 55
i think you need to format the /dev/sda6 and restore the grub on /dev/sda1.. may be the grub is written to your mbr.. so what you have to do is just format the second ubuntu..

Last edited by mobinskariya; 08-20-2009 at 03:45 AM.
 
Old 08-20-2009, 04:53 AM   #5
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
What puzzled me is where ever you installed GRUB of the second installation it should have both installation in its menu.lst
If you started UBUNTU which choices are presented which ?
 
Old 08-21-2009, 03:29 AM   #6
newb66
LQ Newbie
 
Registered: Aug 2009
Posts: 4

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by ronlau9 View Post
What puzzled me is where ever you installed GRUB of the second installation it should have both installation in its menu.lst
If you started UBUNTU which choices are presented which ?
In the menu.lst of second installed system
Code:
title		Ubuntu 9.04, kernel 2.6.28-11-generic
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=d174aa04-2d37-4b4c-ba5d-623d4f768111 ro quiet splash 
initrd		/boot/initrd.img-2.6.28-11-generic
quiet

title		Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode)
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=d174aa04-2d37-4b4c-ba5d-623d4f768111 ro  single
initrd		/boot/initrd.img-2.6.28-11-generic

title		Ubuntu 9.04, memtest86+
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/memtest86+.bin
quiet
thats presents firstly installed system.


and

Code:
title		Other operating systems:
root


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, kernel 2.6.28-11-generic (on /dev/sda1)
root		(hd0,0)
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=e73811ca-e605-40f1-aa6d-b062b54a1d14 ro quiet splash 
initrd		/boot/initrd.img-2.6.28-11-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode) (on /dev/sda1)
root		(hd0,0)
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=e73811ca-e605-40f1-aa6d-b062b54a1d14 ro single 
initrd		/boot/initrd.img-2.6.28-11-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, memtest86+ (on /dev/sda1)
root		(hd0,0)
kernel		/boot/memtest86+.bin  
savedefault
boot
thats presents second installed system.

So, do I need to format /dev/sda6 , and that's all?
 
Old 08-21-2009, 03:40 AM   #7
mobinskariya
Member
 
Registered: Sep 2007
Location: Kerala, India
Distribution: ubuntu 10.04
Posts: 367

Rep: Reputation: 55
isnt it the other way..
Code:
title		Ubuntu 9.04, kernel 2.6.28-11-generic
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=d174aa04-2d37-4b4c-ba5d-623d4f768111 ro quiet splash 
initrd		/boot/initrd.img-2.6.28-11-generic
quiet

title		Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode)
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=d174aa04-2d37-4b4c-ba5d-623d4f768111 ro  single
initrd		/boot/initrd.img-2.6.28-11-generic

title		Ubuntu 9.04, memtest86+
uuid		d174aa04-2d37-4b4c-ba5d-623d4f768111
kernel		/boot/memtest86+.bin
quiet
the above represents the ubuntu installed second

and the following represents the first ubuntu..
Code:
title		Other operating systems:
root


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, kernel 2.6.28-11-generic (on /dev/sda1)
root		(hd0,0)
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=e73811ca-e605-40f1-aa6d-b062b54a1d14 ro quiet splash 
initrd		/boot/initrd.img-2.6.28-11-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, kernel 2.6.28-11-generic (recovery mode) (on /dev/sda1)
root		(hd0,0)
kernel		/boot/vmlinuz-2.6.28-11-generic root=UUID=e73811ca-e605-40f1-aa6d-b062b54a1d14 ro single 
initrd		/boot/initrd.img-2.6.28-11-generic
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title		Ubuntu 9.04, memtest86+ (on /dev/sda1)
root		(hd0,0)
kernel		/boot/memtest86+.bin  
savedefault
boot
you said that you first installed ubuntu on /dev/sda1.. am i right? just try formatting sda6.. after all learning linux means experimentation. Also please don't forget to mention the result here.

Last edited by mobinskariya; 08-21-2009 at 03:43 AM.
 
Old 08-21-2009, 04:44 AM   #8
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
Using the option presented to you when UBUNTU is booting and knowing that UBUNTU is using UUID to boot we can determine which UBUNTu is booting
The next command will give you the UUID
ls -l(L lower case) /dev/disk/by-uuid
than you know for certain with UBUNTU is booting
 
Old 09-01-2009, 08:27 AM   #9
newb66
LQ Newbie
 
Registered: Aug 2009
Posts: 4

Original Poster
Rep: Reputation: 0
Code:
 ls -l /dev/disk/by-uuid
gave me following:

Code:
total 0
lrwxrwxrwx 1 root root 10 2009-08-31 16:04 2dd69543-d290-461a-8cf5-3f6f22dac31c -> ../../sda5
lrwxrwxrwx 1 root root 10 2009-08-31 16:04 bf97e41e-d28f-43b1-a61f-1786cfa0db2f -> ../../sda7
lrwxrwxrwx 1 root root 10 2009-08-31 16:04 d174aa04-2d37-4b4c-ba5d-623d4f768111 -> ../../sda6
lrwxrwxrwx 1 root root 10 2009-08-31 16:04 e73811ca-e605-40f1-aa6d-b062b54a1d14 -> ../../sda1
and as
Code:
Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       18969   152368461   83  Linux
I have to format /dev/sda6/, because my system is on /dev/sda1/.
 
Old 09-01-2009, 09:21 AM   #10
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471

Rep: Reputation: 40
man grub-install?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Delete Ubuntu kernels from dual-boot vista/ubuntu laptop? Leon14344 Linux - Laptop and Netbook 1 06-22-2009 11:32 PM
How to delete installed *.bin files Akwete Linux - General 5 03-09-2007 02:19 AM
Can I delete RPM Packages from where I downloaded them AFTER they are installed? Balarabay1 SUSE / openSUSE 3 05-27-2006 10:18 PM
can i delete compiled folder after installed the software shlinux SUSE / openSUSE 5 04-21-2006 04:34 AM
Can't view or delete installed programs in mandrake Ulrik_Uppkastar Linux - Software 1 11-30-2003 02:08 PM


All times are GMT -5. The time now is 01:17 AM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration