Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
linux_wiki:swap_files [2015/02/05 22:14] billdozor [Verify Swap is Used] |
linux_wiki:swap_files [2016/03/18 23:10] billdozor [Swap Files] |
||
---|---|---|---|
Line 1: | Line 1: | ||
====== Swap Files ====== | ====== Swap Files ====== | ||
- | Description: | + | **General Information** |
- | ==== Create a Swap File with DD ==== | + | Swap can be increased by resizing partitions, adding new partitions formatted as swap, or by creating swap files. Swap files are useful if you need to utilize existing volumes and cannot resize the swap partition. |
+ | |||
+ | **Checklist** | ||
+ | * Distro(s): All | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Create a Swap File with DD ===== | ||
Create a block file called " | Create a block file called " | ||
Line 15: | Line 22: | ||
* count: 1024K * 1024K = 1048576K (or 1GB) | * count: 1024K * 1024K = 1048576K (or 1GB) | ||
- | ==== Format the File ==== | + | ===== Format the File ===== |
<code bash> | <code bash> | ||
Line 21: | Line 28: | ||
</ | </ | ||
- | ==== Enable the Swap ==== | + | ===== Enable the Swap ===== |
<code bash> | <code bash> | ||
Line 27: | Line 34: | ||
</ | </ | ||
- | ==== Verify Swap is Used ==== | + | ===== Verify Swap is Used ===== |
<code bash> | <code bash> | ||
Line 37: | Line 44: | ||
</ | </ | ||
- | ==== Enable this Swap File After a Reboot ==== | + | ===== Enable this Swap File After a Reboot |
Edit /etc/fstab and add: | Edit /etc/fstab and add: |