Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $ sudo apachectl stop
- AH00557: httpd: apr_sockaddr_info_get() failed for My-MacBook-Pro.local
- AH00558: httpd: Could not reliably determine the server's fully
- qualified domain name, using 127.0.0.1. Set the 'ServerName' directive
- globally to suppress this message
- httpd (no pid file) not running
- $ sudo lsof -i:80
- COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
- httpd 3722 _www 4u IPv6 0x123456789abcdef 0t0 TCP *:http (LISTEN)
- httpd 3724 _www 4u IPv6 0x123456789abcdef 0t0 TCP *:http (LISTEN)
- httpd 3725 _www 4u IPv6 0x123456789abcdef 0t0 TCP *:http (LISTEN)
- httpd 56048 root 4u IPv6 0x123456789abcdef 0t0 TCP *:http (LISTEN)
- httpd 56055 _www 4u IPv6 0x123456789abcdef 0t0 TCP *:http (LISTEN)
- $ apachectl status
- Go to http://localhost:80/server-status in the web browser of your choice.
- Note that mod_status must be enabled for this to work.
- $ curl http://localhost:80/server-status
- <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
- <html><head>
- <title>403 Forbidden</title>
- </head><body>
- <h1>Forbidden</h1>
- <p>You don't have permission to access /server-status
- on this server.<br />
- </p>
- </body></html>
- $ sudo nano /etc/apache2/httpd.conf
- $ sudo apachectl restart
- AH00557: httpd: apr_sockaddr_info_get() failed for My-MacBook-Pro.local
- AH00558: httpd: Could not reliably determine the server's fully
- qualified domain name, using 127.0.0.1. Set the 'ServerName' directive
- globally to suppress this message
- ServerName localhost
- LoadModule status_module libexec/apache2/mod_status.so
- $ netstat -an | grep '.80' | grep -i Listen
- tcp46 0 0 *.80 *.* LISTEN
- $ sudo apachectl stop
- Password:
- $ apachectl status
- Go to http://localhost:80/server-status in the web browser of your choice.
- Note that mod_status must be enabled for this to work.
- $ netstat -an | grep '.80' | grep -i Listen
- $
- $ ps aux | grep httpd | grep -v grep
- _www 45379 0.0 0.0 2509492 1084 ?? S 6:27PM 0:00.00 /usr/sbin/httpd -D FOREGROUND
- root 45376 0.0 0.1 2511540 11292 ?? Ss 6:27PM 0:00.19 /usr/sbin/httpd -D FOREGROUND
- $ sudo apachectl stop
- Password:
- $ ps aux | grep httpd | grep -v grep
- $
- $ apachectl -S
- AH00557: httpd: apr_sockaddr_info_get() failed for GSSLA15122293
- AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1. Set the 'ServerName' directive globally to suppress this message
- VirtualHost configuration:
- *:80 myserver.example.com (/private/etc/apache2/extra/httpd-vhosts.conf:24)
- ServerRoot: "/usr"
- Main DocumentRoot: "/Library/WebServer/Documents"
- Main ErrorLog: "/private/var/log/apache2/error_log"
- Mutex proxy: using_defaults
- Mutex default: dir="/private/var/run/" mechanism=default
- Mutex mpm-accept: using_defaults
- Mutex proxy-balancer-shm: using_defaults
- PidFile: "/private/var/run/httpd.pid"
- Define: DUMP_VHOSTS
- Define: DUMP_RUN_CFG
- User: name="_www" id=70 not_used
- Group: name="_www" id=70 not_used
- apachectl -t -D DUMP_INCLUDES
- /usr/sbin/apachectl -t -D DUMP_INCLUDES
- /usr/sbin/apachectl start
Add Comment
Please, Sign In to add comment