Kitz Forum

Computer Software => Linux => Topic started by: Ratae on March 02, 2013, 02:49:40 PM

Title: Partition removal.
Post by: Ratae on March 02, 2013, 02:49:40 PM
Well hello there, it's been a while, but as this is my 'default' forum for anything Linux.... I'm back!  8)

So..... I'm still using my Acer Netbook that dual boots with Lucid Lynx (Ubuntu 10.04LTS) and Windows XP Home. The first Partition of about 80gbs is the Ubuntu one.

Recently.... I've switched browsers on Ubuntu, and I'm now using the Chromium one, it is very much faster than the FF one in Ubuntu, and also faster than FF in the XP partition.

For this reason, I want to get rid of the FF partition and turn the whole machine over to Ubuntu.

I've had a quick shufty around...and it seems it's not quite a simple as just deleting the partition, I'm sure I read somewhere about the boot menu being affected.

So.....I'd very much appreciate some advice from one of  you Linux experts (like Eric) on this matter.

Pssst..... pretend your talking to an Ubuntu idiot, you won't be far wrong!  :-[



Thanks in advance.
Title: Re: Partition removal.
Post by: roseway on March 02, 2013, 03:40:22 PM
If the Ubuntu partition is the first one, then there shouldn't be a problem with deleting the Windows partition. The bootloader will be in the MBR (Master Boot Record, not part of any partition) and the booting code will be in the Ubuntu partition. You can probably do the deletion from Ubuntu, if it has partition manager software installed.

After deleting the Windows partition, you'll still see Windows listed in the boot menu. Boot into Ubuntu, open a command line terminal, and type sudo update-grub which will refresh the boot menu.
Title: Re: Partition removal.
Post by: Ratae on March 03, 2013, 01:29:46 PM
Thanks Eric. I have downloaded and installed 'Gparted'  Will this do the 'necessary' deletion, and if successful, will the new free space just be added to the Ubuntu partition?
Title: Re: Partition removal.
Post by: asbokid on March 03, 2013, 01:52:12 PM
The best way to manipulate partitions (backup anything important first..!)  is to boot from a live CD with gparted on it. [1]
That way none of the file systems on the hard disk are mounted. You can't merge, split or re-size the partitions if they're mounted.
gparted has made the process loads easier, but it can still be perilous - hence backup anything important.

Sometimes it's easier just to delete all partitions, create new ones, and reinstall the operating system (OS) from scratch.
One thing I try to do is create a separate /home partition.  In that way, upgrading the OS without disrupting all the user files, is much easier.

cheers, a

[1] http://gparted.sourceforge.net/livecd.php

Title: Re: Partition removal.
Post by: oldfogy on March 03, 2013, 02:15:10 PM
Thanks Eric. I have downloaded and installed 'Gparted'  Will this do the 'necessary' deletion, and if successful, will the new free space just be added to the Ubuntu partition?
I'm only guessing here, but I think after you delete the partition you will then have to merge it with the first partition to be able to make full use of it.
Sorry I don't know if Gparted has a merge facility.
Title: Re: Partition removal.
Post by: Ratae on March 03, 2013, 02:46:10 PM
Hmmm...thanks fellas.

I read the advice to run GParted from a live disc, but this is a 'Netbook' without an optical drive. I do have an external one, but my youngest son has borrowed that and anyone 'owning' youngest sons, will know how hard it is to get stuff returned!  :'(

I've read the tutorial on GParted, and to be honest, it almost made my eyes bleed. However.....the GUI of the program clearly shows two partitions on the drive, and it's obvious to me which of the two is the XP partition.

