Linux中的Apache服务查看和启动的方法

  打开terminal

  切换到root用户

  cd到/etc/rc.d/init.d/目录,并列出该目录下的所有文件,看看是否有httpd

  使用httpd -v查看已经安装的httpd的版本

  使用rpm -qa | grep httpd查看是否已经安装了httpd

  使用ps -ef | grep httpd查看httpd的进程

  使用service httpd status查看httpd的运行状态

  使用service httpd stop可以停止httpd

  使用service httpd start 可以启动httpd

  service httpd服务启动后,可以在浏览器中输入http://localhost浏览测试,如果能看到如下所示的页面,说明Apache能正常工作。

GitHub 加速计划 / li / linux-dash
10.39 K
1.2 K
下载
A beautiful web dashboard for Linux
最近提交(Master分支:23 天前 )
186a802e added ecosystem file for PM2 4 年前
5def40a3 Add host customization support for the NodeJS version 4 年前
Logo

旨在为数千万中国开发者提供一个无缝且高效的云端环境,以支持学习、使用和贡献开源项目。

更多推荐