Adding additional storage to fog server (Virtual Box)
-
I just found this!! If I have issues, I’ll post to this thread. Otherwise, you can close it. Sorry!
https://wiki.fogproject.org/wiki/index.php/Add_%26_Extend_a_2nd_Virtual_HDD
-
@Joe-Gill If you have issues post back since that document is based on some of my input.
I would go with the new vmdk file. Once that is setup and mapped over the images, you can extend that second vmdk file pretty easy as your needs grow. As long as your images partition is the only thing on that new vmdk file.
-
That went very smoothly so far. I’m copying my images directory over to my new sdb1 drive. So far so good.
@Developers I expected the Storage Node statistics on the Dashboard to update as soon as the new drive was mounted. Is their any particular reason it wouldn’t show up there? I’m not done copying my images directory from the original disk over to the new partition yet though and I haven’t adjusted things in fstab either…
Thanks!!
Cheers,
Joe
-
@Joe-Gill the disk usage updated every two minutes or so. This is to limit strain and load on the server as requesting that information in near real time is very taxing to the server.
-
@george1421
My server seemed to go fine… My storage node on the other hand… I’m running out of space!Well, I ended up running into a problem… I ran out of space on my newly created 300 gig images partition… I got an error saying I ran out of space when I tried to mv my images directory to /mnt/test directory where I had my new partition mounted… The funny thing is when I run GParted, it looks like I have tons of space left. However, when I run df -h I get a different story… I’m a bit perplexed. If you can simplify what’s going on here, please do.
Pardon the input below… My clipboard wasn’t working going from my virtual box to my PC…
root@FogNode:/mnt# df -h Filesystem Size Used Available Use% Mounted On udev 2.0G 12K 2.0G 1% /dev tmpfs 396M 1.2M 395M 1% /run /dev/sda1 489G 149G 315G 33% / none 4.0K 0 4.0K 0% /sys/fs/cgroup none 5.0M 0 5.0M 0% /run/lock none 2.0G 152K 2.0G 1% /run/shm /dev/sdb1 296G 296G 0 100% /mnt/test
Any help is appreciated…
I’m trying to simplify things here but it seems like they are getting more complicated! What I’m shooting for is to have more space in my images directory… Thanks!
Cheers,
Joe
-
@Joe-Gill the graph is also reporting on the old partition, too. Worry about that stuff after you get your images and new disk situated.
-
@Joe-Gill Is this a VM? If so is the new disk thin or thick provisioned? If the disk is the same as what stored the image and was extended, then you are more or less done.
However just extending does not make the Linux server see the new space.
-
@Tom-Elliott Yes this is a VM. I followed the most current wiki I listed below in my previous replies. I ran mkfs ext4 /dev/sdb1 on the partition. So I’m assuming that is setting it to extended. I believe you are correct though.
I am going to see if I can allocate some of the free space from my main partition to the /images directory.
Like what is described here:
http://askubuntu.com/questions/219881/how-can-i-create-one-logical-volume-over-two-disks-using-lvm
We’ll see… It’s always something! I’m just glad our helpdesk has been slow!
Thanks again for the input!
Cheers,
Joe
-
For anyone else out there on FOG looking for this…
In my case I first added additional hard drive space on the VMware virtual disk side of things for my particular virtual machine. I added this space directly to the active hard disk. Then after I did that I booted to a Linux Live CD and ran GParted.
I saw my sda1, an sda2 extended partition and unpartioned space. Gparted would not allow me to add any of the unpartioned space to the existing partition without removing the swap from sda2. Then it did not refresh right away. I had to reboot to the live CD and then I could expand out the existing sda1 partition. I did this and rebooted. Now I can see everything and it appears to be stable.
Note:
In order to remove the swap space, you have to disable swap in gparted than it will remove the lock and let you change things. You have to unmount your drive / active partitions if it has a lock on them.Thanks for making me think guys! I’m glad I was able to figure this one out.
-
Note 2:
The only reason why I had a swap partition I believe was because initially I added a new drive to my VM and initially moved all my images over to that drive… I ended up transferring my images back to the original drive and removing the second drive all together. Despite removing the drive the Swap remained.