Use of CentOS7 systemctl, centos7systemctl
# View running services
Systemctl
# View the status of a service
Systemctl status httpd. service
# Start the service
Systemctl start foo. service
Example: systemctl start httpd. service
# Stop a service
Systemctl stop foo. service
Example: systemctl stop httpd. service
# Restart the service
Systemctl restart foo. service
Example: systemctl restart httpd. service
# Reload the configuration file
Systemctl reload foo. service
Example: systemctl reload httpd. service
# Start a service at startup
Systemctl enable foo. service
For example, systemctl enable httpd. service
# Disabling a service at startup
Systemctl disable foo. service
For example, systemctl disable httpd. service
# Check whether the service is started
Systemctl is-enabled foo. service
For example, systemctl is-enabled httpd. service