Author Topic: Disk space of gisvm guest system  (Read 4427 times)

Vivian

  • Newbie
  • *
  • Posts: 3
Disk space of gisvm guest system
« on: January 15, 2010, 09:04:58 AM »
I have started building a geodatabase with PG Admin III in the GISVM. Everything went good in the beginning, but now pgsql fails to read and write. Ubuntu has no more disk space (nearly 8 GB used), I think this is the reason for pgsql failure. I expanded my virtual disk in vm player (Version 3) to 15 GB. How can I get Ubuntu and postgres to realize this change? Thank you for supporting!
« Last Edit: January 22, 2010, 05:04:27 PM by admin »

Vivian

  • Newbie
  • *
  • Posts: 3
Re: Disk space of gisvm guest system
« Reply #1 on: January 21, 2010, 05:03:56 PM »
A suggestion from the Ubuntu Forum, which leads to the problem that sda1 is the boot partition and therefor I can not unmount it.

http://ubuntuforums.org/showthread.php?p=8669315#post8669315http://gisvm.com/forum/index.php?board=1.0

Hello,
to guide you in the right direction, you can use:

Quote:
resize2fs /dev/sda1 15G
*where sda1 is the partition you want to resize (you have to unmount it first)
**the extra space after the partition has to be unpartitioned..

I haven't used this in a production system yet, so be careful..
__________________
Thank you Microsoft for windows Vista... it was the reason I switched to Linux

admin

  • Administrator
  • Jr. Member
  • *****
  • Posts: 72
Re: Disk space of gisvm guest system
« Reply #2 on: January 22, 2010, 05:03:39 PM »
Hi Vivian,

> I expanded my virtual disk in vm player (Version 3) to 15 GB.

Correct!

Now you have a bigger disk but the partitions inside it still have the same size.

The simplest way to resize partitions is to use "gparted"
[ equivalent to the great Windows Partition Magic! :) ]

Just Download the ISO file from:
http://sourceforge.net/projects/gparted/files/gparted-live-stable/

Then configure VMPlayer on GISVM to replace phisical CD/DVD to that iso file, and boot from it!
VMWare menu: VM > Removable Devices > CD/DVD(IDE) > Settings
(use ISO image file)

Press F2 during the GISVM Boot to enter VM BIOS setup.
Goto BIOS boot menu and change the CD to the top of boot order.

Finally follow the GParted instructions to resize the sda1 partition to the maximum free size.

Please let us know if you have solved the problem.
Thank you!
Ricardo Pinho
« Last Edit: February 11, 2010, 08:26:05 PM by admin »

geoair

  • Newbie
  • *
  • Posts: 8
Re: Disk space of gisvm guest system
« Reply #3 on: February 09, 2010, 11:06:39 AM »
Hi,
I'm also interested in this subject.
I've increased my virtual machine to 15gb (7gb more) so now I have 7gb of unallocated space:
/dev/sda1            ext3                   7.61GB
/dev/sda2            extended         400.06 Mib
       /dev/sda5     linux-swap       400.06 Mib
   unallocated          unallocated        7.00Gib

My question is: using GParted, how can I move the 7gb unllocated space to /dev/sda1?
best Regards.

Vivian

  • Newbie
  • *
  • Posts: 3
Re: Disk space of gisvm guest system
« Reply #4 on: February 09, 2010, 02:26:42 PM »
Hi Admin,
Thank you for the support! I found a workaround and mounted a second disc. with gparted. I didn know I can boot form a CD with VM Player, so next time I install GISVM I will try the solution you described.
Regards Vivian

geoair

  • Newbie
  • *
  • Posts: 8
Re: Disk space of gisvm guest system
« Reply #5 on: February 09, 2010, 05:03:12 PM »
Hi,
After a little try and error I think I found a way to increase the available space.
Followed Admin's steps: increase GISVM size in VMWPlayer, boot GParted inside GISVM.
Now using Gparted I deleted the extended partition, resized sda1 using the unallocated space, leaving the necessary space for creating a new extended partition for the swap.
Until now, everything seems to be ok.
Best regards.

geoair

  • Newbie
  • *
  • Posts: 8
Re: Disk space of gisvm guest system
« Reply #6 on: February 10, 2010, 09:56:03 AM »
One thing I forgot to mention: I assume no responsibility for any damage that my suggestion may cause  ;D
I'm doing this on a trial and error basis so I don't suggest you do these procedures in a production environment unless you're absolutely sure of the results...
Regards

geoair

  • Newbie
  • *
  • Posts: 8
Re: Disk space of gisvm guest system
« Reply #7 on: February 10, 2010, 05:02:36 PM »
Hi,
Another quick update: if you DELETE the swap file dont forget to assign it again insid GISVM.
I don't recall exactly the steps I did, but I followed this guide.
Regards.

geoair

  • Newbie
  • *
  • Posts: 8
Re: Disk space of gisvm guest system
« Reply #8 on: February 11, 2010, 11:14:52 AM »
Hi.
I wasn't satisfied with the fact to have to delete, create and assign swap partitions using GParted and the method I referred before.
The fact is we can move the unallocated space to sda1, assigning the extra space to the partition above and then resizing it to the unalocatted space 'moves' from the bottom of your 'disk'  to after SDA1.After, your only have to resize SDA1.
Hope it helps

admin

  • Administrator
  • Jr. Member
  • *****
  • Posts: 72
Re: Disk space of gisvm guest system
« Reply #9 on: February 11, 2010, 08:23:44 PM »
Hi geoair,

I wasn't satisfied with the fact to have to delete, create and assign swap partitions using GParted and the method I referred before.

Yes, I don't advise you to delete the swap partition!
Since the unallocated space appears after the swap partition, you can't directly increase the sda1 size.
So you should first move the swap partition to the end, and then increase the sda1 partition!

Sorry for not explaining this in detail in the first place... :(
« Last Edit: February 11, 2010, 09:35:48 PM by admin »

geoair

  • Newbie
  • *
  • Posts: 8
Re: Disk space of gisvm guest system
« Reply #10 on: February 17, 2010, 09:17:21 PM »
Hi geoair,

I wasn't satisfied with the fact to have to delete, create and assign swap partitions using GParted and the method I referred before.

Yes, I don't advise you to delete the swap partition!
Since the unallocated space appears after the swap partition, you can't directly increase the sda1 size.
So you should first move the swap partition to the end, and then increase the sda1 partition!

Sorry for not explaining this in detail in the first place... :(
Hi
No problem about that.
Abraço.