Site Tools


linux:general:swap

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
linux:general:swap [2018/08/22 11:24] – [What is Swap?] lunetikklinux:general:swap [2019/02/12 14:45] (current) lunetikk
Line 12: Line 12:
 <code> <code>
 mkswap /swap/swapfile mkswap /swap/swapfile
-chown root:root /tmp/swapfile+chown root:root /swap/swapfile
 chmod 600 /swap/swapfile chmod 600 /swap/swapfile
 </code> </code>
 Add the swapfile to swap Add the swapfile to swap
-swapon /tmp/swapfile+<code> 
 +swapon /swap/swapfile 
 +</code>
  
 === Remove a swapfile from swap === === Remove a swapfile from swap ===
  
-Turn off the swapfile (used swap will be moved to other swap or memory, might take a while) +List the swapfiles 
-swapoff /swap/swap+<code> 
 +swapon -s 
 +</code> 
 +Turn off the swapfile (used swap will be moved to other swap or memory, might take a while)\\ 
 +<code> 
 +swapoff /swap/swapfile 
 +</code>
  
 \\ \\
 \\ \\
-~~DISCUSSION~~+~~DISCUSSION:closed~~
linux/general/swap.1534929874.txt.gz · Last modified: 2018/08/22 11:24 by lunetikk