1.creat a file.

   dd if=/dev/zero of=/swapfile bs=1024 count=65536

2.make swap file 

    mkswap /swapfile

3.enable swap file

   swapon /swapfile

4.add swap file instance into /etc/fstab for auto enable swap file after reboot.

   /swapfile swap swap defaults 0 0

 

文章標籤
全站熱搜
創作者介紹
創作者 horace papa 的頭像
horace papa

Horace papa's life

horace papa 發表在 痞客邦 留言(0) 人氣(2)