Silent upgrade with robo not work

Hello, everyone,
I’ve been trying to do the silent upgrade from the command line for some time now, but it doesn’t work. I followed what I wrote in the official documentation https://docs.suitecrm.com/admin/installation-guide/upgrading/ .
I load the upgrade package in the root directory of my SuiteCRM installation, then I run the command:

./vendor/bin/robo upgrade:suite SuiteCRM-Upgrade-7.11.x-to-7.11.10.zip upgradeLog.log upgrade . admin

This produces the following error

./vendor/bin/robo: line 1: ../consolidation/robo/robo: No such file or directory
You have mail in /var/spool/mail/root

:frowning:

Unfortunately the wizard upgrade doesn’t work for me because I have tables with more than 10000 records.

Any solutions?

Thanks

1 Like

After performing the following commands:

yum update
composer require consolidation/Robo:~1

I was able to launch the silent upgrade command via robo:

./vendor/bin/robo upgrade:suite SuiteCRM-Upgrade-7.11.x-to-7.11.10.zip upgradeLog.log . admin
PHP Fatal error:  Uncaught Error: Class 'Zend_Search_Lucene_Search_QueryParser' not found in /var/www/sites/x-crm-dev/modules/AOD_Index/AOD_Index.php:52
Stack trace:
#0 /var/www/sites/x-crm-dev/data/BeanFactory.php(116): AOD_Index->__construct()
#1 /var/www/sites/x-crm-dev/modules/AOD_Index/AOD_LogicHooks.php(36): BeanFactory::getBean('AOD_Index')
#2 /var/www/sites/x-crm-dev/include/utils/LogicHook.php(272): AOD_LogicHooks->saveModuleChanges(Object(UpgradeHistory), 'after_save', '')
#3 /var/www/sites/x-crm-dev/include/utils/LogicHook.php(213): LogicHook->process_hooks(Array, 'after_save', '')
#4 /var/www/sites/x-crm-dev/data/SugarBean.php(3129): LogicHook->call_custom_logic('Administration', 'after_save', '')
#5 /var/www/sites/x-crm-dev/data/SugarBean.php(2442): SugarBean->call_custom_logic('after_save', '')
#6 /var/www/sites/x-crm-dev/modules/UpgradeWizard/silentUpgrade_step1.php(851): SugarBean->save()
#7 {main}
  thrown in /var/www/sites/x-crm-dev/modules/AOD_Index/AOD_Index.php on line 52
***************         step1 failed         ***************: 255
***************         silentupgrade failed         ***************: 255
 [Exec]  Exit code 255  Time 01:27
➜  Upgrade Complete!

Any solutions on how to solve?

Thanks

After the SuiteCRM update no more loads any CSS and if I open the browser console I find the following errors:

ReferenceError: SUGAR is not defined
x-crm-dev.it:10:9
ReferenceError: $ is not defined
x-crm-dev.it:82:13
ReferenceError: YAHOO is not defined
sugar_grp_yui_widgets.js:2:1
ReferenceError: SUGAR is not defined
dashlets.js:39:1
ReferenceError: $ is not defined
retrievePage.js:141:1
ReferenceError: YAHOO is not defined
? I can't get no ?
ReferenceError: $ is not defined
x-crm-dev.it:454:2
ReferenceError: $ is not defined
x-crm-dev.it:454:2
ReferenceError: alertsTimeoutId is not defined
x-crm-dev.it:454:44
ReferenceError: SUGAR_callsInProgress is not defined
x-crm-dev.it:534:9
ReferenceError: closeMenus is not defined

Going to /index.php?module=Home&action=About the version is correctly updated to 7.11.10

I did all the repair and rebuild operations and deleted the /cache folder but no effect.

The permissions of the folders are correct as I launched the command

sudo chown -R apache:apache .
  sudo chmod -R 755 .
  sudo chmod -R 775 cache custom modules themes data upload
  sudo chmod 775 config_override.php 2>/dev/null

I tried to load on it the new version 7.11.10, deleted the cache folder and regenerated .htaccess… but no results.

ReferenceError: SUGAR is not defined
x-crm-dev.it:10:9
ReferenceError: $ is not defined
x-crm-dev.it:82:13
ReferenceError: YAHOO is not defined
sugar_grp_yui_widgets.js:2:1
ReferenceError: SUGAR is not defined
dashlets.js:39:1
ReferenceError: $ is not defined
retrievePage.js:141:1
ReferenceError: YAHOO is not defined
x-crm-dev.it:403:25
ReferenceError: $ is not defined
x-crm-dev.it:454:2
ReferenceError: $ is not defined
x-crm-dev.it:454:2
ReferenceError: alertsTimeoutId is not defined
x-crm-dev.it:454:44
ReferenceError: SUGAR_callsInProgress is not defined

