Results 1 to 9 of 9
Thread: How do I recompile PHP?
-
08-31-2005, 03:20 PM #1Newbie
- Join Date
- Mar 2005
- Posts
- 19
How do I recompile PHP?
Hello,
A little background first. I have the need for an xml feed from an https url. PHP won't handle https w/ a base install, so i was told to try the cURL Library, but it needs php to be recompiled with --with-curl[=DIR] where DIR is the location of the directory containing the lib and include directories acording to the link above. It also needs OpenSSL as a dependency, which i dunno if this means another recompile parameter. I'm running php 4.3 on CentOS.
So how do i recompile php? How long will the website be down for? Where is php even located typically?
i'm worried that i'm gonna mess up the recompile, and i won't be able to get the site back up again....i'm thinking maybe i should just run a script locally to get the feed, then upload the results each week
Thanks for any help,
WeezelDS
-
08-31-2005, 04:57 PM #2Web Hosting Master
- Join Date
- Apr 2003
- Location
- NC
- Posts
- 3,093
Do you have any control panel?
Generall php recompiling is a huge pain in the *** if you are recompiling from an rpm version because all of the deps are not always present. Basically you want to load a phpinfo file and use the configure line at the top but modify it with what you want. If you hvae a control panel the process can be made easier or more complex depending.John W, CISSP, C|EH
MS Information Security and Assurance
ITEagleEye.com - Server Administration and Security
Yawig.com - Managed VPS and Dedicated Servers with VIP Service
-
08-31-2005, 05:11 PM #3Newbie
- Join Date
- Mar 2005
- Posts
- 19
I have cPanel X, as well as access to the WHM cPanel...however, i don't see anything involving messing w/ php....tho i could be wrong...
I figured I would a slightly modified version of the config line at the top of phpinfo, but i dunno how to change that config w/o recompiling
Thanks man
-
08-31-2005, 05:27 PM #4Web Hosting Master
- Join Date
- May 2003
- Location
- Florida
- Posts
- 902
WHM provides the ability to recompile PHP with Apache in the SOFTWARE section - if you have root WHM.
Just select Apache Update
- Select the link "load previous Config"
- Modify the required php options
- press start Build
-
08-31-2005, 05:41 PM #5Newbie
- Join Date
- Mar 2005
- Posts
- 19
Oh wow...that's a very helpful page
now on that page though, it says "Do not check every box as some options are not compatible or require third party software to be installed." Does this mean i need to do something special (install) the cURL package and the OpenSSL package?, or will checking them and rebuilding be fine?....the only thing the cURL package says for installation is gunzip it and recompile
i just don't want any down time, cuz if apache can't restart, i'll hafta get ahold of my host and get them to rebuild w/ default settings cuz i don't know how to do that via command line....even if i could i wouldn't want that kinda downtime
Thanks
-
08-31-2005, 05:58 PM #6Aspiring Evangelist
- Join Date
- Apr 2004
- Location
- Australia
- Posts
- 419
Hi,
You will be safe installing curl.. touchwood That message refers to things like postgreSQL etc etc...
If apache doesn't restart, you can rebuild it again through WHM, just remember the options you have at the moment
Cheers,
Matt
-
08-31-2005, 06:09 PM #7Newbie
- Join Date
- Mar 2005
- Posts
- 19
Thanks, but if apache new build gives errors, how am I going to rebuild it w/ the old options, if I can't access the WHM cuz apache is down? (Apache and WHM are on the same machine)
Thanks again
WeezelDS
-
08-31-2005, 07:06 PM #8Aspiring Evangelist
- Join Date
- Apr 2004
- Location
- Australia
- Posts
- 419
WHM doesn't run on apache, WHM is its own service Thus it can control apache and rebuild it without being affected.
Cheers
-
08-31-2005, 07:14 PM #9Web Hosting Master
- Join Date
- Apr 2003
- Location
- NC
- Posts
- 3,093
/scripts/easyapache via ssh will also do it and tends to work better. As posted above you hsould be fine with what you want to add, the problems come when you try to move to apache2 (which you should not do) with pcanel.
John W, CISSP, C|EH
MS Information Security and Assurance
ITEagleEye.com - Server Administration and Security
Yawig.com - Managed VPS and Dedicated Servers with VIP Service