MovableType 4.01 and Bluehost CPU Exceeded Error

To run MovableType with a lot of entries (2000+) on Bluehost is painful, since Bluehost has CPU limitation. It checked the CPU a user account is using in 5 minutes. If it was more than certain amount (40 seconds or so), it pops up the CPU Exceeded Error. Recently, they even moved the interval to 60 seconds! That makes a rebuild in possible. It will throw away this error before rebuild complete – in my case, just after I rebuild several pages.

I believe many people experience the same problem: CPU Exceeded Error before MovableType rebuild complete. This is true in 4.0, and 4.01 is not better.

After seeking for the answer for a long time, I finally had an easy solution – to modify the JavaScript code a little bit, and ask MovableType to rest for longer time before each step of the rebuild. Here is what I did.

Propose:

Workaround the Bluehost CPU limit by setting the interval of the build long enough.

File changed:

/public_html/home/cgi-bin/mt/tmpl/cms/rebulding.tmpl

Line Number of the Line Changed:

20

Original:

setTimeout(‘doRedirect()’, 200);

Change to:

setTimeout(‘doRedirect()’, 20000);

That’s it.

You can even try smaller number than 20000 to build faster and then test. Maybe 10000, or several thousands are OK for your server, or your number of archives.

Update May 4, 2008

Changed the line from 60000 back to 20000.

2 Comments

  1. I even need to put 60,000 in that place for it to work.

  2. Also a tip to share, according to MovableType, using too many MTInclude tag, or plugin causes the slowness of rebuild.

Leave a Reply

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