简单的写一些Mac下的Apache打开和关闭以及禁用IP.
打开和关闭
打开和关闭
查看mac apache版本 :
sudo apachectl -v
打开mac apache:
sudo apachectl start
关闭mac apache:
sudo apache stop
重启Mac apache:
sudo apachectl restart
禁用IP
编辑
vi /etc/apache2/httpd.conf或者
sudo vim /etc/apache2/httpd.conf
在最后加上
NameVirtualHost xx.xx.xx.xx
ServerName xx.xx.xx.xx
Order Allow,Deny
Deny from all
保存退出后记住重启apache还有其他方法不一一写出.