diff --git a/create_vhost_php.sh b/create_vhost_php.sh index 59913e6..f57af93 100755 --- a/create_vhost_php.sh +++ b/create_vhost_php.sh @@ -177,7 +177,7 @@ fi # - _httpd_binary="`which httpd`" if [ -z "$_httpd_binary" ]; then - _httpd_binary="`ps -C httpd -f | grep -e \"^root\" | awk '{print$8}'`" + _httpd_binary="$(ps -axu | grep httpd | grep -e "^root" | grep -v grep | awk '{print$11}')" if [ -z "$_httpd_binary" ]; then if [ -x "/usr/local/apache2/bin/httpd" ]; then _httpd_binary="/usr/local/apache2/bin/httpd"