3CX on AWS lightsail getting swap drive error

Status
Not open for further replies.

ArtR

Customer
Basic Certified
Joined
Sep 13, 2018
Messages
48
Reaction score
5
Hi All,
Have a staging v16 (16.0.0.1375) instance running on AWS lightsail but seeing this error on the customer portal of my instance :-

Hardware Memory Swap No SWAP drive available! Execution of any actions on this machine are not possible at the moment.Error

Everything seems to be working, and as it's staging I'm not too worried but would like to see how to resolve anyway.

Anyone else seeing similar or know how to fix?

thanks
Art.
 
Hi @ArtR

We see the same on our portal with our own Linux VPS V16 test instance.

We haven't lodged a case with 3CX yet until V16 is fully released as we were not certain it's fully functional yet :)

@YiannisH_3CX may be able to raise a case.
 
  • Like
Reactions: ArtR
Hi @pact
Yes agree that while it's still in beta not a big issue, just checking in case I was the only lucky one.

Will see how the error goes as we move through to release. Thanks for the reply.

Art
 
So that's not technically a 3CX error. The AMI simply doesn't create a swap by default. Instructions on how to do this on Lightsail available here:

https://www.airix.net/en/fm-cloud-b...cloud-vps/9-swap-file-on-aws-lightsail-ubuntu

Azure also doesn't create swap and it needs to be created there as well.

While it's not a 3CX Application error, it is a PBXExpress or 3CX ISO deployment, so 3CX may need to update the ISO deployment to include swap file creation or provide instructions to generate it. (Now that they appear to be checking for it in the Instance Manager, 3CX certainly doesn't complain about it missing).
 
Generally speaking when a machine has enough memory the swap file is not needed. For instances will lower resources however you may need to create one.
You can do so with the following commands:
Bash:
dd if=/dev/zero of=/swapfile bs=1M count=1024
chmod 0600 /swapfile
mkswap /swapfile
swapon /swapfile
echo 80 > /proc/sys/vm/swappiness

Then in /etc/fstab you need to enter:
/swapfile   none    swap    defaults        0 0

Note: If your system is working OK then i would not recommend performing this change. Only perform this is you are facing an issue and you have a full backup stored away from the PBX machine. This change could hurt your hard drive and cause various issues.
 
Last edited:
just a small FYI, for small instances PBXexpress will create soon swap-files automatically.
 
just a small FYI, for small instances PBXexpress will create soon swap-files automatically.

Thanks for the follow up @StefanW , will this also apply to the ISO image?
 
Thanks for the follow up @StefanW , will this also apply to the ISO image?

yes, however in PBXexpress it is more "pressing" as the general RAM is low in rented instances. Normal x86 hardware comes general with 4GB+ (exception Pi).
 
Status
Not open for further replies.

Forum statistics

Threads
111,914
Messages
589,712
Members
164,785
Latest member
Texas Clay -