User Tools

Site Tools


docu:csheet:sysadm:mem:add_swapfile

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
docu:csheet:sysadm:mem:add_swapfile [2020/08/18 15:55]
admin created
docu:csheet:sysadm:mem:add_swapfile [2020/08/21 10:06] (current)
admin
Line 9: Line 9:
 # create an empty 1G file with 1024KB block size # create an empty 1G file with 1024KB block size
 dd if=/dev/zero of=/root/swapfile01 bs=1M count=1024 dd if=/dev/zero of=/root/swapfile01 bs=1M count=1024
 +
 +# or... a simpler way to do it, using fallocate (if installed)
 +fallocate -l 1G /root/swapfile01
 +
  
 # give the swap file 0600 perms # give the swap file 0600 perms
Line 29: Line 33:
 # or the fancy htop viewer # or the fancy htop viewer
 htop htop
- 
-</code> 
  
 </code> </code>
docu/csheet/sysadm/mem/add_swapfile.1597766150.txt.gz · Last modified: 2020/08/18 15:55 by admin