# Usuage of Swap Space

**URL:** <https://forums.percona.com/t/usuage-of-swap-space/559>\
**Category:** Other MySQL® Questions\
**Created:** [December 10, 2007, 1:15pm UTC](https://forums.percona.com/t/usuage-of-swap-space/559 "2007-12-10T13:15:16Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dvaddi](https://avatars.discourse-cdn.com/v4/letter/d/8edcca/32.png) [@dvaddi](https://forums.percona.com/u/dvaddi)\
**Post date:** [December 10, 2007, 1:15pm UTC](https://forums.percona.com/t/usuage-of-swap-space/559/1 "2007-12-10T13:15:16Z")

</div>

Hi,

On the mysql 5.0 linux 2.6 kernel . I see the RAM of 2.8 GB is used out of 3.0 GB. And the server slows down almost comes to a hang.

when I do a free -m or top , I always see the Swap is hardly used or not used at all.

Do I have to do something for the server to use the swap space and also how I can see if I have a swap file or partition.

Thanks for any help.

---

<div class="post-metadata">

**Author:** ![sterin](https://avatars.discourse-cdn.com/v4/letter/s/3ab097/32.png) [@sterin](https://forums.percona.com/u/sterin)\
**Post date:** [December 10, 2007, 4:24pm UTC](https://forums.percona.com/t/usuage-of-swap-space/559/2 "2007-12-10T16:24:30Z")

</div>

You generally do not want to use the swap space.

On databases where most of the allocated RAM is always used it is very bad to let the DB process get so big that the OS starts to use the swap.  
And the general rule is that it’s better to use a bit less memory than risking that the OS starts to swap.

So 2.8GB allocated out of 3G sounds very good.

When your server starts to go slow does it have high CPU or high I/O load?

---

<div class="post-metadata">

**Author:** ![dvaddi](https://avatars.discourse-cdn.com/v4/letter/d/8edcca/32.png) [@dvaddi](https://forums.percona.com/u/dvaddi)\
**Post date:** [December 10, 2007, 8:57pm UTC](https://forums.percona.com/t/usuage-of-swap-space/559/3 "2007-12-10T20:57:24Z")

</div>

when the server starts to slow there is high CPU.

Thanks
