Failed to activate swap swap partition error on boot



I’m gettin a “failed to activate swap swap partition” error on boot. im still pretty new to linux in general, used ubuntu for the last few months. brand new to manjaro though. I installed manjaro by erasing my hd and doing automatic setup if that matters. and my system in encrypted, anyways it says to check systemctl status dev-sda3.swap. this is the output:

$ systemctl status dev-sda3.swap
 dev-sda3.swap - Swap Partition
   Loaded: loaded (/run/systemd/generator.late/dev-sda3.swap; generated; vendor preset: disabled)
   Active: failed (Result: exit-code) since Wed 2017-02-22 20:28:15 CST; 2min 49s ago
     What: /dev/sda3
     Docs: man:systemd-gpt-auto-generator(8)
  Process: 322 ExecActivate=/sbin/swapon /dev/sda3 (code=exited, status=255)

Feb 22 20:28:15 Veronica systemd[1]: Activating swap Swap Partition...
Feb 22 20:28:15 Veronica swapon[322]: swapon: /dev/sda3: read swap header failed
Feb 22 20:28:15 Veronica systemd[1]: dev-sda3.swap: Swap process exited, code=exited status=255
Feb 22 20:28:15 Veronica systemd[1]: Failed to activate swap Swap Partition.
Feb 22 20:28:15 Veronica systemd[1]: dev-sda3.swap: Unit entered failed state.

lsblk -no UUID /dev/sda3 outputs this:

$ lsblk -no UUID /dev/sda3


[slothboy@Veronica ~]$ sudo blkid
[sudo] password for slothboy: 
/dev/sda1: UUID="4230-9A75" TYPE="vfat" PARTUUID="f3ff9241-cd79-4745-8290-8322a53ee9ca"
/dev/sda2: UUID="c3133261-9989-467d-806c-4bcb8d06879c" TYPE="crypto_LUKS" PARTUUID="a03c540a-d77b-466f-bab3-b2068939639e"
/dev/mapper/luks-c3133261-9989-467d-806c-4bcb8d06879c: UUID="274717dd-83b6-4c0b-b6ce-7ab5ccfebd98" TYPE="ext4"
/dev/sda3: UUID="34580649-1e7c-4f7e-a5ee-88e67d7776c4" TYPE="crypto_LUKS" PARTUUID="9d42e05a-f895-4b5b-8c22-c96d57dfef3d"
/dev/mapper/luks-34580649-1e7c-4f7e-a5ee-88e67d7776c4: UUID="be58db13-8994-4fb7-b3da-3f5881806522" TYPE="swap"

fdisk -l:

$ fdisk -l
Disk /dev/sda: 119.2 GiB, 128035676160 bytes, 250069680 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 1E786D95-E81C-4F99-98FD-9D3D9A9F5DA2

Device         Start       End   Sectors   Size Type
/dev/sda1       4097    618497    614401   300M Microsoft basic data
/dev/sda2     618498 231612851 230994354 110.2G Linux filesystem
/dev/sda3  231612852 250067789  18454938   8.8G Linux swap

Disk /dev/mapper/luks-c3133261-9989-467d-806c-4bcb8d06879c: 110.1 GiB, 118267012096 bytes, 230990258 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/mapper/luks-34580649-1e7c-4f7e-a5ee-88e67d7776c4: 8.8 GiB, 9446831104 bytes, 18450842 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

swapon --show:

$ swapon --show
/dev/dm-1 partition 8.8G   0B   -1

and this is my fstab file:

# /etc/fstab: static file system information.
# Use 'blkid' to print the universally unique identifier for a device; this may
# be used with UUID= as a more robust way to name devices that works even if
# disks are added and removed. See fstab(5).
# <file system>                           <mount point>  <type>  <options>  <dump>  <pass>
UUID=4230-9A75                            /boot/efi      vfat    defaults,noatime 0       2
UUID=274717dd-83b6-4c0b-b6ce-7ab5ccfebd98 /              ext4    defaults,noatime,discard 0       1
UUID=be58db13-8994-4fb7-b3da-3f5881806522 swap           swap    defaults,noatime,discard 0       0
tmpfs                                     /tmp           tmpfs   defaults,noatime,mode=1777 0       0

Is there a noticable problem here? Am I providing enough information to help fix my situation? any help would be awesome. Ive been looking through forums all night and cant figure out what the deal is. I’m not too sure what this /dev/dm-1 line is all about after swapon --show? shouldnt that say /dev/sda3? thanks

Swap patition not mounted (using pre install encryption)
Encrypted swap not working

there is errors on /etc/fstab


Thanks. I’d never even heard of an fstab file a week ago, so dealing with a bit of a learning curve here. Can you be a bit more specific please? I’m off to read about fstab semantics but some more help in the right direction would be appreciated!


What desktop are you running? As far as /etc/fstab my swap line differs but I am not sure it is your problem.
Here is my swap line, you will need to rebuild grub and reboot for this to take effect. Of course use your own uuid etc…
UUID=eab2e60d-699e-4453-b7f1-d62de900fce2 swap swap defaults 0 0

Update: anyway you should probably boot with live usb and run fsck or other file system checker (gparted).


did you encrypt the swap and with the same crypt as / , in same time ?
swap was on when you try to crypt /swap ?
did you swap off before ?


I’m using KDE. I’ll try the changes you suggested.


It was encrypted with the manjaro automatic install. I’m not sure the method or anything… I just checked the box that said “Encrypt” or whatever and entered a password… I didn’t manually do anything really, Manjaro installer did everything including partitioning the hard drive and setting up the swap in the first place.


I had a similar problem after installing Manjaro 17.0, erase disk, encryption, let installer do the rest. After booting, swapon --show didn’t even show any output, just returned to the prompt!.

I fixed it by replacing the UUID=… in /etc/fstab with /dev/mapper/luks…

Maybe a bug in the installer? I tried for several days to get an installation with manual partitioning (/boot, /, /home, swap) working but gave up and just used the installer default encryption scheme.


I recently setup Manjaro I3 community edition and setup a custom partition table. I enabled encryption for /, /boot, swap, /home. When the system would boot none of my partitions would mount. Updating my fstab to /dev/mapper/luks… absolute paths instead of UUID’s seems to have solved the issue for me. I’m wondering if this is a bug in the installer as well.


I’ve reported this as a bug:


Did a fresh Manjaro I3 install two months ago (december 2017) with full disk encryption enabled and didn’t realise since yesterday that swap is not activated.
Updating fstab to /dev/mapper/luks… absolute paths instead of UUID’s solved the issue for me also :slight_smile: