upgrading to php 5.4

Home Forums BulletProof Security Pro upgrading to php 5.4

Tagged: 

Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #8415
    Krzysztof
    Participant

    Hello,

    I started to serach the web about php performance and found out that php 5.4 is much faster than my 5.2.17 so I started to think about upgrading it.

    What would be the procedure to BPS PRO work with new php? I have a VPS so I would have to tell my support to upgrade my php to 5.4. Should I tell them to do something else? Will BPS PRO work out of the box after such an upgrade or will I have to set it up again?

    #8416
    AITpro Admin
    Keymaster

    BPS and BPS Pro have been tested with PHP5.4 and there are no issues or problems.  The only factor for an issue would be if you are using a custom php.ini file and/or php/php.ini .htaccess handlers.  If you are not using a custom php.ini file and not using php/php.ini handler .htaccess code then you can simply upgrade to PHP5.4.

    If you are using a custom php.ini file and/or php/php.ini handler .htaccess code then you will need to delete your custom php.ini file and remove your php/php.ini handler .htaccess code from your root .htaccess file before upgrading to PHP5.4.

    #8417
    Krzysztof
    Participant

    I have a php.ini created with BPS PRO – the default one.  I just send that file to my admins and they uploded it to the server. The htaccess is default with some aditions from me for gzip etags etc.

    #8418
    AITpro Admin
    Keymaster

    You would want to use a new custom php.ini file that is based on the Server’s php.ini file for PHP5.4.  I assume your Server admins will do this for you and take any additional directive settings you have created/added in your custom php.ini file and add them to the new custom php.ini file for PHP5.4.  Most directive settings will probably be the same in your old custom php.ini file, but it is always best to start with the Server’s php.ini as the base for your custom php.ini file and then customize your particular website’s custom php.ini file.

    #8420
    Krzysztof
    Participant

    OK. I understand.

    Do you recomend going to php 5.4 from php 5.2.17?

    #8421
    AITpro Admin
    Keymaster

    I assume PHP5.4 is an improvement over PHP5.2 so yeah I think it is a good thing to upgrade.  I have not looked at what those specific improvements are, but in general any upgrade should be an improvement.  😉

    #8423
    AITpro Admin
    Keymaster

    Here is the list of improvements in PHP5.3.x

    http://php.net/releases/5_3_0.php

    Here is the list of improvements in PHP5.4.x

    http://php.net/releases/5_4_0.php

    #8424
    AITpro Admin
    Keymaster

    Looks like PHP5.4.x was a major release with this being the most important thing for end users and of course from a Host’s perspective:

    • Improved performance and reduced memory consumption
    #8425
    Krzysztof
    Participant

    I have send a message to my support and asked if the will do it, and put my custom php.ini created by BPS Pro again on the server. Now I’m waiting for their reply 😉

    #8468
    Krzysztof
    Participant

    Just to report – php 5.4 works OK. BPS php.ini works ok. I can see a bit of speed gain but I have to test a bit more. It is nut much – like from 1s to 0,9s but still if upgrading would give me 0,1s the it was worth it.

    I only get this warning:

    11-Aug-2013 15:51:47] PHP Strict Standards:  Unknown: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Berlin' for 'CEST/2.0/DST' instead in Unknown on line 0

    Now I’m considering to upgrade my mysql – it is a bit old to, and maybe it could also speed things up.

    #8473
    AITpro Admin
    Keymaster

    1 second to .9 second performance gain is HUGE!  That is awesome.

    In PHP5.4.x this change was made regarding the date.timezone php.ini directive.  Basically this is better error checking.  The error message you posted states that the problem was automatically corrected/fixed.

    Removed support for putenv(“TZ=..”) for setting the timezone.

    Removed the timezone guessing algorithm in case the timezone isn’t set with date.timezone or date_default_timezone_set(). Instead of a guessed timezone, “UTC” is now used instead.

    #8486
    Krzysztof
    Participant

    I’m sorry. It is my bad English again.

    The site was loading in 1s and now it load in 0,9s so the speed gain is about 0,1s. I hope that this time I wrote it corect 😉

    #8489
    AITpro Admin
    Keymaster

    That is still pretty good when you look at it as a percentage.  Your site loads 10% faster than it did before.  Nice.  😉

Viewing 13 posts - 1 through 13 (of 13 total)
  • You must be logged in to reply to this topic.