![]() |
httpd: unrecognized service 的解决方案
最近在搭建Apache服务器的时候突然出现了 “httpd: unrecognized service”的错误,无法解析httpd服务,记录下解决方案。
问题描述 在使用命令“service httpd restart|start|stop”的时候会出现“httpd: unrecognized service”这样的错误。 原因分析 可能是安装了其他的与本服务有冲突的程序,导致本服务无法解析。 也有可能是系统服务损坏,导致无法启动。 解决方案 将httpd注册为系统服务即可,可使用如下代码: Code:
#cd /usr/local/apache/bin/ ##进入你的Apache安装目录下的bin文件夹下 #cp apachectl /etc/rc.d/init.d/httpd如果在执行”cp apachectl /etc/rc.d/init.d/httpd“命令时,出现 Code:
cp: not writing through dangling symlink ‘/etc/rc.d/init.d/httpd’只要 ”rm /etc/rc.d/init.d/httpd“,问题即可解决。 |
| All times are GMT +8. The time now is 07:57 AM. |
Powered by vBulletin Version 3.8.7
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.