Today I finally could spin off a server running cPanel on Amazon Web Services. You can find great instructions here: How to Setup cPanel on AWS
and here also very important if you want to run your own nameservers: Amazon EC2 Nameservers on AWS
But if you plan on using Amazon’s own Linux flavor, make sure you do this two steps before installing cPanel:
- Remove dovecot from your yum.conf file excluded list;
- Run the following command to install all the required libraries.
yum install xz-compat-libs-5.1.2-8alpha.11.amzn1.x86_64
That will make sure you have the latest required RPM packages to run cPanel on Amazon Linux.
If you don’t run these steps above, you may get this error:
- ssystem [BEGIN]: /scripts/rdate
open3: exec of /scripts/rdate failed at /home/cPanelInstall/selfgz23309/install line 238.
Removing /root/installer.lock.
or this one:
liblzma.so.0()(64bit) is needed by dovecot-1:2.2.19-1.cp1148.x86_64
Before running the command to install cPanel, make sure your hostname is a public accessible, something like: ec2-IPADDRESS.us-west-2.compute.amazonaws.com
After all that everything runs fine and you just need to finish setting up your cPanel/WHM installation.
Do you run cPanel on AWS? Let me know how does that work for you.
Update 1: I had to edit the named.conf file to allow queries since we are running our own nameservers. Make sure you check the line for:
allow-query { any; };
Update 2: Once cPanel is running you should really optimize it’s settings for your server. I found this link very informative:
Optimize MySQL & Apache on cPanel/WHM server
Make sure also you follow the firewall/security settings mentioned there.