Database Failure - Same error for pretty much most things :(

Hey Guys,

So I have been having a really tough time getting this to work. Ever since I moved this to AWS, its been painstakingly annoying to work with. I can’t repair, can’t upgrade, can’t make a third party plugin to work at all… For anything and everything I get the error Database failure. Please refer to suitecrm.log for details.

And the suitecrm.log is as under. I have tried everything I could find online. And now im at my wit’s end. If anyone could please help me through this misery, I would be more than helpful. Quite honestly I don’t mind buying you a drink as a thank you gesture. I am that desperate.

Thu Jul 30 10:45:02 2020 [1906][1][FATAL] SugarBean::populateDefaultValues $field_defs should be an array
Thu Jul 30 10:45:04 2020 [1906][1][FATAL] SugarBean::populateDefaultValues $field_defs should be an array
Thu Jul 30 10:45:05 2020 [1906][1][FATAL] Mysqli_query failed.
Thu Jul 30 10:45:05 2020 [1906][1][FATAL] Query Failed: ALTER TABLE users_feeds modify COLUMN rank int(11) NULL : MySQL error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘rank int(11) NULL’ at line 1
Thu Jul 30 10:45:05 2020 [1906][1][FATAL] Exception handling in /var/www/cms/include/MVC/Controller/SugarController.php:400
Thu Jul 30 10:45:05 2020 [1906][1][FATAL] Exception in Controller: Database failure. Please refer to suitecrm.log for details.
Thu Jul 30 10:45:05 2020 [1906][1][FATAL] backtrace:
#0 /var/www/cms/include/database/DBManager.php(353): sugar_die()
#1 /var/www/cms/include/database/DBManager.php(328): DBManager->registerError()
#2 /var/www/cms/include/database/MysqliManager.php(179): DBManager->checkError()
#3 /var/www/cms/include/database/MysqlManager.php(625): MysqliManager->query()
#4 /var/www/cms/modules/Administration/repairDatabase.php(152): MysqlManager->repairTableParams()
#5 /var/www/cms/modules/Administration/QuickRepairAndRebuild.php(139): include_once(’/var/www/cms/mo…’)
#6 /var/www/cms/modules/Administration/QuickRepairAndRebuild.php(121): RepairAndClear->repairDatabase()
#7 /var/www/cms/custom/outright_utils/core/common/outright_installation_utils.php(18): RepairAndClear->repairAndClearAll()
#8 /var/www/cms/custom/modules/outr_outr_licence/list_view_hook.php(39): outright_do_repair()
#9 /var/www/cms/include/utils/LogicHook.php(272): add_list_view_button->outright_finish_license()
#10 /var/www/cms/include/utils/LogicHook.php(208): LogicHook->process_hooks()
#11 /var/www/cms/data/SugarBean.php(3112): LogicHook->call_custom_logic()
#12 /var/www/cms/data/SugarBean.php(2376): SugarBean->call_custom_logic()
#13 /var/www/cms/custom/outright_utils/core/security/outright_security_utils.php(54): SugarBean->save()
#14 /var/www/cms/custom/outright_utils/core/security/outright_security_utils.php(21): outright_security->do_validate()
#15 /var/www/cms/modules/outr_pdf_template_settings/views/view.list.php(41): outright_security->__construct()
#16 /var/www/cms/include/MVC/View/SugarView.php(226): outr_pdf_template_settingsViewList->display()
#17 /var/www/cms/include/MVC/Controller/SugarController.php(435): SugarView->process()
#18 /var/www/cms/include/MVC/Controller/SugarController.php(375): SugarController->processView()
#19 /var/www/cms/include/MVC/SugarApplication.php(113): SugarController->execute()
#20 /var/www/cms/index.php(52): SugarApplication->execute()
#21 {main}
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: Connectors
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: Connectors
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: Versions
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: Versions
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: CustomFields
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: CustomFields
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: Connectors
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: Connectors
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: Versions
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: Versions
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: CustomFields
Thu Jul 30 10:45:05 2020 [2230][1][FATAL] Cannot find bean file for module: CustomFields

Can you specify version of SuiteCRM, Mysql and php etc… ?
The error seems an incompatible version of MySQL may be.

Hi Sagar,

Appreciate your prompt support… Here are the details you requested for -

SuiteCRM - 7.11.15
PHP - 7.4.3
MySQL - 8.0.21-0ubuntu0.20.04.3

its running on Ubuntu 20.04.1 LTS on an EC2 Box.

I confirm it is an issue with rank field and MySQL compatibility.
Here is the compatibility matrix.

The above rank field issue is registered case and it has workaround to but not merged yet.

Here is the suggested workaround file that you need to change.

2 Likes

Oh man… so what do you suggest??
Do I keep a backup of these files & DB and start all over again? Like install the compatible version of PHP, MySQL and start over again?

I would suggest, try with given patch and do check if you have any other issue.

Thank you Sagar, I will try these patches then.

Hi Sagar,

So finally, I just downgraded it to MySQL 5.7.31 and that fixed the problem :smiley:

1 Like