1

Topic: inept use of gparted capability "I believe"

I have 160GB external that I had planned on installing Debian and Ubuntu in a dual boot.
Prior to installation I inserted gparted and created 2 partitions.One was 83.77 GiB and other was 64.04.I removed gparted, inserted the Debian live CD and somehow I ended up with

Partition    File Sysyem   Mountpoint Label  Size  Used unused  Flag
sdb2             ext3       /                64.04 4.72  59.32
sdb3          Extended                        1.24
sdb5          Swap                            1.24
sdb1          ext3        /media/     /       83.77 1.50  82.27

The other HD internal has Mepis 8 and is flagged boot

Guess its easy to tell I am totally new, confused and wondering if there is an option with gparted to repair that partition on the external to release storage space for Ubuntu install.
Presently I do have a successful dual boot.
Please advise

2 (edited by cmdr 2009-03-28 18:58:48)

Re: inept use of gparted capability "I believe"

Hello potteryladymkm,

Partition    File Sysyem    Mountpoint    Label       Size   Used    unused   Flag
sdb2          ext3          /                        64.04   4.72     59.32
sdb3          Extended                                       1.24
sdb5          Swap                                           1.24
sdb1          ext3          /media/          /       83.77   1.50     82.27

I just sorted your print-out (written copy of GParted's graphic ? ). Is it true, that numbering of partitions ( sdb2 left from sdb1 ) is not in disk order as you showed it in the above table ?

I would suggest, that you redo it, which is much easier, than to correct the problematic actual situation. Since you created only two partitions - as you stated  -  Debian must have created the extended (swap) partition and used the free sdb1 partition as media storage area. Probably you selected options during installation without exactly knowing, what would happen.

How to

1. Delete all partitions on sdb by creating a new partition table.
2. Create  one (first primary) partition ( for Ubuntu), leave enough unallocated space for Debian. Do not format it.
3. Install Ubuntu. Do not create a swap partition, let Debian do the job later and use one swap for both distros.
4. Create a second primary partition (for Debian) and leave sufficient unallocated space for the swap and new /media (data)partition, which can be used by both or even all three distros.
5. Install Debian. Do NOT agree to create the /media partition with Debian. Create it afterwards within the extended partition, where Debian  - and Ubuntu - put their swapped data.
6. "Tell" Ubuntu, where it finds the swap partition.
7. Probably you get a confusing Grub boot menu afterwards. If you don't know, how to get it clear, post  sda1/boot/grub/menu.lst (a text file) here, and we recreate it slim and individual.

Regards
cmdr

3

Re: inept use of gparted capability "I believe"

Cmdr:
Thanks for the reply and yes the printout is in sequence as per partition editor. is there not a way with gparted to say delete that media partition and still have a working dual boot? Then to create a new partition from that unallocated media mistake or am I all wet

4 (edited by cmdr 2009-03-28 19:40:54)

Re: inept use of gparted capability "I believe"

@potteryladymkm :

potteryladymkm wrote:

Cmdr:
Thanks for the reply and yes the printout is in sequence as per partition editor. is there not a way with gparted to say delete that media partition and still have a working dual boot? Then to create a new partition from that unallocated media mistake or am I all wet

Yes , of course, approximatly as you described it. I would correct the partition order with "fdisk" (Debian gets sdb1, by simply exchanging the partition table content), then delete the content of the /media partition (sdb2), not the partition itself, nor its file system (take Mepis for that task). And finally install "Ubuntu", use the Debian swap area for Ubuntu, too. Don't forget to correct "menu.lst" and replace (hd1,1)  =sdb2 by (hd1,0) =sdb1  within the menu command lines for Debian.

Regards
cmdr

5

Re: inept use of gparted capability "I believe"

cmdr.
Besides getting my problem solved eventually I am getting a linux lesson as well and I guess that is the point.
debian:/home/mary# fdisk device

Unable to open device
debian:/home/mary#
How do I get in and after I do are we actually erasing what is on the partition or is it a format or what.
what is the command?
This is much harder then throwing on a pottery wheele lol
Thanks

6

Re: inept use of gparted capability "I believe"

Cmdr
http://s677.photobucket.com/albums/vv131/MKM1939
Those might help and do those key icons on external signify mounted?
here is menu.1st from boot folder/grub

# menu.lst - See: grub(8), info grub, update-grub(8)
#            grub-install(8), grub-floppy(8),
#            grub-md5-crypt, /usr/share/doc/grub
#            and /usr/share/doc/grub-legacy-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
# WARNING: If you are using dmraid do not change this entry to 'saved' or your
# array will desync and will not let you boot your system.
default        0

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout        5

# Pretty colours
color cyan/blue white/blue

## password ['--md5'] passwd
# If used in the first section of a menu file, disable all interactive editing
# control (menu entry editor and command-line)  and entries protected by the
# command 'lock'
# e.g. password topsecret
#      password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/
# password topsecret

#
# examples
#
# title        Windows 95/98/NT/2000
# root        (hd0,0)
# makeactive
# chainloader    +1
#
# title        Linux
# root        (hd0,1)
# kernel    /vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default options below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specific kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
##      kopt_2_6_8=root=/dev/hdc1 ro
##      kopt_2_6_8_2_686=root=/dev/hdc2 ro
# kopt=root=/dev/sdb2 ro

## default grub root device
## e.g. groot=(hd0,0)
# groot=(hd1,1)

## should update-grub create alternative automagic boot options
## e.g. alternative=true
##      alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
##      lockalternative=false
# lockalternative=false

## additional options to use with the default boot option, but not with the
## alternatives
## e.g. defoptions=vga=791 resume=/dev/hda5
# defoptions=quiet

## should update-grub lock old automagic boot options
## e.g. lockold=false
##      lockold=true
# lockold=false

## Xen hypervisor options to use with the default Xen boot option
# xenhopt=

## Xen Linux kernel options to use with the default Xen boot option
# xenkopt=console=tty0

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
##      altoptions=(single-user) single
# altoptions=(single-user mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
##      howmany=7
# howmany=all

## should update-grub create memtest86 boot option
## e.g. memtest86=true
##      memtest86=false
# memtest86=true

## should update-grub adjust the value of the default booted system
## can be true or false
# updatedefaultentry=false

## should update-grub add savedefault to the default options
## can be true or false
# savedefault=false

## ## End Default Options ##

title        Debian GNU/Linux, kernel 2.6.26-1-amd64
root        (hd1,1)
kernel        /boot/vmlinuz-2.6.26-1-amd64 root=/dev/sdb2 ro quiet
initrd        /boot/initrd.img-2.6.26-1-amd64

title        Debian GNU/Linux, kernel 2.6.26-1-amd64 (single-user mode)
root        (hd1,1)
kernel        /boot/vmlinuz-2.6.26-1-amd64 root=/dev/sdb2 ro single
initrd        /boot/initrd.img-2.6.26-1-amd64

### 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        MEPIS at sda1, newest kernel (on /dev/sda1)
root        (hd0,0)
kernel        /boot/vmlinuz root=/dev/sda1 nomce quiet splash vga=791 resume=/dev/sda2
initrd        /boot/initrd.img
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda1.
title        MEPIS at sda1, kernel 2.6.27-1-mepis64-smp (on /dev/sda1)
root        (hd0,0)
kernel        /boot/vmlinuz-2.6.27-1-mepis64-smp root=/dev/sda1 nomce quiet splash vga=791 resume=/dev/sda2
initrd        /boot/initrd.img-2.6.27-1-mepis64-smp
savedefault
boot


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

7

Re: inept use of gparted capability "I believe"

Hello potteryladymkm,

Your GParted screenshot shows, that you deleted the extended partition as well as the first primary sdb1. I did NOT advise you to do so !

cmdr wrote:

...
then delete the content of the /media partition (sdb2), not the partition itself, nor its file system (take Mepis for that task).

It would be much easier and quicker for you to follow my first "How to", restarting with a blank external drive and using the wizards of Ubuntu and Debian for a new installation, than to get out of the actual situation with no knowledge of console mode, partitioning and bootmanager files.

The single partition, you left,  contains Debian and is mounted as root (therefore the keyring).  It is not possible with "fdisk" to "fix the order" of one single partition; you need two at minimum.
BTW, one should not work with partitioning software on mounted drives, i.e. you should NOT use GParted from within your installed Debian distro, but a "GParted Live CD" instead.

If you want to continue this stony path , you have to create a new first partition (file system ext3), sized to the whole unallocated space, then start console ("Terminal" icon) and type at the prompt (press[ENTER] after each line)

fdisk /dev/sdb

you get a new prompt ("Command (m for Help):"), then type

x
f
w

and you are back at the console mode; leave it and restart "GParted" by its icon.
Now sdb1 should contain Debian ("4.73 GiB used").

After exchanging partition numbering, you have to correct "menu.lst" with an editor (TAKE "MEPIS" !).
Replace "(hd1,1)" by "(hd1,0)" and "root=/dev/sdb2" by "root=/dev/sdb1", wherever you find it. Test, if Debian starts.

I would shrink partition sdb2 to about the size of the Debian partition, because you then can create (after Ubuntu installation) an extended partition for swap and further logical volumes (common data, media, pottery catalogues or else).

Good luck
cmdr