Suspend fix for Joli OS

Hello dear peoplez! Vacation! In my book that means spending more time with linux and figuring out small problems which might or might not drive me nuts. Since one of the previous upgrades I have not been able to suspend my netbook, which runs Joli OS 1.2. This drives me nuts. I figured out I have too little swap space for suspend or hibernation to work. If you, like me, installed Joli OS from Windows, using a windows installer (Wubi), go ahead and follow this small tutorial. If you installed Joli OS on its own partition, you should use GParted to increase the size of the swap partion (I won't go through that here though). Happy tweaking! 

UPDATE1: I've added a link to a script which will turn off WLAN when entering suspend mode. This is also essential for suspend to work with Vaio P on Joli OS (or Ubuntu). Your suspend troubles may depend on either too small swap space and/or WLAN keeping your netbook awake.

Estimated time needed: 20 minutes. 
First, check your free swap space. Press Alt+F1 to open a terminal and write:


In the same window information about RAM (mem), buffer and swap will appear. Compare the sizes of the mem and swap values. They should be around the same sizes. In my case my swap had changed size to 10% the size of my RAM! Let's get started!

Press Ctrl+Shift+T to open a new tab in the terminal window. And write the following:

sudo bash
(write your password to login as root)
swapoff -a
cd /host/jolicloud/disks
mv swap.disk swap.disk.backup
dd if=/dev/zero of=swap.disk bs=1024 count=EnterYourRAMSizeHere
(this will take about 15 minutes for 2 Gb, so take a nap or watch your favourite TV show!)
mkswap swap.disk
swapon -a

In order for us to see if the change had an effect write:


again to see the current RAM, buffer and swap sizes.

UPDATE2: Here is the link to the script that will turn off WLAN when suspending your netbook. Note that the power LED on the wireless switch will be on, even during suspend.

No comments: