• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

nginx 502 Error on Sending Forum Emails Via Sendmail

Gene Steinberg

Regular Pleskian
I have an 8-core dedicated server with 16GB RAM, Plesk 12.5.30 update 25 with PHP 7.0.4, PHP-FPM over Apache.

When sending batch text emails via our XenForo forum script (version 1.5.6), which uses sendmail, it times out about a third to two-thirds through the process with an nginx gateway 502 error.

I can find no relevant error logs for Apache or nginx.

XenForo was not able to offer much guidance, except to look for a PHP issue. Should I be allocating more resources in php.ini?

What should I change or set to deal with this problem?

Peace,
Gene
 
Usually, nginx gateway 502 error indicates problems with connection to the backend (Apache in our case). Apache can hang for many different reasons. Restart downtime, for example or something else. First of all, I would suggest you try to enable graceful Apache restart and check how it goes on after that. To enable:

# plesk db
mysql> REPLACE INTO misc VALUES ('restart_apache_gracefully', 'true');

To disable:

mysql> REPLACE INTO misc VALUES ('restart_apache_gracefully', 'false');
 
# plesk db

Reading table information for completion of table and column names

You can turn off this feature to get a quicker startup with -A


Welcome to the MariaDB monitor. Commands end with ; or \g.

Your MariaDB connection id is 239892

Server version: 10.0.24-MariaDB MariaDB Server


Copyright (c) 2000, 2016, Oracle, MariaDB Corporation Ab and others.


Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.


MariaDB [psa]> mysql> REPLACE INTO misc VALUES ('restart_apache_gracefully', 'true');

ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'mysql> REPLACE INTO misc VALUES ('restart_apache_gracefully', 'true')' at line 1

MariaDB [psa]>

So?

Peace,
Gene
 
Hi Gene,
you don't need the "mysql>" at the begining of the command...
Code:
MariaDB [psa]> REPLACE INTO misc VALUES ('restart_apache_gracefully', 'true');
Query OK, 1 row affected (0.03 sec)

MariaDB [psa]>

Regards

Lloyd
 
Back
Top