Which command can be used to check the status of a service?

Prepare for the LPI 101-500 Certification Exam. Utilize flashcards, navigate multiple choice questions, and benefit from hints and explanations. Begin your Linux certification journey today!

The command "systemctl" is used to interact with the systemd system and service manager, which is the default init system on many modern Linux distributions. When checking the status of a service, the "systemctl status service_name" command provides comprehensive information about the specified service, including whether it is currently running, any active processes associated with it, and its recent logs. This tool is integral for managing services, enabling administrators to start, stop, enable, disable, and monitor service statuses effectively.

While "service" is a command used to manage services in SysVinit and potentially other init systems, it is less versatile compared to systemctl for services managed by systemd. The "status" command doesn't directly correlate to checking the status of services; it is not a standalone command in this context. The "check" command does not exist in standard service management in Linux systems, making it irrelevant for this purpose. Therefore, "systemctl" stands out as the most appropriate choice for checking the status of a service in current Linux environments that utilize systemd.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy