The Daemon Diagnostic Vector
On an Ubuntu Linux server, background applications (such as the Nginx web server, the MySQL database, or the SSH daemon) run as persistent services. When a website goes offline or a connection fails, the absolute first step in troubleshooting is determining whether the underlying service has crashed, hung, or failed to start correctly during boot. Relying on application-level error logs is often useless if the core daemon itself is no longer active in memory.
How to Check the Status of a Service
Modern Ubuntu deployments utilize the systemd initialization architecture, meaning all service diagnostics are handled by the systemctl command.
1. Open your terminal application or connect to your server via SSH.
2. To query the exact, current operational state of a specific service, execute the following command (replacing nginx with the name of the service you are investigating):
sudo systemctl status nginx
3. The terminal will immediately output a highly detailed diagnostic block.
4. Look for the line beginning with Active:. If the service is operating correctly, it will read active (running) in green text.
5. If the service has crashed or was manually stopped, it will read inactive (dead) or failed in red text.
6. The bottom lines of the output will also display the most recent log entries generated directly by that specific daemon, which often instantly reveals the exact error preventing it from starting.
Press the Q key to exit the status report and return to the standard command prompt.