VISL

Member
Jul 14, 2007
12
0
51
Hi,

My WHM/Cpanel is currently running PHP 4.4.7, I want to upgrade it to PHP 5.2.1 or similar but am concerned I could mess everything up.

Is it easy to do via the WHM Panel? I'm concerned I may break the server completely.

Thanks
 

madaboutlinux

Well-Known Member
Jan 24, 2005
1,051
2
168
Earth
Go through this carefully :-
Login to server as root.
Execute the script :-
/scripts/easyapache >>> after few minutes it will display 8 options.
Select 7th
Select 'PHP Module ---->' and hit enter.
Select PHP version using space bar.
Select 'Exit', again select 'Exit' and then say 'Yes' to save.
Let the script execute completely.

After completion, restart apache:
service httpd stop
service httpd start

OR

You can also install it from WHM if you wish to.
Goto Software >> Apache update >> click on "Load Previous Config"
Select the PHP version you wish to.
Click Save.


Execute php -v to check the version.
 

cPanelDavidG

Technical Product Specialist
Nov 29, 2006
11,216
10
313
Houston, TX
cPanel Access Level
Root Administrator
Hi,

My WHM/Cpanel is currently running PHP 4.4.7, I want to upgrade it to PHP 5.2.1 or similar but am concerned I could mess everything up.

Is it easy to do via the WHM Panel? I'm concerned I may break the server completely.

Thanks
I usually use WHM and have recompiled/upgraded PHP a few times myself. It's easy, just read carefully as there are some things that can adversely interact with PHP (such as mod_perl).

In EA3 we are separating the items that are experimental and more clearly indicating the modules that may cause issues so you wont need to worry as much. EA3 will be available in cPanel 11 Stage 2.
 

VISL

Member
Jul 14, 2007
12
0
51
Just tried an upgrade from WHM.

Httpd failed :( Reverting back to 4.47 to see if I can at least get web pages working again.
 

VISL

Member
Jul 14, 2007
12
0
51
Glad to know I'm not the only one!

I was thinking .... 'I can't even click a few buttons!!'
 

jayh38

Well-Known Member
Mar 3, 2006
1,213
0
166
Just tried an upgrade from WHM.

Httpd failed :( Reverting back to 4.47 to see if I can at least get web pages working again.
If the compile completed without errors, then apache needs some small adjustments to start. This could be something as simple as extensions listed in php.ini needing updates or even httpd.conf commenting out php5 instead of 4, etc.


I would suggest hiring someone to upgrade for you if you do not know what to look for or ask your data center if you are on a managed box. Feel free to PM me if you need assistance.
 

dataferret

Member
Jul 20, 2007
5
0
51
Worth checking when upgrading from PHP4 to PHP5 - look at which version of Ioncube is installed and upgrade/downgrade Ioncube to the most suitable version for your PHP install