Incorrect CONFIGURATION ERROR message displayed when nginx fails to be reloaded after configuration change to website
ISPConfig version 3.1.1p1 on Ubuntu 16.04 LTS
When nginx fails to restart, due to a bad configuration directive, the true reason for the failure seems not to be reported accurately.
First error in system log:
(warning) nginx did not restart after the configuration change for website example.com. Reverting the configuration. Saved non-working config as /etc/nginx/sites-available/example.com.vhost.err
Okay, that's fine. The next message in the system log:
(warning) Reason for nginx restart failure: nginx: the configuration file /etc/nginx/nginx.conf syntax is ok nginx: configuration file /etc/nginx/nginx.conf test is successful
So, it seems that ISPConfig is fetching the wrong error message and displaying it in the interface (see attached screenshot).
I'm not sure if it's relevant or not, but I tried pasting the contents of example.com.vhost.err into example.com.vhost and running "nginx -t" and nginx reports that the configuration file is OK.
I wish I had more information as to why this happens, but, alas, I do not.