VMware Cloud Community
vikrantkamboj
Contributor
Contributor

memory problem

  • Set the value of sched.mem.max to the allocated memory or greater.
  • Select the virtual machine's Resources > Memory > Limit > Unlimited box.

I have done this setting on my VM to release the bolloning and swapping of vm . But still bolloning and swapping is showing on vm .

I want to tell you that I have 5 gb free ram on host but still I am facing that kind of problem .  can anybody help me .

Reply
0 Kudos
10 Replies
Gortee
Hot Shot
Hot Shot

Just to be clear you have removed all limits and you are allowing the host to use as much as it can.  You also see you have 5Gb free memory on the host yet your virtual machine is ballooning and swapping to disk in OS. 

If these are all correct one possible answer is you have the memory reservation for overhead getting in your way.   It also could be a DRS setting.  If you have set DRS to reserve a % of resources it will show free on host but cause swapping.  Could also be slot size depending on your DRS settings.

One easy way to tell on DRS is turn it off... see if you are still swapping.   I am willing to bet it's DRS.

Let me know if it does not fix it,

J

Joseph Griffiths http://blog.jgriffiths.org @Gortees VCDX-DCV #143
Reply
0 Kudos
john23
Commander
Commander

Reserve the memory for particular vm, for making sure no swapping is happening.

Since if servers are in cluster, some time as per slot definition we may face this kind of issue.

-A

Thanks -A Read my blogs: www.openwriteup.com
Reply
0 Kudos
vikrantkamboj
Contributor
Contributor

we are not using drs and  HA .I have reserved the memory for particular this vm but problem is still the same .I don't want to shutdown the vm    .

Reply
0 Kudos
john23
Commander
Commander

can you share esxtop output with "m" option.

-A

Thanks -A Read my blogs: www.openwriteup.com
Reply
0 Kudos
Gortee
Hot Shot
Hot Shot

Morning,

So just to be clear.  There is no HA or DRS involved it's a single host.  You have reserved 100% of the hosts memory to be allocated and you are still seeing swapping on the operating system due to memory ballooning? 

If the answer to all these questions are assumptions are yes then you have a bug.  You should open a ticket with vmware support.  With 100% memory reservation ballooning should never happen.  It is turned off when reservation allocates 100% of the memory.   Now it is still possible for the Guest OS (vm) to swap with reservation but this is not a consequence of ballooning it's a normal function of operating systems with less RAM than is required.

Thanks,

J

Joseph Griffiths http://blog.jgriffiths.org @Gortees VCDX-DCV #143
Reply
0 Kudos
vikrantkamboj
Contributor
Contributor

@john23 I saw the details of vm   through ssh  esxtop   and  swr/s , sww/s value is 0.00   but still   70 mb swapped on particular this vm my 6 gb ram is free on host and the limit on vm is unlimited .

Reply
0 Kudos
john23
Commander
Commander

70 mb swapping observation in esxtop??

Thanks -A Read my blogs: www.openwriteup.com
Reply
0 Kudos
vikrantkamboj
Contributor
Contributor

@john23      NO 70mb swapping is not showing in esxtop  swr/s , sww/s value is 0.00 .   

Reply
0 Kudos
NickSousa
Contributor
Contributor

Memory pages that are sitting on disk in the swap file will not be inserted back into RAM preemptively. This was first shared with me by Valentin Bondzio, a VMware employee and super smart guy.

I confirmed this myself too but it makes sense. He mentioned originally that there is a performance hit for transferring the swapped memory pages back into RAM, which is why they let the swapped pages sit idle if they aren't being requested.

You can work around this by doing a full shutdown and start up of the VM (not just the guest OS - the entire VM). I tested all of this on ESXi 4.1 a few years ago, but it should still apply to version 5 as well.

Hope this helps.

Reply
0 Kudos
vikrantkamboj
Contributor
Contributor

I don't want to shutdown the vm . without shout is this possible to clear the swap from vm


Reply
0 Kudos