- Daemons are processes that wait or run in the background performing various tasks.
- To listen for connections, a daemon uses a socket.
- service often refers to one or more daemons
- Parallelization capabilities, which increase the boot speed of a system
- Automatic service dependency management which can prevent long time-out.
- A method of tracking related processes together by using Linux control groups
- On-demand starting of daemons without requiring a separate service
Listing unit files with systemctl
- Query the state of all units
# systemctl
- Query the state of selected service
# systemctl --type=service
- List full output of the selected service. Useful for detailed check and investigation
# systemctl status sshd.service -l
- To check whether the particular is active and enabled to start at boot time
# systemctl is-active sshd # systemctl is-enabled sshd
- List the active state of all loaded units. --all will include inactive units
# systemctl list-units --type=service # systemctl list-units --type=service --all
- View the enabled and disabled settings for all units
# systemctl list-unit-files --type=service
- View only failed services.
# systemctl --failed --type=service
Controlling System Services a. Status of a Service
# systemctl status sshd.serviceb. Disable of a Service
# systemctl disable sshd.servicec. Enable and verify the status of a Service
# systemctl enable sshd.service
# systemctl is-enabled sshd.serviced. Reload configuration file of a running service
# systemctl is-enabled sshd.service
No comments:
Post a Comment