歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> 關於Linux >> selinux未禁用導致httpd無法使用非80等默認端口解決

selinux未禁用導致httpd無法使用非80等默認端口解決

日期:2017/3/1 15:27:52   编辑:關於Linux
selinux未禁用導致httpd無法使用非80等默認端口解決 現象 修改httpd端口為9080,並啟動提示如下: [root@haifeng ~]# service httpd start Starting httpd: (13)Permission denied: make_sock: could not bind to address [::]:9080 (13)Permission denied: make_sock: could not bind to address 0.0.0.0:9080 no listening sockets available, shutting down Unable to open logs [FAILED] 問題解決: 1、先不重啟禁用selinux使用setenforce 0 2、設置配置文件/etc/selinux/config和/etc/sysconfig/selinux裡面都禁用selinux,以後重啟生效。 網友提示: 1、先是查看9080端口有沒被其他程序占用 #netstat -anpt | grep 9080,未被占用 2、查看權限問題, 3、查看selinux狀態 #getenforce 狀態為 Enforcing 可能是配置未生效,/etc/sysconfig/selinux裡面配置是禁用,/etc/selinux/config這裡是未禁用 注:getenforce/setenforce查看和設置SELinux的當前工作模式
Copyright © Linux教程網 All Rights Reserved