SWAP Disappeared from nodes

Speedy059

Renowned Member
Jul 3, 2010
13
1
68
I'm just noticing this today after I logged into a couple of LXC's that their swap was missing. Then to my surprise, the nodes themselves have 0 swap. The swap must have disappeared after an update or something?

All the nodes are using ZFS for storage option. I could of sworn the nodes used to have swap, and so did the LXC's.

How do I go about enabling it again?
 
You should first check the output of swapon --show on the node, in case it is actually enabled and the problem is elsewhere.
If there is no output, check the output of lsblk to see if you can identify the partition that was being used for swap. If you see it there, you should be able to enable it with swapon /dev/sdX. Following this, make sure there is also an entry for it in /etc/fstab.
If there is no swap partition, you can follow the Debian docs to create one: https://wiki.debian.org/Swap
 
Looks like it never had swap. Since i'm using ZFS i'll create a partition on the rpool/ROOT/swap and then assign it.

Thanks
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!