GIT 5676 Disk Information in web UI is incorrect
I’m running Fog Server on 14.04 LTS Ubuntu server with Trunk 5676. Logging into the web ui shows my Disk Information as 2gb free and 2gb used. My /images folder is located on a 1tb drive with about 900gb available. I was able to create an image from my test machine and the chart never updates. Is this a configuration issue or a potential bug in the ui? Anything else I can provide to help please let me know.
Remoted in, and found that he is using a 32 bit OS. The value I was using to do the math was a function called intval which cannot do math beyond 32 bit scope (if the OS is 32 bit).
To fix, I just removed the intval function around the free/used space.
@mrdally204 I usually set the owner and group of images to fog
sudo chown -R fog.fog /images
And I set the permissions to 775
sudo chmod -R 775 /images
Whether or not that’s the best security practice is arguable, and since your permissions are already 777 the owner being root probably doesn’t matter. But changing the owner might be worth a shot.
@Wayne-Workman The 1tb drive is internal and also used to run the OS.
fog@FogServer:~$ sudo file -sL /dev/sda1 /dev/sda1: Linux rev 1.0 ext4 filesystem data, UUID=546a8cba-febc-48e5-87da-a4c6ea712a5e (needs journal recovery) (extents) (large files) (huge files)
permission on /images
fog@FogServer:~$ ls -ld /images drwxrwxrwx 5 root root 4096 Dec 14 11:11 /images
Anything I missed?
@TOM ELLIOTT ask and you shall receive :)
@mrdally204 I’ve now fixed the weird display issues that were presented.
This is because of the checks to build the selector. It would only clean the contents if there was data. This now has been corrected with a two fold approach.
First I fixed the panes by removing the check to see if there was indeed data to present. This allowed the page to display properly with all the panes, though the usage pane had an unidentified id passed. This undefined ID would still be clickable, but at least the page looked proper and operated more properly, minus the big blank white spots.
Second, I check if there are nodes for the page to look at. The elements that auto update will only display if there is at least one “graph enabled” node. If there are 0 graph enabled nodes, the Client Count, Disk Usage, and bandwidth elements will not even be printed.
It may take a bit to get used to, but I also imagine not too many people run with fog’s graph’s on all nodes disabled.
Could you also grab a screen shot of the home page? Maybe there is an indicator on that? Seeing as we have a screenshot of the home page when it’s broken and a screenshot of the underlying hardware information, I think the only one we’re missing is the home page showing up as 4gb.
Can you tell us more about the 1TB drive?
Is it external? USB? What filesystem does it use? What are the permissions on /images ?
fog@FogServer:~$ cat /etc/exports /images *(ro,sync,no_wdelay,no_subtree_check,insecure_locks,no_root_squash,insecure,fsid=0) /images/dev *(rw,async,no_wdelay,no_subtree_check,no_root_squash,insecure,fsid=1)
My HD info looks accurate in the gui, see the screen shot below. I looked into the user/password of the storage management section and it looks to be correct. I have also tried rebooting the machine and restarting apache with no success unfortunately. This is not a show stopping issue by any means but the tinkerer in me is annoyed ;)
In the storage management of the fog gui is everything set correctly? IP address, interface, user/password and all that?
on the server what does your /etc/exports look like?
What does fog say about your hard drive in the gui?
I’ve seen mine mess up before and one of those configurations was just messed up. Maybe your ip isn’t static and it changed on you?
Other times a quick restart of apache refreshed and fixed the issue
sudo service apache2 restart
sudo /etc/init.d/apache2 restart
Or just a good old fashioned restart of the whole server can fix it to if it’s an odd bug in your server.
Though it’s most likely a simple configuration issue in the ui based on when this has happened to me a few times and since your nfs server is probably working since you were able to upload an image.
How big does the gui say your image is? You will need to enable “FOG_FTP_IMAGE_SIZE” under “General Settings” in the FOG Configuration then go to image management and list all images.
Hopefully one of those ideas helps.
@ch3i Thanks for the quick reply. here is the output
Filesystem Size Used Avail Use% Mounted on /dev/sda1 909G 48G 815G 6% / none 4.0K 0 4.0K 0% /sys/fs/cgroup udev 3.9G 4.0K 3.9G 1% /dev tmpfs 800M 676K 799M 1% /run none 5.0M 0 5.0M 0% /run/lock none 4.0G 0 4.0G 0% /run/shm none 100M 0 100M 0% /run/user
@mrdally204 lol nice home page ;)
Have you a 4Gb partition ? can you post the result of
@ch3i The TB drive also houses the Ubuntu Server OS. I’m not really sure how to answer your question unless my response does :)
Is there a way to force a refresh of this information? Would log files help in troubleshooting?
EDIT: I tried disabling the graph in Storage Management > Edit and it screws up the home page badly :)
@mrdally204 Hi, how is mount your TB drive : local disk, nfs, … ?