Best practice installing PHP

I'm having some problems with loading problems on my site. I've activated APC for PHP and it works for a few hours, then my WordPress reports error 500 but I've been reading up on APC, well, a little bit at least. It seems that APC is "dead" on PHP 5.5 and now I'm wondering this.

Should I install lang/php5 for future simplicity or can I install lang/php55 and just be done with it? What is the difference between these ports?
 
Re: Best praxis installing PHP

hnk said:
I'm having some problems with loading problems on my site. I've activated APC for PHP and it works for a few hours, then my WordPress reports error 500 but I've been reading up on APC, well, a little bit at least. It seems that APC is "dead" on PHP 5.5 and now I'm wondering this.
Should I install lang/php5 for future simplicity or can I install lang/php55 and just be done with it? What is the difference between these ports?
Have you tracked down what is causing your 500 errors? Log files (php, Wordpress) are generally a good place to start.

lang/php5 and lang/php55 are different versions of php. lang/php5 is php-5.4.26. lang/php55 is php-5.5.10. See:
  • /usr/ports/lang/php5/distinfo
  • /usr/ports/lang/phop55/distinfo
You should install the version of lang/php that you require. I'm not sure what you mean by the terms "future simplicity" and "just be done with it" when referencing lang/php5 and lang/php55, respectively.
 
Re: Best praxis installing PHP

Yes I'm still looking into what the cause of the 500 errors can be, APC is the main cause but I haven't really come that far in the troubleshooting process of APC.

Regarding lang/php5 and/or lang/php55, why is lang/php5 just 5.4.26 if there is a 5.5 version available? If I deinstall lang/php5 and install lang/php55, besides the version difference what other differences are there between these ports?
 
Re: Best praxis installing PHP

Depending a bit on installed extensions, PHP can die in quite interesting ways when the extension loading order is wrong, although that usually manifests itself when Apache is started. Are you possibly running threaded lang/phpX as a www/apacheXX module?

I'd say the best practice these days is running lang/phpXX as either a fastcgi or an fpm process, instead of using the php5.so Apache module.

-Reko
 
Re: Best praxis installing PHP

hnk said:
Regarding lang/php5 and/or lang/php55, why is lang/php5 just 5.4.26 if there is a 5.5 version available?
Not everyone wants to be or can be on the latest version of a given port, especially if it has not been fully tested it in their environment. It is common to see installations with software running in production that is one version behind the latest version, and with the latest version running in test.

hnk said:
If i deinstall lang/php5 and install lang/php55, besides the version difference what other differences are there between these ports?
In general, vendors issue new versions of their software to add/enhance the feature set and/or include bug/security fixes, some of which can be significant between major version bumps. For php specifically, you should consult the PHP 5 Change Log on the PHP Web Site for further details.
 
Back
Top