I just need to know that I'm not going to be left with an empty, unusable partition! :'(

Title: Re: Partition removal.
Post by: asbokid on March 03, 2013, 02:56:51 PM
gparted live can be written to and booted from a USB flash stick if there's no CD/DVD drive available.

The re-partitioning has to be done on unmounted file systems - i.e. using a live bootable operating system like gparted live.

Otherwise only half the job can be done - deleting the Windows partition is okay, but the adjacent Linux partition cannot grow into the freed space.

What is shown by the following?

Code: [Select]
sudo /sbin/fdisk -l
cheers, a

EDIT:

I just need to know that I'm not going to be left with an empty, unusable partition! :'(

That's exactly what does happen when you try to merge a new partition with a partition that's already mounted :-X
Title: Re: Partition removal.
Post by: Ratae on March 03, 2013, 03:34:31 PM
This is what Gparted shows for my drive ...




Title: Re: Partition removal.
Post by: oldfogy on March 03, 2013, 03:48:34 PM
I have in the past used similar programs that show that exact same screen-shot, once the partition was removed it then allowed me to merge the empty space into the partition next to it, thus increasing the size and doing what you want it to do.

I take it the first partition is the Acers original backup/recovery partition, so also if you wanted to and have no intention of going back to XP then you could also get rid of that partition.
Title: Re: Partition removal.
Post by: asbokid on March 03, 2013, 05:00:23 PM
As oldfogy has said, both sda1 and sda2 could be deleted, and then sda3 could be grown to the left.   sda3 is an extended partition, and contains two logical partitions sda5 and sda6. These partitions (or more accurately, the file systems on them) all have to be unmounted to perform that merge and grow operation.

The contents of sda3 (containing secondary logical partitions sda5 and sda6) will then have to be moved to the new beginning of the sda3 partition.   Since the partition/s are barely utilised that shouldn't take very long.

It could be worth studying the existing grub configuration, usually found under /boot, to confirm that it won't all bork when the partitions and partition table are manipulated!

Good luck!

cheers, a

EDIT:  what about going half-way, and shrinking sda2 from 56GB to 30GB or thereabouts, and then growing sda3 to absorb the free space released?  Not familiar with Windows, but will it still boot if the recovery partition is deleted?  If so, you could gain another 10GB from doing that.

EDIT2: Vague memories of it being a requirement that a volume has at least one primary partition. If so, sda1 and sda2 can't both be deleted, since that only leaves an extended partition sda3.   Sometimes it is easier just to wipe a drive and install the OS from scratch  :-\

EDIT3:  Logical partitions not "secondary" partitions. ???
Title: Re: Partition removal.
Post by: Ratae on March 03, 2013, 07:16:02 PM
As oldfogy has said, both sda1 and sda2 could be deleted, and then sda3 could be grown to the left.   sda3 is an extended partition, and contains two secondary partitions sda5 and sda6. These partitions (or more accurately, the file systems on them) all have to be unmounted to perform that merge and grow operation.

The contents of sda3 (containing secondary partitions sda5 and sda6) will then have to be moved to the new beginning of the sda3 partition.   Since the partition/s are barely utilised that shouldn't take very long.

It could be worth studying the existing grub configuration, usually found under /boot, to confirm that it won't all bork when the partitions and partition table are manipulated!

Good luck!

cheers, a

EDIT:  what about going half-way, and shrinking sda2 from 56GB to 30GB or thereabouts, and then growing sda3 to absorb the free space released?  Not familiar with Windows, but will it still boot if the recovery partition is deleted?  If so, you could gain another 10GB from doing that.

EDIT2: Vague memories of it being a requirement that a volume has at least one primary partition. If so, sda1 and sda2 can't both be deleted, since that only leaves an extended partition sda3.   Sometimes it is easier just to wipe a drive and install the OS from scratch  :-\

But according to 'Grub' ... my primary partition IS the Ubuntu one. Ubuntu is the first on the list and is the system that the netbook boots to if I don't 'select' one of them!

I also have a program on the netbook called 'Grub customiser' (I think) I have used this in the past for removing older versionsof Ubuntu.


Title: Re: Partition removal.
Post by: asbokid on March 03, 2013, 08:01:09 PM
I meant primary partition as in the physical definition, rather than the partition that holds the OS that is booted by default:

See: http://en.wikipedia.org/wiki/Disk_partitioning#PC_partition_types

Good luck with it!

cheers, a
Title: Re: Partition removal.
Post by: Ratae on March 03, 2013, 08:51:41 PM
I meant primary partition as in the physical definition, rather than the partition that holds the OS that is booted by default:

See: http://en.wikipedia.org/wiki/Disk_partitioning#PC_partition_types

Good luck with it!

cheers, a


Thanks for the advice, I've decided to have a crack at it, if it all goes thingys up...I'll do a clean install!
Title: Re: Partition removal.
Post by: roseway on March 03, 2013, 08:55:56 PM
Good man! ;D
Title: Re: Partition removal.
Post by: oldfogy on March 03, 2013, 09:03:28 PM
Just remember 'Read twice, Click Once'
Title: Re: Partition removal.
Post by: Ratae on March 04, 2013, 08:47:11 AM
Ok fellas, I bit the bullet and deleted Windows, then removed it from Grub.

As I suspected, I'm left with an empty partition that I can do nothing with.

However...it occurred to me that I'm no worse off than I was before. I've only used about 10 gbs of the available space on the machine anyway, as I don't use it for anything else but the internet.

So...I won't bother wiping the drive and doing a clean install...not yet anyway, and I have got rid of Windows on this machine which was becoming a pia!

When I get that ext drive back from Ratae minor, I might burn a Gparted live disc and see what I can do with that. Anyway, thanks for all of the advice and help.....see you all later!
Title: Re: Partition removal.
Post by: roseway on March 04, 2013, 10:25:04 AM
You could format that empty partition with a Linux filesystem and use it for data storage.
Title: Re: Partition removal.
Post by: Ratae on March 04, 2013, 03:07:23 PM
You could format that empty partition with a Linux filesystem and use it for data storage.

Eric...I decided to download that GParted live disc and burn it, then see what I can do with that!

But....I'm completely lost now 'cos I downloaded from 'Source Forge' what it called an .iso file, but when it downloaded it's an .exe file!

I've burned many .iso files before and used them to boot windows.....but what is an 'exe file supposed to do?   :-[

I also downloaded a zip file...I haven't a clue what to to with it!




Title: Re: Partition removal.
Post by: oldfogy on March 04, 2013, 03:42:45 PM
Can you see the extension and does it say .exe or .iso?
Or are you sure there was not the option of downloading either and you downloaded the exe file by mistake?

As for the zip file which is probably a .RAR just unrar (decompress) it with 'WinRAR' or any other zip file extractor.
Title: Re: Partition removal.
Post by: roseway on March 04, 2013, 04:10:39 PM
The download you want is http://sourceforge.net/projects/gparted/files/gparted-live-stable/0.14.1-6/gparted-live-0.14.1-6-i486.iso (http://sourceforge.net/projects/gparted/files/gparted-live-stable/0.14.1-6/gparted-live-0.14.1-6-i486.iso)
Title: Re: Partition removal.
Post by: Ratae on March 04, 2013, 05:00:11 PM
Can you see the extension and does it say .exe or .iso?
Or are you sure there was not the option of downloading either and you downloaded the exe file by mistake?

As for the zip file which is probably a .RAR just unrar (decompress) it with 'WinRAR' or any other zip file extractor.

No Phil...it was a .zip file which I opened with 7Zip. That .exe file was the only file in it!

And 'NO' Phil..it definitely had .iso on it!
Title: Re: Partition removal.
Post by: oldfogy on March 04, 2013, 05:13:30 PM
TBH I think I would be inclined to forget what you have already downloaded and start again, mainly because it's getting confusing what you have and what you thought you had.

I just tried Roseways link and although it was a bit slow it did give me the download option the second time I opened his link, so that might be your best option and just download that one and forget what you have already downloaded.
Title: Re: Partition removal.
Post by: Ratae on March 04, 2013, 05:19:53 PM
Yep...I'll do that!
Title: Re: Partition removal.
Post by: Ratae on March 04, 2013, 11:01:59 PM
Ok fellas....I'm damned if I know how I got that .exe. file...but anyway, as OF suggested, I started again!

So....I downloaded that .iso file of Eric's, burned the disc and ran it.

Well, considering most of the stuff on it was gibberish to me, I gave it my best shot! It doesn't appear to have been a complete disaster, far from it. I apparently have managed to format that unused partition to ext4, the other partition is the same, and I can see it in GParted.

But...I can't see it in the boot list when I start the machine, and don't know how to use it!




Title: Re: Partition removal.
Post by: oldfogy on March 04, 2013, 11:17:32 PM
As I said earlier I have seen that exact same picture in another program so.

Have you tried either right clicking the now unused portion or dragging the edge of the used portion into the unused portion to see what happens?

Always keep a look at the bottom left-hand side of the program screen after trying anything because that is where it will show any instructions you have told the program to do, plus eventually before doing anything you will be asked if you want to continue.

NB.
If you select to do the same thing more than once the program will also carry out your instructions more than once, which then obviously take a lot more time, so keep a eye on the bottom corner.

Is there nothing or anything about 'Merge' or something similar in your menu's?
Title: Re: Partition removal.
Post by: roseway on March 04, 2013, 11:19:00 PM
I'm afraid it's my bedtime now, but briefly, in Linux you have to mount a partition before you can use it. That means creating a mount point, i.e. a directory to use for the contents of the partition (something like /media/data for example) and then editing /etc/fstab to add a line to mount the partition in that directory. You may find that your OS has configuration utility to make this easier, somewhere in the menu.
Title: Re: Partition removal.
Post by: oldfogy on March 04, 2013, 11:49:09 PM
As I said I don't use or know anything about Linux but when using the program in windows I simply elected to use all the vacant space once the space had been freed-up.
Title: Re: Partition removal.
Post by: Ratae on March 05, 2013, 05:26:33 PM
Right then fellas.... I don't quite know how, but there's just a chance that I might be halfway there!

Anyway...I installed a program called 'Storage Device Manager' from the repositories. In there I could select a partition and choose to 'mount or unmount'

So...I selected that sda1 partition and selected 'mount'

Now.....when I boot up, on the desktop there is an icon which reads '71gb file system' ... When I click on it Nautilus appears with a folder showing. There is a X  in the folder icon and it's called 'Lost + Found'

I've no idea what it is and I'm wondering how I can use this partition!
Title: Re: Partition removal.
Post by: roseway on March 05, 2013, 06:30:59 PM
"Lost + Found" is managed by the system and contains files which have been misplaced as a result of some error situation. It's quite normal to find a directory with that name in a mounted partition. If the mounting has worked, you should be able to copy files to and from the partition, ignoring the "Lost + Found" directory inside it.
Title: Re: Partition removal.
Post by: Ratae on March 06, 2013, 02:00:25 PM
Ok fellas...well first up, thanks again for all of the help and your endless patience!  :clap2:


Anyway...I have finally decided that Eric was right at the beginning, it's probably best to just reload the o/s fresh.

But for the minute, I'm gonna stop trying to fix something that for my purposes isn't really broken. I've deleted that partition and just using the 80gb one.

Later.  :drink:
Title: Re: Partition removal.
Post by: Ratae on March 12, 2013, 11:56:54 PM
Well, just to update you on this. I finally decided that 'enough was enough' ....so I installed Linux Mint 14  Mate edition, and used the whole drive.

WOW! ...I thought that Ubuntu was good, but this is very very good, I'm mucho impressed.

Still doing a bit of tinkering, but I think that this is deffo a keeper!  :clap:
Title: Re: Partition removal.
Post by: roseway on March 13, 2013, 07:22:38 AM
Excellent news! :thumbs:
Title: Re: Partition removal.
Post by: tickmike on March 13, 2013, 01:17:37 PM

WOW! ...I thought that Ubuntu was good, but this is very very good, I'm mucho impressed.

That's what I thought about PCLinuxOS when I tried it instead of Ubuntu and Mint  :) but everyone to there own .
well done.
                                                   ---------------------------------------------------------------
I had a virus once, it was called 'Windows'   >:D, So I used a piece of good security software it was called 'Delete'  ;D Yes you have got it, I Deleted Windows off my hard drive.   ;D .

Now I do not have any problems.
Title: Re: Partition removal.
Post by: broadstairs on March 13, 2013, 02:15:50 PM
Yes it's funny how folks find their best Linux. I've tried Red Hat (some years ago), Mandrake, Mandriva, Mageia, PCLinuxOS, Kubuntu (cant stand Gnome) and now finally have seemed to stick with Fedora (currently 17 but will upgrade to 18 soon).

Stuart
Title: Re: Partition removal.
Post by: Ratae on March 18, 2013, 08:51:49 PM
Yep, more than pleased with this Mint Netbook. I've installed Chromium as the default browser too, and that's very good on Linux.


Once again guys...thanks for all of the help and advice.  :drink: