Linux Mint - Free and powerful

Monday, 13 January 2014

2. Creating a Linux Mint Power Server - Memory and Swap

Upgrading the memory and or swap file

In case you are using a pathetic I-B-M foundation server you will find that 2 GB of memory is not enough. Also, if you did a default install you will only have a swap file of 2 GB. In my case I had a faulty 1 GB stick that left me with only 1 GB.

While waiting for some memory to arrive from ebay I decided to create two swap files on two separate disks to temporarily increase the memory capacity. Apparently the kernel will load balance between the two files. (this is of course overkill and pretty pointless but nevertheless it was good to test the mechanism)


Create the swap files

dd if=/dev/zero of=/swapfile1 bs=1024 count=10485760
dd if=/dev/zero of=/mnt/ADD-DOMINO/swapfile2 bs=1024 count=10485760

# Check the directory listing to see if you have files name

Issue the mkswap command

mkswap /swapfile1
mkswap /mnt/ADD-DOMINO/swapfile2

Edit fstab

gedit /etc/fstab &

/swapfile1                 none    swap    sw      0       0
/mnt/ADD-DOMINO/swapfile2  none    swap    sw      0       0 inhere


Switch on the swap file

swapon /swapfile1
swapon /mnt/ADD-DOMINO/swapfile2

Set the swappiness

echo 20 > /proc/sys/vm/swappiness

echo 90 > /proc/sys/vm/swappiness

To make this permanent.

Edit - /etc/sysctl.conf and adjust vm.swappiness



















After my real memory upgrade

I reinstalled this server so the default installer created the swap partition. 































0 comments :

Post a Comment

Thank you for taking the time to comment. Your opinion is important and of value and we appreciate the positive feedback! If you are "Negative Nancy" then please do us, and humanity, a favor, and piss off.

Total Pageviews

Google+ Followers

Pages

Blog Archive

Popular Posts

Recent Comments

Rays Twitter feed

Ads

Web sites come and go and information is lost and therefore some pages are archived. @rayd123. Powered by Blogger.