How To: Increase the Disk Space without adding another disk

Questions and answers about how to do stuff

Moderator: erroneus



How To: Increase the Disk Space without adding another disk

Postby HyTeK » Thu Jul 10, 2008 5:15 pm

Our recent installation went belly up due to the clamav update cache filling up the disk, but before that happened we increased the size of the quarantine by adding another virtual disk as listed here on ESVA.

USE THIS LINK FOR ESVA2

After we added the second virtual disk which was 8GB in size, I noticed a drop in performance on our server. We have 6 VM's running on our server, and never really had a problem with performance until adding another virtual disk to the mix.

Since I had to install a new ESVA 1.7 (as 2.0 isn't out yet), I decided to increase the size of the virtual disk that ESVA is installed on by default by 25GB. After increasing the size of the ONE virtual disk, performance went back to normal, pre-quarantine disk setup. Below is what I used and how I changed the disk space without adding a second virtual disk or physical disk.

VMWare Server 2.0.0 Beta (Build 101583) (used only to initially setup ESVA before going on production server which is VMWare Server 1.x)

Code: Select all
1. Open VMWare Server
a. Turn OFF ESVA1715
b. Click on "Edit" for Hard Disk 1 (SCSI 0:0)
c. Click "Increase Capacity..."
  i. Change New Capacity:
   1. 25GB
  ii. Click OK
2. Extend the Logical Volume
a. Power on ESVA
  i. Login in as root
   1. $parted /dev/sda [enter]
     a. > mkpart [enter]
      i. > primary [enter]
      ii. > ext3 [enter]
      iii. > 4094.692 [enter]
      iv. > 25600 [enter]
     b. > quit [enter]
   2. $mkfs.ext3 /dev/sda3 [enter]
   3. $pvcreate /dev/sda3 [enter]
   4. $vgextend VolGroup00 /dev/sda3 [enter]
   5. $lvextend -L21G /dev/VolGroup00/LogVol00 [enter]
   6. $ext2online /dev/VolGroup00/LogVol00 [enter]
   7. $/sbin/shutdown -r now [enter]


This will increase your drive space to an available 21GB of space without the need of adding another virtual disk or physical disk. (on a new install there will only be 7% used :) )

Notes:
1. This can be used on ESVA that is currently in use. However, I imagine that the online file system resize will take an extra amount of time.
2. You have to shutdown ESVA on the VMWare server to be able to resize the virtual disk.
3. I have not tried to resize the virtual disk with VMWare Server 1.x. Although I resized the virtual disk with VMWare Server 2.0, ESVA is RUNNING on VMWare Server 1.x.
4. The very last reboot is only to ensure that the system is bootable and works upon extending the volumes.
5. You can change the size from the 25GB I have listed here, but all of the numbers will be changed. (the parted parameters and the lvextend parameters)
6. When typing the commands in the terminal, do not type in the $ (dollar sign) symbol. This symbol is only to designate the following command to be typed into the terminal.
7. When typing the commands in the terminal, do not type in the > (right arrow) symbol. This symbol is only to designate the following command to be typed into the terminal application you are currently in


Cheers.
Last edited by HyTeK on Wed Jul 30, 2008 4:16 pm, edited 1 time in total.
HyTeK
Hot shot
 
Posts: 68
Joined: Thu Jul 10, 2008 4:24 pm



Postby jensskov » Wed Jul 30, 2008 2:36 pm

Hi

I tried resizing var on ESVA2 to 15Gb...

I did:
parted /dev/sda
mkfs.ext3 /dev/sda4
pvcreate /dev/sda4
vgextend vg_var /dev/sda4 -v
lvextend -L11G /dev/vg_var/lv_var

But var now had 7.8Gb

Can anyone see what i'm missing
User avatar
jensskov
Enthusiast
 
Posts: 37
Joined: Tue Aug 14, 2007 2:42 pm



Postby HyTeK » Wed Jul 30, 2008 4:12 pm

Your using the wrong HowTo for ESVA2.

Please use the correct forum for ESVA2 as there are major differences.



http://www.global-domination.org/forum/ ... php?t=1060

Cheers.
HyTeK
Hot shot
 
Posts: 68
Joined: Thu Jul 10, 2008 4:24 pm



Postby jensskov » Wed Jul 30, 2008 4:18 pm

ups, thanks.
User avatar
jensskov
Enthusiast
 
Posts: 37
Joined: Tue Aug 14, 2007 2:42 pm


Return to 1.7 How-to

Who is online

Users browsing this forum: No registered users and 0 guests

cron