Alternative PHP Cache, APC, on GoDaddy Hosting

By | 03/10/2012

As I said earlier, Godaddy is implementing APC ( a great cache functionality) on its shared hosting plans. In a recent contact I had with them, it looks like the launch day is tomorrow.
Godaddy.comTill now, Godaddy disabled (by default) this extension for clients using actually Zend and Ioncube; good choice; as these 3 extensions represent an incompatibility risk.

If you want to benefit from the “awaited” great performance boosts with APC, you need to disable Zend and Ioncube extension and enable APC.

Enable APC on Godaddy.com Hosting

Here is how to do it:

Open your working php.ini/php5.ini file (it might be in a subfolder or on your root folder)

If you have Zend or Ioncube extensions enabled, and you are sure your sites will work without them, disable these extensions by putting a semicolon (;) in front of each line about them.

If you see “apc.enabled=0” somewhere, comment this line with a semicolon (;) too.

Godaddy Optimized php(5).ini

Here is a nice PHP5.INI (for Godaddy Linux hosting plans using FastCGI PHP 5.3)

Save it as php5.ini and place it in the public root of your server (/html folder). Careful to backup your current php5.ini.

Now you have APC enabled by default!

Check if APC is installed on your Godaddy account

You can check it by opening a php file containing phpinfo() function.

Here is an example:

Save the code below in a file named: phpinfo.php

Now you can put this file next to your websites files (careful not to overwrite existing files) and browse to this file with your web browser. Search in the page for “APC”, you will know now…

Keep in mind that these settings apply if you have your hosting with any of Godaddy Resellers, like “DomainsPricedRight.com”

 

One thought on “Alternative PHP Cache, APC, on GoDaddy Hosting

  1. Kenji Sakamoto

    The “SendBufferSize” value of apache server is important too for PHP cache.
    Though APC is available, if buffer size is too small processing time will not be decreased.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *

CommentLuv badge