This post was intended for my blog http://linuxtricksandtips.blogspot.com/ but for some unknown reasons ended up here. I won't delete it, but all the guys coming here from a search, feel forwarded. :)
My Sabayon seems to have the habit of writing stuff into the swap and then forgetting about them. So I thought for a while, why not just empty the swap when it's full and I'm sure nothing is using it. Well, it turned out it's possible to do so. Thanks to this forum post, now I know how.
So, there are the commands:
$swapoff
$swapon
which can be safely used to turn on and off the swap. Now, the source site suggests using "$swapoff /dev/hdxx" but if you have only one swap partition (like I do) this is unnecessary.
All you need to do is (as sudo, of course):
$swapoff -a
and after it finishes emptying your swap,
$swapon -a
And it's done. You have a fresh swap file, which you can start trashing immediately.
Now, if you do that when a program is still writing to the swap, I don't know what will happen. Maybe something ugly, maybe not. I tested it when nothing was using the swap even though my ram was almost full, and I haven't noticed any problems for now.
Enjoy!
Denijane
08 ноември 2011, вторник
15 април 2011, петък
New domain
A little notification to all the users of http://kindlenookorsony.wordpress.com that the blog changed domain and now can found on http://www.kindlenookorsony.com . I can't say how extremely glad I am to escape the rules of wordpress.com. Now I can do to my site whatever I want. Cheers.
10 февруари 2011, четвъртък
30 декември 2010, четвъртък
The sleeping dragon wakes up - China, 2010
Click on the link to read my new post: The sleeping dragon wakes up - China, 2010.
23 декември 2010, четвъртък
Stuxnet - the worm to hell, 2010
Click here to check out my new post Stuxnet - the worm to hell, 2010.
17 декември 2010, петък
UFO sigthings, 2010
To read "UFO sightings, 2010" click on the link or check "http://after-the-pink-goat.blogspot.com"
05 декември 2010, неделя
Freedom - the biggest threat of all, 2010
New post - Freedom - the biggest threat of all, 2010 - published on After The pink Goat. Please click on the link to read or wait to be redirected.
Етикети:
chemical control,
wikileaks,
wiretap internet
Абонамент за:
Публикации (Atom)