How to check the swap file in linux:
root> swapon -s
Disk Usage :
root> df -m
Memory usage:
root> free -m
To create 1GB swap space
root> sudo dd if=/dev/zero of=/swapfile bs=1M count=1024
root> sudo mkswap /swapfile
root> sudo swapon /swapfile
root> /swapfile swap swap defaults 0 0
root> /swapfile swap swap defaults 0 0
To Add additional Swap space:
root> dd if=/dev/zero of=/extraswap bs=1M count=6144
root> mkswap /extraswap
root> swapon /extraswap
root> vi /etc/fstab
/extraswap none swap sw 0 0
Add the above Line.
Sort Disk usage :
Sort Disk usage :
du -H --max-depth=1 /home/user
No comments:
Post a Comment