Suramya's Blog : Welcome to my crazy life…

September 23, 2008

SugarCRM Silent upgrade issues and fixes

Filed under: Computer Software,Knowledgebase,Tech Related — Suramya @ 5:59 PM

The past few weeks I have been working on the SugarCRM Silent upgrade script that upgrades the CRM from ver 4.5.1 to Version 5.0 and I hit some issues that took ages to fix. So I am sharing the fixes/solutions here for others who might have hit these issues and are looking for a solution:

1. The upgrade fails suddenly with the following error message in the upgradeWizard.log file:

Wed, 24 Sep 2008 08:28:20 -0500 [UpgradeWizard] - *** ERROR: could not copy file: /home/suramya/public_html/CRM/include/SugarFields/Fields/Address/DetailView.tpl

To fix this issue you need to extract the upgrade zip file that you downloaded and then copy the SugarFields folder from the includes directory into the include folder of your CRM. Once you do that the CRM upgrade will continue normally.

2. Upgrade fails with the following error message:

Fatal error: Call to a member function on a non-object in /home/suramya/public_html/CRM/include/dir_inc.php on line 135

This one was an interesting one to fix. I had already migrated a couple of test installs on that server so I knew the server supported the upgrade script and I was migrating the same install again so I knew that the install could be upgraded.

Finally figured out that if you rename the upgrade zip file to another name it will fail with that error message. Which is kind of silly because we give the installer the name of the upgrade zip file when running it…

Hope this helps someone else out there.

– Sur


  1. I’m fighting with the same (case 2) error while upgrading SugarCRM CE. Could you explain better how do you fix the upgrade problem with dir_inc.php on line 135.

    thanks for help


    Comment by Marco Loche — October 7, 2008 @ 10:31 PM

  2. Sure… The solution (atleast the one that worked for me) was to rename the upgrade zip file to the original file name that you got when you had downloaded the file.

    In my case it was “”. So I renamed the file from “” to “” and the upgrade worked..

    Hope this helps.

    – Suramya

    Comment by Suramya — October 7, 2008 @ 11:55 PM

  3. thanks for your help.

    Finally the problem was due to problems with rwx rights on files.
    I’ve resolved with long debugging and several chmod and chown.

    now i’m running on sugarcrm 5.1.0 🙂

    Comment by Marco Loche — October 9, 2008 @ 4:57 PM

  4. I’ve been working on upgrading SugarCRM CE to 5.1 as well and have hit the same wall: Fatal error: Call to a member function on a non-object in /home/www/broadreachhealthcare/sugar/include/dir_inc.php on line 148.

    I apologize up front that I’m pretty green around database maintenance, I’m a graphic designer, and so this is probably a really stupid question coming next. When I downloaded the Upgrade I didn’t rename it but I’m pretty sure the problem is that I’ve not located the upgrade to the Sugar file on my server. Does anybody know where the Zip file needs to be in order to be located?

    I’ve prepared all other server side setting to spec as well as the setting in the Sugar user interface.

    Thank you in advance,


    Comment by Chris — October 14, 2008 @ 12:43 AM

  5. The upgrade can be in any directory on the server as long as the user you are running the upgrade as can access that directory. In your case you can upload the zip file to the “/home/www/broadreachhealthcare/sugar” directory.

    Actually, if the silent upgrade is giving you a lot of issues then you can also use the regular upgrade process. Login as admin to the CRM, click on the admin link on the top right, then click on the “Upgrade Wizard” link and follow the on screen instructions. It is a simpler way of upgrading.

    Comment by Suramya — October 14, 2008 @ 7:02 PM

  6. could also work for vtiger ? 🙂

    Comment by sugarcrm vs vtiger — April 29, 2011 @ 11:06 PM

  7. Thanks for sharing your experience. I was having same problem and it helped me. Thanks for posting.

    Comment by SugarCRM Developers India — December 22, 2011 @ 4:41 PM

RSS feed for comments on this post. TrackBack URL

Leave a comment

Powered by WordPress