所以,经过2天努力想象为什么Macports Apache httpd
突然决定停止工作,最后它归结为:
$ sudo bash -x /opt/local/apache2/bin/apachectl -k start
ARGV='-k start'
HTTPD=/opt/local/apache2/bin/httpd
test -f /opt/local/apache2/bin/envvars
. /opt/local/apache2/bin/envvars
test x '!=' x
DYLD_FALLBACK_LIBRARY_PATH=/opt/local/lib
export DYLD_FALLBACK_LIBRARY_PATH
LYNX='lynx -dump'
STATUSURL=http://localhost:80/server-status
ULIMIT_MAX_FILES=
'[' x '!=' x ']'
ERROR=0
'[' 'x-k start' = x ']'
case $ARGV in
/opt/local/apache2/bin/httpd -k start
ERROR=1
exit 1
这是房间里的大象,ERROR=1
是什么意思?
我运行调试,我得到上面相同的错误:
$ sudo bash -x /opt/local/apache2/bin/apachectl -k start -e Debug -E /dev/stdout
本地Mac Apache没有返回错误并httpd
正常启动,它给出了这个输出:
$ sudo bash -x /usr/sbin/apachectl -k start
ACMD=-k
ARGV='-k start'
HTTPD=/usr/sbin/httpd
test -f /usr/sbin/envvars
. /usr/sbin/envvars
test x '!=' x
DYLD_LIBRARY_PATH=/usr/lib
export DYLD_LIBRARY_PATH
LYNX='lynx -dump'
STATUSURL=http://localhost:80/server-status
ULIMIT_MAX_FILES=
LAUNCHCTL=/bin/launchctl
LAUNCHD_JOB=/System/Library/LaunchDaemons/org.apache.httpd.plist
'[' x '!=' x ']'
ERROR=0
'[' 'x-k start' = x ']'
case $ARGV in
/usr/sbin/httpd -k start
ERROR=0
exit 0
这可能是我最后一次对此,2天后我愿意放弃!
sudo bash -x /opt/local/apache2/bin/apachectl -k start -e Debug -E /dev/stdout
我也得到ERROR = 1并退出1