Need to resize ubntu vm

I am trying to re-size this vm and utilize the additional space but gparted isn't allowing me how can I do it without loosing any data?  Please advise..
2015-03-23-16-47-59.jpg
sj77Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

rindiCommented:
Delete the swap partition, then do the resize, leaving space for swap, then create the partition again. Make sure you change the settings of ubuntu's /etc/fstab file so the new swap partition can be used (the UUID of the partition changes when you create a new one, and fstab loads partitions via this ID).

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
or you could use VMware Converter, and create a V2V.

see my EE Article, as an example, but increase the size

HOW TO: Shrink or Reduce a VMware Virtual Machine Disk (VMDK) using VMware vCenter Converter Standalone v5.5.2
sj77Author Commented:
Could I just move the swap partition to the end of the drive and then do the resize?
The 7 Worst Nightmares of a Sysadmin

Fear not! To defend your business’ IT systems we’re going to shine a light on the seven most sinister terrors that haunt sysadmins. That way you can be sure there’s nothing in your stack waiting to go bump in the night.

sj77Author Commented:
See the attached image..
2015-03-26-14-26-00.jpg
rindiCommented:
I don't think swap partitions can be moved. Besides, they don't hold any data, so deleting and creating a new one would be faster.
sj77Author Commented:
Rindi,

I was able to do it with gparted, is that a problem?
rindiCommented:
No, if it worked then it is OK. I just never tried it as it is faster deleting it and creating a new one.
sj77Author Commented:
What about when you have a that is around the linux swap is it the same way like deleting?
2015-03-31-5-12-58.jpg
rindiCommented:
You mean the swap partition is within an extended partition? You would have to delete both, the swap and the extended partition.
sj77Author Commented:
Just like the picture states... It seems that way correct?..
rindiCommented:
Yes, you'd have to delete them both, first the swap and then the extended partition.
sj77Author Commented:
Once I delete them I can just re-create them the exact same size do i need to do anything  after re-creating them in partition magic?
rindiCommented:
If you don't intend to use more than 4 partitions on your virtual disk, you only need to create a new Swap partition. Since this is a VM, it wouldn't make any sense to have more partitions on that disk anyway. You will just need to adjust the /etc/fstab file so the partition gets loaded when you start ubuntu, like I mentioned earlier. In the partition editor of PartedMagic, when you right click the swap partition you created, and select "information", you'll see it's UUID. That is what you'll have to use in the fstab file.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Storage

From novice to tech pro — start learning today.