Swap partition unused

I switched from Ubuntu to EndeavourOS, reusing the partition layout originally created by Ubuntu. Everything works, except that EndeavourOS does not appear to use the swap partition (htop shows swap as 0K/0K). Here is the output from lsblk:

AME        FSTYPE FSVER LABEL      UUID                                 FSAVAIL FSUSE% MOUNTPOINT
├─sda2      ntfs         New Volume 98A47A64A47A44B2                                    
├─sda3      swap   1                790bd5a5-1117-488d-82fc-47555a69a1e5                
└─sda4      ext4   1.0              0edd68c9-4fa3-42d0-b7dd-dc6d45bac3e8  404.1G     0% /home
├─nvme0n1p1 ntfs                    26F69DB8F69D88A7                                    
├─nvme0n1p2 vfat   FAT32            CEEC-D1D8                                57M    40% /boot/efi
├─nvme0n1p4 ntfs                    8A64A61E64A60D4F                                    
├─nvme0n1p5 ntfs                    06D43BB5D43BA639                                    
└─nvme0n1p6 ext4   1.0              45dae5d4-27ea-44f9-8e09-cd94d8676334     95G    10% /

Note that I am dual-booting with Windows 10.

As you can see from the above, sda3 is a swap partition.

Any idea what the problem might be?

Is it listed in /etc/fstab ?

1 Like

Can we see the contents of /etc/fstab and the results of the command swapon

1 Like

If I’m reading this correctly, the swap partition is not listed by fstab:

# /etc/fstab: static file system information.
# ...
# <file system>             <mount point>  <type>  <options>  <dump>  <pass>
UUID=CEEC-D1D8                            /boot/efi      vfat    umask=0077 0 2
UUID=45dae5d4-27ea-44f9-8e09-cd94d8676334 /              ext4    defaults,noatime 0 1
UUID=0edd68c9-4fa3-42d0-b7dd-dc6d45bac3e8 /home          ext4    defaults,noatime 0 2

Unfortunately, the swapon command produces no output.

Are you using a swap file?

EDIT: likely not. Swap definition should be in /etc/fstab.

You need to add an entry to /etc/fstab for your swap partition.

That means you have no swap active.

1 Like

@dalto, that makes sense. How exactly should I do that?

@manuel, no, the intention is to use a swap partition. I read the Wiki, “Adding swap after installation”, and the way I understand it is that systems should just recognise the swap partition. The only difference between what I have and what’s in the first part of the wiki is that my swap partition is the location of the partition.

Like this:

UUID=790bd5a5-1117-488d-82fc-47555a69a1e5       none            swap            defaults        0 0


Thank you, @dalto and @manuel! Adding that entry to fstab worked.

1 Like

And welcome to the forum! :smile:


yea welcome at the forum :enos:
Do you manually partition on installer?

1 Like

Welcome to the forum @s767 :partying_face: :tada: :balloon:

1 Like

So, I did the following in the installer:

  1. formatted the existing ext4 partitions (sda4 and nvme0n1p6) and
  2. specified the mount points for /, /home and /boot.efi.

The mount points are the same as they were from my previous Linux install.

Maybe I missed something. Was I supposed to do something to the existing swap partition during the install process?

yes, i think calamares does not detect swap automatically, you need to set it to use, on a manual partition, if you choose automatic it will use a swap if you put it on before installation (swapon).


This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.