Unix systems, and other Unix-like operating systems, use the term "swap" to describe both the act of moving memory pages between RAM and disk, and the region of a disk the pages are stored on. In some of those systems, it is common to use a separate whole partition of a hard disk for swapping. These ...

learn more… | top users | synonyms

104
votes
18answers
55k views

I have 16GB RAM. Do I need 32GB swap?

I read many places that the rule of thumb for swap space is to double the amount of physical RAM. However, 32 GB does seem a LOT. Do I need that much? Do I need it at all with this high amount of ...
71
votes
1answer
126k views

How do I configure swappiness?

I need Step by Step, simple and easy way to configure swappiness.
60
votes
5answers
29k views

Why is swap being used even though I have plenty of free RAM?

I thought the whole essence of swap was to act as a temporary storage safety net when RAM was full but my swap partition is constantly being used even though I sometimes have as much as 3GB free RAM. ...
37
votes
5answers
46k views

How do I add a swap partition after system installation?

I did not opt for a swap partition during Ubuntu installation. Later I freed up some space, and made a swap partition. Now after booting up I am manually opening gparted and right-clicking the swap ...
35
votes
9answers
44k views

How to empty swap if there is free RAM?

When I open a RAM-intensive app (VirtualBox set at 2GB of RAM), some swap space is generally used, depending on what else I have open at the time. However, when I quit that last application, the 2GB ...
27
votes
4answers
4k views

Importance of Swap Partition

What is the purpose of a swap partition? How do I know I have just enough swap partition? Not too much/little. My Ubuntu PC is used for typical stuff: Web (email, facebook, etc.) Some movies ...
25
votes
2answers
27k views

Is it safe to turn swap off permanently?

My system was getting slower, especially when I use browsers like Firefox / Chromium and Virtual Machines. I noticed that I've got at least 3.2 GB of free RAM (using Gnome system monitor) and there ...
25
votes
2answers
33k views

How to increase swap space?

I have, by default, 250MB of swap space in Ubuntu, and I want to expand it to a larger size. I need 800MB, which I think will be enough to open several applications without having to hit the current ...
22
votes
3answers
4k views

How can I turn off swap permanently?

Swap makes my system all sluggish and turning it off makes everything smoother. I have 3.5 GB of RAM. I know how to turn swap off by entering sudo swapoff -a in the terminal, but that's just for the ...
22
votes
5answers
8k views

Does it make sense to create swap partitions for new installations nowadways?

