LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 07-21-2012, 02:50 AM   #1
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 20.04
Posts: 2,116

Rep: Reputation: 73
rearrange partitions and use unallocated space


I had Fed 17 installed, but it was not working well. I installed Ubuntu 12.04, using 'replace existing Linux'. Ubuntu asked me to create a swap, and I clicked after the partition. That left me with the situation you can see in the screenshot. I didn't have time to do anything about it then. Apparently, you can only have 4 partitions, so I have 140GB unallocated. I would like to put Fedora on there now that I have time. It may have improved with time.

How can I best rearrange things? If I have to, I can reinstall Ubuntu, but I'd rather not.
Attached Thumbnails
Click image for larger version

Name:	Screenshot from 2012-07-21 15:40:19.png
Views:	16
Size:	59.2 KB
ID:	10175  
 
Old 07-21-2012, 03:01 AM   #2
pingu
Senior Member
 
Registered: Jul 2004
Location: Skuttunge SWEDEN
Distribution: Debian preferably
Posts: 1,350

Rep: Reputation: 127Reputation: 127
Luckily this is not a big problem.
"you can only have 4 partitions," yes, but that is primary partitions.
What you can do is create an extended partition which acts as a container for lots of partitions (more exactly "logical volumes" but you can treat them as partitions).
So do this:
1. Delete /dev/sda4
2. Use all unallocated space, ~142GB, for extended partition.
3. Create new swap, then all partitions you want as logical volumes.
And finally, check that Ubuntu picks up the new swap, maybe you have to do it manually.
 
1 members found this post helpful.
Old 07-21-2012, 03:15 AM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,119

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Quote:
Originally Posted by pingu View Post
What you can do is create an extended partition which acts as a container for lots of partitions (more exactly "logical volumes" but you can treat them as partitions).
Nope, they are logical partitions within an extended. Logical volumes are are somethings else again, for LVM.

Other than that good advice that should help the OP. Fedora will find the (logical) swap o.k. but may reformat it, which will change its UUID. This will make Ubuntu unbootable, so keep an eye on the Ubuntu fstab before rebooting.

Last edited by syg00; 07-21-2012 at 03:16 AM.
 
Old 07-21-2012, 03:18 AM   #4
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 20.04
Posts: 2,116

Original Poster
Rep: Reputation: 73
Thanks, I'll try it later. I'll try not to blow up my computer!

What was that about unbootable?? How to avoid such crises on this beautiful day??

Last edited by Pedroski; 07-21-2012 at 03:19 AM.
 
Old 07-21-2012, 03:23 AM   #5
pingu
Senior Member
 
Registered: Jul 2004
Location: Skuttunge SWEDEN
Distribution: Debian preferably
Posts: 1,350

Rep: Reputation: 127Reputation: 127
Quote:
Originally Posted by syg00 View Post
Nope, they are logical partitions within an extended. Logical volumes are are somethings else again, for LVM.
Oops, my mistake. Thanks for correcting.
 
Old 07-21-2012, 04:02 AM   #6
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 20.04
Posts: 2,116

Original Poster
Rep: Reputation: 73
Sorry, but if things go pear shaped on rearranging the partitions and installing Fed, I should:

1) Look in /etc/fstab for the UUID of the swap partition
2) Make sure that is the entry in Ubuntu's /etc/fstab (at the mo this is UUID=779573f9-b046-4017-ae6b-6f550994634c none swap sw 0 0) and if necessary insert the new UUID

Then Ubu will boot ok??
 
Old 07-21-2012, 04:06 AM   #7
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,119

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Quote:
Originally Posted by Pedroski View Post
What was that about unbootable?? How to avoid such crises on this beautiful day??
Just check the UUID on the swap (using blkid maybe) is what Ubuntu expects it to be.

July in Nanjing - hmmm, that would be hot and steamy if I recall correctly. "Beautiful day" might be a stretch of the imagination ...

Edit: posts crossed "in-flight". Yep, maybe Fedora won't reformat it - but check just in case.

Last edited by syg00; 07-21-2012 at 04:08 AM.
 
Old 07-21-2012, 04:10 AM   #8
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 20.04
Posts: 2,116

Original Poster
Rep: Reputation: 73
Thanks for that.
Definitely swelteringly hot, but sunny today, blue sky over my little mountain, 方山 (fangshan)
 
Old 07-22-2012, 07:03 PM   #9
Pedroski
Senior Member
 
Registered: Jan 2002
Location: Nanjing, China
Distribution: Ubuntu 20.04
Posts: 2,116

Original Poster
Rep: Reputation: 73
Post scriptum: I did the deed, worked fine. Fedora did reformat the swap partition, without informing or asking me. Afterwards it had a different UUID
But Ubuntu didn't falter: it took a bit longer booting, I suppose it noticed that the disk had been altered, and came back ok.
 
  


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
makes partitions & unallocated space must created manually lse123 Linux - Newbie 13 12-07-2011 11:06 AM
Unallocated Space in Gparted? magic8ball88 Linux - Newbie 11 05-22-2010 01:53 AM
How to rearrange partitions on a disk? sheintze Linux - Software 3 03-10-2007 07:39 PM
Unallocated Partitions oldmartian Linux - Software 8 02-24-2007 01:22 PM
partioning unallocated space Ledft Linux - Newbie 4 05-30-2006 11:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 06:13 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
Open Source Consulting | Domain Registration