I have a server with 128 GB of RAM and a 100 GB hard drive in it. It seems to use pretty much swap instead of using actual RAM when rsyncing disks. I found other questions on Stack Overflow with similar problems, but none had a real solution. This is the output of "glances":
The server will normally never use 128 GB of RAM, so is it safe to disable swap? Would this increase the speed of the system or could it break something?
Or can I tell Ubuntu to use the physical RAM, instead of using swap?
Best Answer
On your Ubuntu server you have a total of 1,38 GB of swap for 128 GB of RAM.
On your screenshot the system is using 970 MB of swap for 14,9 GB of RAM, to my opinion is a standard amount of swap used by the system and far less to the 14,9 GB of RAM.
However it's a fair point to avoid your linux kernel to swap because is actually an "expensive" process in regard to its overall impact on the system performance.
Here I would suggest to adjust the amount of swappiness on the system, please find the following information for the Ubuntu FAQ :