why is swap on the server being used up
why is swap on the server being used up
I'm trying to understand my server , if the memory is only 34% used why is the server using 8% swap?
I thought when the memory was full the server goes onto to use swap, or am I mistaken?
I thought when the memory was full the server goes onto to use swap, or am I mistaken?
Give me celebrity porn
what is the server load at that time?
From Malta with love and sunshine
It is quite normal for your server top to show 'swap' in use nothing there to worry over.
-
- Posts: 421
- Joined: March 11th, 2018, 6:36 pm
that is how it is
- TheButcher
- Posts: 12448
- Joined: February 2nd, 2018, 11:48 am
- Title: I like weekends
- Referrals: 1
- Contact:
Those numbers are very acceptable you have nothing to worry about
SWAP is hard disk space used when RAM is not enough, but it is slower. So why SWAP is used when RAM is not 100% in use is a mystery.
therefore if you see swap being used you are short on ram, makes sense.
Just looked and my memory is 46% in use and 21% swap too. So how is swap only used when your memory is full?
Sometimes it can still use swap even if memory isn't being used up. It takes as much time to get data out of swap as it does to get it in there, so sometimes the kernel will just keep it. It's not just if memory > x% then use swap linearly. And sometimes the kernel just uses swap to prevent out of memory errors and other things like using too much cache.
-
- Posts: 1138
- Joined: May 22nd, 2018, 6:47 pm
- Title: work hard play hard
If your load is 1 or under you have no reason to worry about swap
-
- Posts: 1322
- Joined: May 4th, 2018, 6:51 pm
winning opinion / answer I agree with what he postedColmike7 wrote: ↑July 7th, 2021, 2:05 pmSometimes it can still use swap even if memory isn't being used up. It takes as much time to get data out of swap as it does to get it in there, so sometimes the kernel will just keep it. It's not just if memory > x% then use swap linearly. And sometimes the kernel just uses swap to prevent out of memory errors and other things like using too much cache.
Best thing is add ram it's cheap so you are not using up disk function when ram can do it