:frowning:

I don’t think it’s a permissions problem because taken by the frustration I set the permissions of the folders to 777 and nothing changes

Deleting the cache directory might actually be the source of some of your problems…

https://academe.co.uk/2012/06/sugarcrm-cache-directory-it-is-not-a-cache-directory/

The situation now is not as bad as when that article was written, but much of it still applies. It is definitely not recommended to clear cache directory completely.

If you can try some of the repairs again, without deleting cache, that would be nice.

Can you login and use the screens?

Do you have any PHP errors now in any of your logs?

Hello PGR,
Thank you for answering.
Thanks for the advice not to delete completely the directory /cache, this action unfortunately I had already done more than once .
I tried to do any kind of ‘repair’ but it did not work, I could still log in but the css and Js files are not loaded. In Suite CRM logs I don’t get anything, the same for Apache logs.

I stepped back and did two tests.
TEST 1 -> I have restored the status of my system to version 7.11.5, from a backup. Then I made again the ‘silent-upgrade’ to version 7.11.10, getting the error that I attach to the post.

TEST2 -> I installed a clean version of SuiteCRM 7.10.5 and made the ‘silent-upgrade’. Also in this case I get the same error that you can find in the attachment. The difference is that the installation seems to work and it seems updated to 7.11.10… What seems strange is that even if a FATAL ERROR appears the installation process ends with ‘Upgrade Complete!’.

Can this error be the cause of the malfunction ?

Are you running the scheduler jobs during the upgrade?

If you are, try turning them off temporarily and running the upgrade.

Hello PGR,
I tried to upgrade version 7.11.5 of my system with all the scehedulers disabled and I get the same command line error and the same visual problem… in the sense that I lose stylization and the firefox console always signals me the following errors:


ReferenceError: SUGAR is not defined
index.php:10:9
ReferenceError: $ is not defined
index.php:82:13
ReferenceError: YAHOO is not defined
sugar_grp_yui_widgets.js:2:1
ReferenceError: SUGAR is not defined
dashlets.js:39:1
ReferenceError: $ is not defined
retrievePage.js:141:1
ReferenceError: YAHOO is not defined
index.php:403:25
ReferenceError: $ is not defined
index.php:454:2
ReferenceError: $ is not defined
index.php:454:2
ReferenceError: alertsTimeoutId is not defined
index.php:454:44
ReferenceError: SUGAR_callsInProgress is not defined
index.php:534:9
ReferenceError: closeMenus is not defined

Maybe it’s permissions.

I know you wrote above you tried with 777 permissions, but there is still a case that might not be working. It’s new file creation (soething quite relevant in rebuilding deleted caches).

This depends on two more things you might want to check:

  • default_permissions entry in config.php

  • the sticky bits in directories which control the permissions granted to new files. SetGID and SetOID.

Hi PGR,
the parameters ‘default_permissions’ in the config.php file are:

'default_permissions' => 
  array (
    'dir_mode' => 1528,
    'file_mode' => 493,
    'user' => '',
    'group' => '',
  )

I don’t understand what the values are.

how can i control sticky bits? I made you a screenshot of the command ‘ls -l’ if it can be useful

You should fill that with the correct “user” and “group”.

For the values if you use a prefix of “0”, you can enter the familiar octal values like this “0775”. Those numbers are just the octals converted by PHP into decimal.

http://decimal-to-binary.com/decimal-to-binary-converter-online.html?id=41976

As you can see there, that 1528 is really “02770”.

By the way, that “2” is what you should use, for folders, to get the bits right.

So you can try re-running the chmods to include that for folders, with something like this:


find /path/to/base/dir -type d -exec chmod 2775 {} +

Hello PGR,
I tried to check on what you suggested, but nothing…
I wondered if I had modified a .tpl file of the theme to include the company logo in the login screen. The problem was the files in the

/custom/themes/SuiteP/tpls/

folder that probably changed in the new update. Deleted all files except login.tpl everything works great!!!
I am very happy

Thank you.

Hello web_elinet

I am facing same issue please let me know if you find any solution

Thanks in advance
chinmay

Hello dev.chnmay,
my problem was related to a modification of a .tpl file as you can read in the previous post.
I do not know if the solution found can help you