As some users already mentioned you should always examine the error_log in order to check what’s wrong with the configuration:
You can either
cat the file:
tail -f /var/log/nginx/error.log
tail -n 200 /var/log/nginx/error.log
You can also check for any syntax errors:
sudo nginx -t
In newer OSs like CentOS 7 you can use use the journalctl command to see the logs that the journald daemon has collected.
When used alone, every journal entry that is in the system will be displayed within a pager (usually less) for you to browse. The oldest entries will be up top:
We have an existing tutorial on how to view and manipulate systemd logs.
Hope that this helps!
Some of the most compelling advantages of systemd are those involved with process and system logging. Using other systems, logs are usually dispersed throughout the system, handled by different daemons and tools, and can be fairly difficult to interpret when they span...