How to restart apache

藏色散人
Release: 2019-08-09 09:47:52
Original
8841 people have browsed it

How to restart apache

How to restart apache?

Restart Apache under windows

● First, right-click "This Computer" and click "Manage";

● In In the "Computer Management" program that opens, double-click "Services and Applications."

● In the "Computer Management" program that opens, double-click "Services".

● In the list of all services, click "apache";

● If apache is not started, "Start Service" is displayed on the left, and clicking it will start the service

● If apache has been started, "Stop and Restart Service" is displayed on the left. Clicking it will perform the operation

Restart Apache under Linux

Assume the apahce installation directory of the current Linux user is /usr/local/apache2, then use the following commands in the command line terminal to start, stop and restart apache.

1. The command to start apahce:

/usr/local/apache2/bin/apachectl start apache
Copy after login

2. The command to stop apache:

/usr/local/apache2/bin/apachectl stop
Copy after login

3. The command to restart apache:

/usr/local/apache2/bin/apachectl restart
Copy after login

To be in To restart the Apache server without interrupting the current connection, you should run:

/usr/local/sbin/apachectl graceful
Copy after login

If the current user's apache has been installed as a Linux service, you can use the following command to perform the above operations.

1. Start apache

service httpd start
Copy after login

2. Stop serving apache

service httpd stop
Copy after login

3. Restart apache

service httpd restart
Copy after login

For more Apache related knowledge, please visitApache usage tutorial column!

The above is the detailed content of How to restart apache. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template