Home>Article>Operation and Maintenance> How to start the service in centos
You can use systemctl to start/stop/restart services.
To start a service, you need to use the following command:
# systemctl start httpd.service
This will start the httpd service, which in our case is the Apache HTTP server.
To stop it, you need to use this command as root:
# systemctl stop httpd.service
If you want to restart, you can use the restart option. If the service is running, it will restart the service; if the service is not running , it will start.
Recommended tutorial:centos tutorial
The above is the detailed content of How to start the service in centos. For more information, please follow other related articles on the PHP Chinese website!