2025-03-14 21:59:59 -06:00
|
|
|
# swapoff
|
|
|
|
|
|
|
|
|
|
> Disable devices and files for swapping.
|
|
|
|
|
> Note: `path/to/file` can either point to a regular file or a swap partition.
|
2025-04-03 20:36:56 -06:00
|
|
|
> More information: <https://manned.org/swapoff.8>.
|
2025-03-14 21:59:59 -06:00
|
|
|
|
|
|
|
|
- Disable a given swap area:
|
|
|
|
|
|
|
|
|
|
`swapoff {{path/to/file}}`
|
|
|
|
|
|
|
|
|
|
- Disable all swap areas in `/proc/swaps`:
|
|
|
|
|
|
2025-04-03 20:36:56 -06:00
|
|
|
`swapoff {{[-a|--all]}}`
|
2025-03-14 21:59:59 -06:00
|
|
|
|
|
|
|
|
- Disable a swap partition by its label:
|
|
|
|
|
|
|
|
|
|
`swapoff -L {{label}}`
|