Written by James McDonald

April 21, 2011

My Dreamhost Piwik archive.sh cron job has been failing with an error:

php binary not found. Make sure php5 or php exists in PATH.

I presume this is due to dreamhost changing the PATH env not to include /usr/local/bin so the Piwik archive.sh code is not finding the php binary.

My current answer is to comment out the search for a php binary and add it hard coded as below.

#for TEST_PHP_BIN in php5 php php-cli php-cgi; do
#  if which $TEST_PHP_BIN >/dev/null 2>/dev/null; then
#    PHP_BIN=`which $TEST_PHP_BIN`
#    break
#  fi
# done

# added by james because the above wasn't finding php
# possibly because the PATH env is not right

PHP_BIN=/usr/local/bin/php

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

The reCAPTCHA verification period has expired. Please reload the page.

You May Also Like…

Squarespace Image Export

To gain continued access to your Squarespace website images after cancelling your subscription you have several...

MySQL 8.x GRANT ALL STATEMENT

-- CREATE CREATE USER 'tgnrestoreuser'@'localhost' IDENTIFIED BY 'AppleSauceLoveBird2024'; GRANT ALL PRIVILEGES ON...

Exetel Opt-Out of CGNAT

If your port forwards and inbound and/or outbound site-to-site VPN's have failed when switching to Exetel due to their...