Author Topic: DB Error: [1146] Table 'roundcube.contacts' doesn't exist  (Read 1583 times)

Offline ClintonLee83

  • Newbie
  • *
  • Posts: 5
CentOS 7, Roundcube 1.6.1

I'm using vestacp with roundcube, upgraded exim today. Tried sending out mail for the first time from roundcube and I'm getting an error:

smtp error (451): failed to add recipient "recipient@mail.com" (temporary local problem - please try later.)

errors.log:

DB Error: [1146] Table 'roundcube.contacts' doesn't exist (SQL Query: SELECT * FROM `contacts` AS c WHERE c.`del` <> 1 AND c.`user_id` = '3' AND ((`name` LIKE $
[26-Jun-2023 09:19:07 +0000]: <13kp61b7> DB Error: [1146] Table 'roundcube.contactgroups' doesn't exist (SQL Query: SELECT * FROM `contactgroups` WHERE `del` <> 1 AND `user_id` = '3' AND `name` LIKE '$
[26-Jun-2023 09:19:07 +0000]: <13kp61b7> DB Error: [1146] Table 'roundcube.collected_addresses' doesn't exist (SQL Query: SELECT * FROM `collected_addresses` WHERE `user_id` = '3' AND `type` = '1' AND$
[26-Jun-2023 09:19:07 +0000]: <13kp61b7> DB Error: [1146] Table 'roundcube.collected_addresses' doesn't exist (SQL Query: SELECT * FROM `collected_addresses` WHERE `user_id` = '3' AND `type` = '2' AND$
[26-Jun-2023 09:19:12 +0000]: <13kp61b7> PHP Error: Invalid response code received from server (POST /webmail/?_task=mail&_unlock=loading1687771151974&_framed=1&_lang=en_US&_action=send)
[26-Jun-2023 09:19:12 +0000]: <13kp61b7> SMTP Error: Failed to send data. [451] Temporary local problem - please try later in /usr/share/roundcubemail/program/lib/Roundcube/rcube.php on line 1794 (POS$

There seems to be an issue with the database. Any ideas about how to solve this?

Thank you!

Offline ClintonLee83

  • Newbie
  • *
  • Posts: 5
Re: DB Error: [1146] Table 'roundcube.contacts' doesn't exist
« Reply #1 on: June 27, 2023, 03:54:06 AM »
Solved:

I'm using vestacp, I tried re-installing vesta and an error appeared:
ERROR 1071 (42000) at line 51: Specified key was too long; max key length is 767 bytes

This is a db error which I assumed was related to roundcube. So after verifying the roundcube db was incomplete, I deleted the roundcube db and re-created an empty roundcube db, then tried to re-install from initial roundcube sql:
mysql roundcube < /usr/share/roundcubemail/SQL/mysql.initial.sql

ERROR: 1071 (42000) at line 51: Specified key was too long; max key length is 767 bytes

I added: innodb_large_prefix = 1;

Still didn't work.

Mariadb version 5.5.6 has issues with max key length. So I could either try and fix this or install a newer version of mariadb.

Upgraded to mariadb 10.4 -
mysql roundcube < /usr/share/roundcubemail/SQL/mysql.initial.sql

That worked! In addition, mysql performs better.

I still have an smtp problem which I'll start a new thread.