No swap message in gui

I’m getting this message in notification area, it does not give any instructions but says:

Your system has no swap space. This should be fixed as soon as possible. Once fixed issue a reload to remove this message.

I have never made any changes memory or storage - could someone please advise a fix?

edit: sorry FreePBX 13.0.151 Asterisk Version: 11.22.0

Its a new warning that was added recently. Its very clear. Says you have no swap. Meaning your PBX is not setup with memory swap so if you run out of memory it can not use disk swap. Very dangerous.

Thanks for the info - I’ve never done anything like this before but will give it a go creating one.
will this feature be available if I carry out a fresh install with latest distro?


Seeing the same error message on my system.
How do I create swap on existing production system?

Thanks in advance

If you built your system without a swap partition ,( swapon -a. would show,)

Is the easiest solution

Hi dicko,
if I used that command shown in the link where would the swap file be? I’m worried that if I run the command shown it will fill a partition which is already near full, the partition details of my disk below:

fdisk -l

Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x108de80e

Device Boot Start End Blocks Id System
/dev/sda1 * 1 39 307200 83 Linux
Partition 1 does not end on cylinder boundary.
/dev/sda2 39 30402 243888128 83 Linux
/dev/sda3 30402 30402 1208 82 Linux swap / Solaris

That is a very strange partitioning , how did you mage to do that?

If you follow that guide

dd if=/dev/zero of=/swapfile bs=1024 count=65536

swapfile will obviously be in the / directory just adjust to suit, to see better how your drive(s) are being used:-
df -h

(also after reading that link again I suggest you add “chmod 600 /swapfile” as only root should have access to it)

Hi dicko,
this is what the command shows:

Filesystem Size Used Avail Use% Mounted on
/dev/sda2 229G 8.5G 209G 4% /
tmpfs 943M 0 943M 0% /dev/shm
/dev/sda1 283M 46M 223M 17% /boot

did you say that adjustments would be made or do I have to adjust?


That will make a 64M swapfile in / and you have 209G available so the only adjustment is to how big you want your swap space to be

man dd

you have a swap partition, so use it:

sudo mkswap /dev/sda3
sudo swapon /dev/sda3

check if /dev/sda3 is listen in

cat /proc/swaps
cat /etc/fstab

It’s too small to be a useful swap partition.

ahh sorry, i didn’t noticed it’s only 1 block.