why VM level and guest OS level RAM so different ?

Discussions related to using VirtualBox on Windows hosts.
Post Reply
yenisey82@gmail.com
Posts: 1
Joined: 11. Aug 2015, 16:16

why VM level and guest OS level RAM so different ?

Post by yenisey82@gmail.com »

Virtualbox version: 4.3.28
Host OS : Windows 7 Home Premium
Guest OS : Oracle Linux 6.6

At Virtualbox level (From GUI at Host Level) , I allocated 2800MB for my Linux VM. After installing the Guest OS (Oracle Linux 6.6) , when I run free command (which provides info on Physical RAM), from my Guest OS, I see only 2485 MB. ie. 315MB has been disappeared/lost/unaccounted for ? Why is this ?

Code: Select all

[root@pravda178 ~]# free -m
             total       used       free     shared    buffers     cached
Mem:          2485       2319        165        111         35        614
-/+ buffers/cache:       1669        815
Swap:          299          0        299
In VMWare workstation (version 10.0.3) , this difference is only 60MB.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: why VM level and guest OS level RAM so different ?

Post by mpack »

Let me turn that around.

My physical host has 4GB installed. If I view My Computer | Properties my Windows host OS says I have 3.49GB RAM installed. Why do you suppose that might be?

Let's further suppose that on a different PC with the same amount of RAM installed I see a different number in My Computer. What might be the reason for the difference?
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: why VM level and guest OS level RAM so different ?

Post by Perryg »

Even on metal there is a difference. Host with 32GB = 32,768MB

Tanslates to the following:

Code: Select all

~ $ free -m
             total       used       free     shared    buffers     cached
Mem:         32135       2415      29720         26          3        257
-/+ buffers/cache:       2153      29981
Swap:        30807          0      30807
leaving a difference of 633MB that the host or guest uses for overhead. (including video memory in the case of the guest)
BlueSkies2
Posts: 2
Joined: 15. Nov 2012, 17:35

Re: why VM level and guest OS level RAM so different ?

Post by BlueSkies2 »

Thank You Perryg, mpack. I didn't think of this aspect. Since I discovered that this difference is less for a VMWARE workstation guest, I got curious. But, I guess, this is inevitable.
Post Reply