欢迎来到资源库(www.zyku.net)

Linux

当前位置:首页 > 服务器教程 > Linux > 启动

linux 下 apache启动、停止、重启命令

时间:2018-11-23|栏目:Linux|点击:|我要投稿

基本的操作方法:

本文假设你的apahce安装目录为/usr/local/apache2,这些方法适合任何情况

apahce启动命令:

/usr/local/apache2/bin/apachectl start

apache停止命令

/usr/local/apache2/bin/apachectl stop

apache重新启动命令:

/usr/local/apache2/bin/apachectl restart

要在重启 Apache 服务器时不中断当前的连接,则应运行:

/usr/local/sbin/apachectl graceful

如果apache安装成为linux的服务的话,可以用以下命令操作:

service httpd start 启动
service httpd restart 重新启动
service httpd stop 停止服务

Linux系统为Ubuntu

一、Start Apache 2 Server /启动apache服务

# /etc/init.d/apache2 start
or
$ sudo /etc/init.d/apache2 start

二、 Restart Apache 2 Server /重启apache服务

# /etc/init.d/apache2 restart
or
$ sudo /etc/init.d/apache2 restart

三、Stop Apache 2 Server /停止apache服务

# /etc/init.d/apache2 stop
or
$ sudo /etc/init.d/apache2 stop

(资源库 www.zyku.net)

关于我们 | 版权申明 | 寻求合作 |

重要申明:本站所有的文章、图片、评论等内容,均由网友发表或上传并维护或收集自网络,仅供个人学习交流使用,版权归原作者所有。

如有侵犯您的版权,请与我们联系,我们将在24小时内进行处理、任何非本站因素导致的法律后果,本站均不负任何责任。

联系QQ:95148658 | 邮箱:mb8#qq.com(#换成@)

苏ICP备2020066115号-1

本网站由提供CDN加速/云存储服务