-
-
Notifications
You must be signed in to change notification settings - Fork 296
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Swap file automatically generates on boot #673
Comments
try: sudo systemctl stop swapfile.swap sudo systemctl mask mkswap.service sudo rm -rf /swapfile |
Yes, I had to mask it. Disabling the services didn't work. Thank you so much :) |
Wouldn't that also disable swap file generation on other specified devices? For example, I might want to put a swap file on the nvme drive. The problem is the 1GB swap file still generates regardless on the root partition of the SD card, I've tested that. |
I can confirm. After disabling the swap using |
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 14 days. Thank you for your contribution! |
I have not tested it, but my assumption is that this is just happening for the desktop version and not the server version. Maybe someone has time to test my assumption. If I have some time I will probably test it myself. During my try to fix #1130 @Joshua-Riek pointed me to the project / package ubuntu-rockchip-settings. If my interpretation of this project / package is correct, then the swapfile is generated, because of the settings here: https://github.com/Joshua-Riek/ubuntu-rockchip-settings/tree/noble/data/desktop (mkswap.service and swapfile.swap). Those settings to not exist in the server version here: https://github.com/Joshua-Riek/ubuntu-rockchip-settings/tree/noble/data/server Therefore my interpretation (which may be wrong) is that these settings were done by intention for the desktop version and not by accident. Therefore my assumption would be that this is not a bug in the sense of an unexpected behaviour, because it looks like an architectual decision. However I agree that a swap file does not make much sense on a board with a lot of RAM. But if one would remove the settings then people using boards with few RAM would have to always activate swap consciously. I have no idea what @Joshua-Riek tought's were. But when thinking of it, this might be a topic for the wiki here: https://github.com/Joshua-Riek/ubuntu-rockchip/wiki |
Hi,
I'm using the ubuntu-22.04.3-preinstalled-server-arm64-orangepi-5-plus image and there is a 1GB swap file in root that automatically generates every reboot. This is on a SD card so I definitely don't want a swap file to be generated on reboot. I have to manually disable swap by logging into SSH after rebooting. Deleting the file doesn't prevent it from regenerating on reboot.
This file doesn't exist in /etc/fstab. Is this documented anywhere? I can't find any details about this on google. What's the best method to permanently disable this?
Or does the x-systemd.growfs automatically generate it?
The text was updated successfully, but these errors were encountered: