PHP 5.2.3 Instal


#1

I logged on the shell and tried to run the file. It started but than stopped because of a ‘stat’ because php.cgi doesn’t exist. What did I do wrong?


#2

What “file” did you try to “run”? What exactly was/were the error message(s)?

From the information you have provided, I don’t even know what you did, and couldn’t begin to guess what you might have done “wrong”. :wink:

–rlparker


#3

Sorry, I ran the PHP 5.2.3 Install file provided in the Wiki. It just stopped and said ‘stat error No such file/directory in php5/bin/php.cgi’


#4

Well., that helps a little but still doesn’t tell us what you have done. I assume, since you did not link it, that you are talking about this page on the DreamHost wiki, which has two different scripts. If not, please let me know what page on the wiki you are using.

If you are using the page I linked above, which of the two scripts provided are you using?

Note the specific instruction on the page re. installing 5.2.3 via the first script provided:

This script does not work if you are compiling PHP version 5.2.3 or greater. To make this script work when compiling PHP version 5.2.3 or greater, change the third from last line from this…

cp ${INSTALLDIR}/bin/php ${HOME}/${DOMAIN}/cgi-bin/php.cgi

…to this…

cp ${INSTALLDIR}/bin/php-cgi ${HOME}/${DOMAIN}/cgi-bin/php.cgi

Did you use the first script, and have you done this?

–rlparker


#5

Correct page, correct script and correct edit. I was trying to do everything that you said, and changed the line and it still gave me an error. Let me try again, and see if I can get it to work.


#6

If that doesn’t work for you after double checking everything and trying again, I suggest you post what you have put in the following variables, as that might give someone here a clue as to what is happeing:

The domain in which to install the PHP CGI script.

export DOMAIN=“your.domain.com

Where do you want all this stuff built? I’d recommend picking a local

filesystem.

Don’t pick a directory that already exists! We clean up after

ourselves at the end!

SRCDIR=${HOME}/source

And where should it be installed?

INSTALLDIR=${HOME}/php5

Set DISTDIR to somewhere persistent, if you plan to muck around with this

script and run it several times!

DISTDIR=${HOME}/dist

–rlparker


#7

cp: cannot stat `/home/theflea912/php5/bin/php-cgi’: No such file or directory

That is correct error I got again.
Those variables are all the default ones, except export DOMAIN, which is qantasvirtual.net.

From the looks of it, I get almost complete than it quits on me.


#8

Try running this script, and let me know if that works for you instead :slight_smile:


Chips N Cheese - Custom PHP installs and the like!


#9

No previous php.ini to restore.
Striping debug info from cgi-bin files…
rm: cannot lstat .' in.’: Stale NFS file handle

Thats what I got with the new script


#10

Yup, I still don’t understand the “rm: cannot lstat” error (I can’t reproduce it in any environment but DH’s), but if you got that far, it means it worked :wink:


Chips N Cheese - Custom PHP installs and the like!