modify swap space
hello,
after finish installing debian server i found that there is 8GB swap space and now i want to increase them for 30GB the default i found is Code:
swapon -s Code:
df -h how i can increase the size ? |
Hi,
Here is a prety well detail how to, to do so: http://www.linux.com/learn/tutorials...th-a-swap-file But let me be curious and ask you why would you do such thing? Usually, when your os is swapping, this is bad. So I don't even imagin with 30G of SWAP. Unless you really want to kill the performances of your machine. But if you got the choice, add some RAM... Really. Angel. |
i have 32gb ram, and am using squid server so at some point squid will eat all the ram thats why i need that swap area , what you say ?
|
I say => DO NOT SWAP (At least I wouldn't do.)
Limit your squid cache size, but do not swap. swapping will kill the performances of your server. If you don't believe me, try it, and you will understand my words. Squid is like a child, the more you'll give him the more it will take. Show him who is the BOSS. :tisk: |
Quote:
Servers using swap space is not generally a bad thing. Even major use of swap space in not necessarily a performance problem. Limiting swap space or swappiness to less than your system should have, can significantly reduce performance. I have quite a lot of swap space configured, and in some cases used, on the Linux systems for which I make those decisions. My decisions in those cases are quite well supported by evidence, unlike the common bias against swapping seen in this forum. I would not extrapolate from my experience to a server on which the major memory usage is squid, because I don't know enough. So I won't claim to know you are wrong. I just think the OP should be warned that you sound like you are repeating commonly held incorrect views. |
Hi Johnsfine,
Thank you for your well formulated contribution to this answer. Few years back I did experience this issue as well, and I notice that squid swapping was making the IO going up as hell. After tuning up squid on "what should be cached" and what should not, I reduce the cache size. Doing so, I've seen a significant performance improvement. Tuning squid cache is not easy but you'll get much better performances at the end. But you are right with one point here, I do not have enough information to say that hack back shouldn't use SWAP. Maybe he got some SSD, in that case it might not heart too much (although I never tried this configuration). But at the end of the day (in my opinion "and by experience", and it seems that by the squid team as well) SWAP usage should be use with caution as performances WILL suffer. (see my quote below) Quote:
Regards, Angel. |
All times are GMT -5. The time now is 08:01 AM. |