nefelim4ag / systemd-swap

Script for creating hybrid swap space from zram swaps, swap files and swap partitions.
GNU General Public License v3.0
550 stars 81 forks source link

Failed deactivating swap at shutdown #199

Closed solsticedhiver closed 2 years ago

solsticedhiver commented 3 years ago

It is not a major issue but since I installed and enabled systemd-swap (no change to /etc/sys/system/swap.conf) my swap parittion fails to be deactivated at shutdown:

Jan 29 15:38:02 rhea systemd[1]: Failed deactivating swap /dev/disk/by-uuid/75bd5d3b-3426-4283-94a9-27aa9ff4dbb7.
Jan 29 15:38:02 rhea systemd[1]: Failed deactivating swap Swap Block/Partition.
Jan 29 15:38:02 rhea systemd[1]: Failed deactivating swap /dev/vg/swap.
Jan 29 15:38:02 rhea systemd[1]: Failed deactivating swap /dev/disk/by-id/dm-uuid-LVM-YFlfWaSRmCHY3Z3HEcoQU2ssfuxGnDU3Qx6BhO1gx7tRKTunCyiqw1rden289vsk.
Jan 29 15:38:02 rhea systemd[1]: Failed deactivating swap /dev/disk/by-id/dm-name-vg-swap.
Jan 29 15:38:02 rhea systemd[1]: Failed deactivating swap /dev/mapper/vg-swap.
Jan 29 15:38:02 rhea systemd[1]: dev-disk-by\x2duuid-75bd5d3b\x2d3426\x2d4283\x2d94a9\x2d27aa9ff4dbb7.swap: Failed with result 'exit-code'.
Jan 29 15:38:02 rhea systemd[1]: dev-mapper-vg\x2dswap.swap: Failed with result 'exit-code'.
Jan 29 15:38:02 rhea systemd[1]: dev-disk-by\x2did-dm\x2dname\x2dvg\x2dswap.swap: Failed with result 'exit-code'.

This is a swap in a LVM lv inside a LUKS container

oold commented 2 years ago

You're not supposed to use an independent swap partition if systemd-swap is running. Please refer to the readme. Feel free to reopen the issue if you're feeling like I misunderstood the issue at hand.