Email Piping

Email piping automatically imports emails for an email address into the support ticket system. As a result, clients can open and reply to tickets via email without the need to log in to the Client Area first.

  • Email piping and email importing use separate configurations and are distinct methods of importing email replies.
    • We recommend using email piping if you use cPanel & WHM and only import email replies from one domain.
    • We recommend using email importing if you use other control panels or if you want to import email from multiple domains.
  • Your mail service provider is separate from your configuration for email piping. You can update this configuration at Configuration () > System Settings > General Settings in the Mail tab.

Configuring Email Piping

To configure email piping for a support department:

  1. Go to Configuration () > System Settings > Support Departments.
    Before you can set up email piping, you must configure your support departments at Configuration () > System Settings > Support Departments. Add each of your departments and the email address that you assigned to them.
  2. Copy the command to use to pipe email from Ticket Importing using Email Forwarders file path (or, if you use cPanel, only copy the file path).
    Importing Cron Commands
    If you have customized the location of the crons directory, ensure that the file path matches that location. The path will resemble the following example:
    \| php -q /home/username/public_html/whmcs/crons/pipe.php
    
  3. Use your preferred method to configure email piping.

Test Email Piping

After you set up email piping, try sending a test email. If the piping is correctly configured, the system will open a new ticket. For testing purposes, do not use an admin’s email address to send the message.

Common Errors

If the system didn’t pipe an email into the ticket system, check the Ticket Mail Import Log at Configuration () > System Logs. This shows all the emails that WHMCS’s email piping feature has processed and any errors that may have occurred.

If you cannot find any log entries in Ticket Mail Import Log at Configuration () > System Logs, the most likely cause is that the pop.php cron job isn’t set up or is unable to successfully import the emails.

You can also find error details by temporarily adding the following line to the configuration.php file and then visiting http://www.example.com/crons/pop.php, where www.example.com is your WHMCS installation’s location:

$pop_cron_debug = true;
For more information about updating the configuration.php file, see The configuration.php File.

Below are the most common errors:

Error or IssueDescriptionRecommended Solution
Connection refusedThis error usually indicates that the server’s firewall is blocking traffic to Google.Check your firewall for configurations that might block traffic to google.com. To do this, run the following command on your WHMCS installation’s server:

telnet gmail-pop.l.google.com 995
Too many login failures
or
Can not authenticate to POP3 server
or
Password command failed
These errors indicate a problem with your support department’s email credentials or an intermittent issue between WHMCS and your mail server.

If you are using Google, this may also indicate that Google blocked WHMCS from authenticating.
Check the support department’s email configuration at Configuration () > System Settings > Support Departments. Ensure that the username, password, and port are correct and that the hostname is a valid FQDN that resolves correctly.

If you find errors and the mailserver has blocked you, you may need to wait out the block time. If you have the correct access to your mailserver, you may be able to whitelist the WHMCS IP address or remove the block instead.

If your credentials in WHMCS are correct and you are using Google, you may need to adjust your Google account settings to allow external applications to log in using a username and password. You can check whether Google blocked WHMCS from logging in by going to Recent Activity in Gmail™ and looking for Suspicious sign in prevented messages.
The system could not find the ticket ID. (WHMCS 8.4 and later)
or
Ticket ID Not Found (WHMCS 8.3 and earlier)
This error indicates that you are sending via an email address that you assigned to an admin. Admins can reply to tickets but cannot open new ones.Send the email from an email address that is not associated with an admin on your WHMCS installation.
The system blocked a potential email loop. (WHMCS 8.4 and later)
or
Blocked Potential Email Loop (WHMCS 8.3 and earlier)
This error indicates that WHMCS received a large number of emails from the same email address, indicating an auto-responder loop. To break the cycle, WHMCS did not import the email.

By default, the system will block any new tickets from the offending address if it receives 10 emails from the same address within a 15 minute period.
Investigate why the email address is sending a large number of emails.

You can reconfigure the criteria for blocking an email address in Ticket Reply Email Limit in the Mail tab at Configuration () > System Settings > General Settings.
The sender's email address is not registered. (WHMCS 8.4 and later)
or
Unregistered Email Address (WHMCS 8.3 and earlier)
This error indicates that you have chosen to only allow registered clients to open tickets in this department.Uncheck Clients Only for the support department at Configuration () > System Settings > Support Departments to allow others to open tickets in the support department.
The system prevented an autoresponder from opening a ticket. (WHMCS 8.4 and later)
or
Prevented an Auto Responder from Opening a Ticket (WHMCS 8.3 and earlier)
This error message indicates that an email contained the Auto-Submitted attribute in its headers. The system will not import these messages into the WHMCS support ticket system. This avoids sending an auto-reply in accordance with the RFC 3834 email specification.

In WHMCS 8.1 and later, the system sends support emails with RFC 3834-compliant headers by default.
  • You can disable this at Configuration () > System Settings > General Settings in the Mail tab.
  • Regardless of your settings, WHMCS will not accept email that email that contains the Auto-Submitted header via email piping or email importing.
Adjust your settings to allow the email.
Unable to communicate with the WHMCS installationThe cron.php file could not communicate with the WHMCS installation. This typically occurs when you have customized the location of the /crons directory. The cron.php file will look for the WHMCS directory in the location in the /crons/config.php file.To resolve this error, update the /crons/config.php file.
For steps to do this, see Troubleshooting the System Cron.
local delivery failedThis error indicates that the forwarder entry is incorrect. The message is not correctly going to the pipe.php script, possibly due to a permissions issue.Ensure that the /crons/pipe.php file uses 755 permissions. Then, try the following variations of the email forwarder command:

|/usr/bin/php -q /home/username/public_html/whmcs/crons/pipe.php

|/usr/local/bin/php -q /home/username/public_html/whmcs/crons/pipe.php
Sender Verify FailedThe SMTP server requires a valid account on the server to send from.Check the From Address setting in the Mail tab at Configuration () > System Settings > General Settings is not blank and you have entered a valid address that is authorized to send mail through the SMTP server.
WHMCS Pop Cron Did Not RunThis error indicates that you have entered POP3 details for a support department, but you haven’t configured the required cron job or finished importing the emails.Configure the cron job and ensure that it runs correctly.
Duplicated email reply imports.If the system is importing the same email replies multiple times, this often indicates that you have configured multiple support departments in WHMCS to use the same mailbox.Configure a separate email account for each support department.
DirectAdmin sending emails twice.A line in the exim.conf file is causing email piping on a DirectAdmin server to send email twice.Remove or comment the unseen line in the exim.conf file. You can do this by adding a # character to the beginning of the unseen line.
For more information, see DirectAdmin’s Forums.
  • For additional help, contact your hosting provider or mailserver administrator.
  • If you continue to have problems after performing the steps above and are using Google, contact Google or visit their GSuite discussion forums. Google may have blocked your server from accessing their mail servers.

Last modified: June 14, 2024