When moving swap file locations, old swap file is left on each device
|Reported by:||kallisti5||Owned by:||nobody|
|Has a Patch:||no||Platform:||All|
Description (last modified by )
When you move swap locations, an old swap file is left on the previous device. This file can be erased by hand post-reboot, however it should be cleaned up automatically.
- Swap file location changed by user
- Swap file is in use by os... so it can't be erased
- After reboot, kernel uses new swap file specified.
- Old swap file still exists.
This is generally a problem of knowing where the old swap file *was* on reboot. a syscall may be a good solution (not requiring a reboot for swapfile changes, maybe a _kern_swap_reprovision call that will:
- Make the kernel flush the swap file into memory (if possible or return a failure)
- Make the kernel erase the current swap file from disk, and re-read the virtual_memory config to set up the new swap file.