For a desktop installation in a new and shiny laptop (let's say 16gb ram and ssd hd), does it make sense to have a swap partition?
21
votes
5answers
16k views

Why most people recommend to reduce swappiness to 10-20?

I have seen in several site which recommend to reduce swappiness to 10-20 for better performance. http://community.linuxmint.com/tutorial/view/998 ...
20
votes
4answers
2k views

With an SSD, do I need to change my swappiness to increase SSD life?

I encountered this article which includes the following suggestion: Swap and swappiness I kept my swap partition on the old HDD. Swap on the SSD would be faster, but would also shorten the ...
19
votes
5answers
20k views

How do I use zRam?

I installed zRam as described on webupd8.org. I installed it from the terminal. Is that all I have to do or do I have to do some configuration or something? Does the zram-enabler do everything by ...
18
votes
4answers
17k views

How do I disable swap?

I have some sensitive data in ram that i prefer not to be on disk. How do i disable swap? I have more then enough ram. If ram gets too high i have no problems with processes being terminated. How do I ...
16
votes
1answer
424 views

boot up problem (14.04 + GRUB + Swap + Nvidia) - with pictures

When I start my laptop, it takes as much as 7 tries to get past the place where the swap gets mounted; if anyone is looking over my shoulder then it becomes 15 tries! My laptop is a lenovo W520 with ...
15
votes
1answer
16k views

What to do about “the disk drive for /dev/mapper/cryptswap1 is not ready yet or not present”?

While booting Ubuntu 12.04, the disk drive for /dev/mapper/cryptswap1 is not ready yet or not present is showing. What is this? Is this is an error?
14
votes
2answers
4k views

What is the default swap size?

How does the installer calculate what size of swap partition to create? Presumably it's based on installed RAM size, but does that depend on how much RAM?
13
votes
4answers
8k views

How big should I make my swap partition?

I'm (re)installing Ubuntu on my Toshiba NB100 netbook (Intel Atom, 120GB HD, 2GB RAM). Already have a partition I call "Stuff" with all my media and docs. Will be deleting the one I had Win7 on ...
12
votes
3answers
3k views

Does 12.04 support hibernating to a swap file?

I'm about to reinstall Ubuntu on a netbook with a tiny disk. Because of the tiny disk size, I'd strongly prefer to have a swap file than a swap partition. However, I want to be able to hibernate. I ...
11
votes
3answers
2k views

Is the swap partition encrypted?

Selecting the encryption option at install time to encrypt the home partition. Does this enable encryption of the swap partition or is the swap partition unencrypted. If the swap partition is ...
11
votes
6answers
2k views

Do we need Swap partition on a LAMP server?

Do we need actually swap partition on the ubuntu-server with LAMP? I think I don't need it, but better to know for sure if it will not cause some unpredicted behaviour. Actually my thoughts were: ...
10
votes
3answers
1k views

Why is the default swappiness 60? What would be the effect if I lower the swappiness value for my desktop PC?

I was reading about swappiness in various forums and I saw some videos. Many stated that it's a good thing for desktop users to decrease the swappiness value below 60 (which is the default). Some ...
10
votes
4answers
9k views

How to permanently enable compressed ram swap? What version to use?

EDIT: In precise there's now zram-config. It's an upstart job compressing up to half of your ram spread over $(number of CPU cores) swap devices. It didn't allways start at boot but issuing sudo ...
10
votes
6answers
3k views

Swap shoots to 100% after a couple of hours of usage

For some reason or another, my swap usage will peak to 100% capacity after a couple hours of usage. My interface will then freeze, after which I have to wait 20 minutes time to be able to even move ...
9
votes
2answers
13k views

Adding a new swap file. How to edit fstab to enable swap after reboot?

I've deleted my existing swap partition due to some partitioning problem. I don't have a swap space now so I've created a swap file with: dd if=/dev/zero of=/root/myswapfile bs=1M count=1024 Here's ...
9
votes
3answers
8k views

Check if partition is encrypted

How do I check if a partition is encrypted? In particular I would like to know how I check if /home and swap is encrypted.
8
votes
4answers
10k views

Put swap on SSD or HDD?

New installation coming up. 120gb SSD for OS and HOME and 1tb HDD for storage. 16gb of ram which means 16gb of swap if I recall correctly. SSD space is too valuable for a swap partition right? If my ...
8
votes
6answers
15k views

How do I find out if I have a swap partition on my hard drive?

I used the 12.04 live cd to install Ubuntu over my Windows 7 partition and deleted everything so I just have Ubuntu on my laptop. But since during the installer I chose the simple "erase entire disk" ...
8
votes
2answers
5k views

“Swap not available” - I must manually “swapon” after every reboot

I am on Ubuntu 12.04, Thinkpad Edge 13, encrypted home. A message in the System Monitor tells me that swap is "not available". I can get it back using the swapon option in gparted (I thought I could ...
8
votes
2answers
204 views

How could one really get sensitive information from a swap partition?

When I google this question, I only get all sort of information on how to protect sensitive data, how to encrypt swap, and how "dangerous" could be to keep a "normal" swap in a linux system. But I ...
8
votes
4answers
9k views

Is my Swap (cryptswap) partition working properly?

I have a feeling it's not. I'm running Ubuntu 11.10 on a Toshiba Satellite L305-S5944 Laptop. Says I have 1.8 GiB of Ram (thought I had 2). When I look at the Resources tab in the System Monitor ...
7
votes
4answers
7k views

Is having the 'swap' partition at the 'beginning' better than at the 'end'?

I recently installed Ubuntu 11.04 onto a RAID0(stripe) device using the alternate installation disc and manually partitioned the HDs ext4 and swap partitions; during this process, I was reading in a ...
7
votes
3answers
12k views

How to disable cryptswap?

How can I disable cryptswap? I would like an unencrypted swap like before. This is on an ubuntu 9.10 system.
7
votes
1answer
1k views

Why is swappiness=10 recommended?

A value of swappiness=10 is recommended in Ubuntu's SwapFaq. Why is a value of 10 is recommended rather than swappiness=0? Are there any pros of 10 or cons of zero?
7
votes
4answers
28k views

How to decide on Swap size [duplicate]

Possible Duplicate: I have 16GB RAM. Do I need 32GB swap? I wanted to just confirm how much the size of Swap partition should be. Lots of places tell that the swap size should be twice the ...
7
votes
2answers
466 views

Is it safe to resize my swap partition on a production system?

I have a laptop with 4GB RAM, but when I first set it up, I had no plans to hibernate so I gave it 2GB swap. I don't want to use a swap file, so is it safe to resize the swap partition (and of course ...
7
votes
2answers
416 views

Swap, Swapiness and Standby: swapping starts when waking up

I'm running Ubuntu 12.04 on a Lenovo W500 (Core2Duo T9400, 4GB Ram) Current kernel: 3.2.0-32-generic #51-Ubuntu SMP Wed Sep 26 21:33:09 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux -- but the problems ...
6
votes
3answers
8k views

Ubuntu 12.04 increase swap [duplicate]

I have installed a Unbuntu 12.04 and want to increase my swap size from 1Gb to 4Gb can anyone tell how to do this? /dev/sda5 partition 1046524 568284 -1
6
votes
1answer
2k views

what is SWAP and how large a swap partition should I create? [duplicate]

I have a system with 4gb of RAM and Intel i5 processor. I want to know how much memory I should allocate to SWAP. Will allocating more memory help increase the system performance. In the past i have ...
6
votes
3answers
8k views

How do increase the swap size of my Wubi installation?

I have installed Ubuntu using the Wubi installer. So I have the default swap size of only 256MB. I have 1GB of RAM, so many times the system stars crying demanding more swap. I have read the Swap FAQ, ...
6
votes
2answers
1k views

Why is kswapd0 running on a computer with no swap?

I have a cloud server with ~14G of RAM and no swap. However, I occasionally see kswapd0 taking up some CPU when I run top. Why would kswapd0 be running at all if there's no swap space for it to ...
6
votes
1answer
2k views

How do I restore a swap partition I accidentally deleted?

I accidentally deleted my swap partition via gparted. (I'm still logged in the system so restoring should be easier) Can someone help me please? I'm not sure how to configure it because the Ubuntu ...
6
votes
2answers
489 views

How to configure how much RAM usage should to start swapping on Ubuntu

I always notice that Ubuntu start using swap, as soon as the RAM usage is around 60-70%. How to configure it so it should wait so RAM usage became 80-90%. And is there a way to empty the swap, as soon ...
6
votes
1answer
5k views

How do I setup an encrypted swap file?

When I installed Ubuntu, I setup an encrypted home partition. Now I have come to an issue where I am running out of memory because I haven't setup swap. How can I setup an encrypted swap file? A ...
6
votes
1answer
3k views

How large of a swap partition is needed to hibernate?

I've read this question, but it doesn't definitively answer my question. If I want my computer to be able to hibernate, do I need to have a swap partition as large as my RAM, or will Ubuntu wisely be ...
6
votes
2answers
4k views

Hibernate to a swap file

I have configured a new Ubuntu 10.10 installation in a Notebook to use a swap file, instead of using a swap partition. For default is not possible to get Ubuntu to hibernate using a swap file, so i ...
6
votes
1answer
2k views

Swap not being detected on 14.04 LTS

I upgraded from 12.04 to 14.04. When I opened my resource monitor, I noticed my swap was not detected. I installed Gparted, opened the program and started to look at my file tree. I noticed that my ...
6
votes
1answer
3k views

How do I get Ubuntu 12.04 to recognize encrypted swap partition so that I can hibernate?

I just installed Ubuntu 12.04 and used gparted to erase and enlarge my swap partition. When I rebooted, gparted said that the file partition for the swap was unknown. Gparted doesn't let me change ...
5
votes
4answers
13k views

Using usbdrive as ram in ubuntu

In windows it is possible to use usb flash drive as a virtual ram. I wonder if it is possible to do so in ubuntu? If it is, how could one do it? [Edit]: I mean Ready boost equivallent for ubuntu. I ...
5
votes
4answers
7k views

While installing Ubuntu, It asked me to allocate something called Swap Space, What exactly is it?

While installing Ubuntu, It asked me to allocate something called Swap Space, What exactly is it? What would happen if i dont allocate it?/ What is the use if i did allocate?