How to install PowerMTA on CentOS?


PowerMTA is a Commercial Mail Transfer Agent used by leading email service providers.  Here are the steps to install PowerMTA on CentOS.

Step 1- Create a record for your domain name

  1. Note down your Server IP such as
  2. Login into your hosting account and access the Control Panel of your current domain name
  3. Go to DNS Zone File under your hosting account
  4. Change your current A record with the Server IP address


Step 2 – Set a hostname

Note – Assume your new domain name is –

You will need it to set a hostname or change server’s hostname in CentOS.  Here are the steps to follow

  1. Open the command terminal of your SSD Cloud Server
  2. Type hostname –f

Change your current hostname with a subdomain  by following command

  1. hostname

Now you have to change the domain name in your hosting account as well. Follow the steps given below

  1. Go to command terminal and type hostname –f

You should see a result like

Add a CNAME to your DNS name in your hosting record by following steps give below

  1. Login to your hosting account and go to control panel
  • Find yourdomain in the list
  • Click Manage DNS
  • On the Records page, click “Add” to add a new record
  • In the Type drop-down menu- select CNAME
  • Enter the required details and save the configuration


Step 3 – Install Php, Apache, Mysql, Perl, Zip, Unzip, iptables, net-tools, telnet

Type the commands below in your server SSH Command line

  1. yum -y install httpd
  2. yum -y install mysql.x86_64 mysql-devel.x86_64 mysql-server.x86_64 mod_auth_mysql.x86_64
  3. yum -y install php.x86_64 php-cli.x86_64 php-common.x86_64 php-mysql.x86_64
  4. yum -y install wget nano
  5. yum -y install perl zip unzip iptables* net-tools telnet
  6. yum search php-


Step 4- Installing PowerMTA on your SSD Cloud Server

Note- the steps given here are applicable to CentOS 64-bit

  1. Upload your RPM file to the /Home/ folder using any FTP software

Open the SSH command line and type the following commands

  1. rpm -ivh /home/PowerMTA-4.0r6.x86_64.rpm
  2. chmod 755 PowerMTA-4.0r6.x86_64.rpm

You will get a message signifying successful installation of PowerMTA on your SSD Cloud Server. Now, you have to create some folders for PowerMTA to work. Type the following command at SSH command line

  1. chown pmta:pmta /etc/pmta/config;
  2. chmod 640 /etc/pmta/config;
  3. mkdir -p /var/spool/pmtaPickup/;
  4. mkdir -p /var/spool/pmtaPickup/Pickup;
  5. mkdir -p /var/spool/pmtaPickup/BadMail;
  6. mkdir -p /var/spool/pmtaIncoming;
  7. chown pmta:pmta /var/spool/pmtaIncoming;
  8. chmod 755 /var/spool/pmtaIncoming;
  9. chown pmta:pmta /var/spool/pmtaPickup/*
  10. mkdir -p /var/log/pmta;
  11. mkdir -p /var/log/pmtaAccRep;
  12. mkdir -p /var/log/pmtaErr;
  13. mkdir -p /var/log/pmtaErrRep;
  14. chown pmta:pmta /var/log/pmta;
  15. chown pmta:pmta /var/log/pmtaAccRep;
  16. chown pmta:pmta /var/log/pmtaErr;
  17. chown pmta:pmta /var/log/pmtaErrRep;
  18. chmod 755 /var/log/pmta;
  19. chmod 755 /var/log/pmtaAccRep;
  20. chmod 755 /var/log/pmtaErr;
  21. chmod 755 /var/log/pmtaErrRep;

Now, you need to configure the HTTPD service.  At command terminal type the following commands

  1. nano /etc/httpd/conf/httpd.conf

Change the domain name values to yourdomain

  1. ServerName
  2. ServerAlias
  3. DocumentRoot /var/www/
  4. ErrorLog /var/log/httpd/error_log.
  5. TransferLog /var/log/httpd/access_log.
  6. ServerName XXX.XXX.XXX
  7. ServerAlias XXX.XX.XXX.XXX
  8. DocumentRoot /var/www/
  9. ErrorLog /var/log/httpd/error_log
  10. TransferLog /var/log/httpd/access_log

Leave a Reply

Your email address will not be published. Required fields are marked *

Security code * Time limit is exhausted. Please reload the CAPTCHA.

This site uses Akismet to reduce spam. Learn how your comment data is processed.