Symptoms
After the RoundCube cPanel package is update to 1.7, you find that one of the following is occurring:
- Webmail stops working for mailboxes after the Roundcube 1.7 update. Opening webmail ends with
ERR_TOO_MANY_REDIRECTSin the browser. - The Roundcube error log
/home/USER/logs/roundcube/errors.logshows:
CONFIG_TEXT: DB Error: [1] table session has no column named expires_at
The /usr/local/cpanel/logs/error_log file shows the following after running /usr/local/cpanel/bin/update-roundcube-sqlite-db:
CONFIG_TEXT: warn [update-roundcube-sqlite-db] Schema update failed for /usr/local/cpanel/base/3rdparty/roundcube/SQL/sqlite.initial.sql: DBD::SQLite::db do failed: table users already exists at /usr/local/cpanel/Cpanel/Email/RoundCube/DBI.pm line 180.
In the affected mailbox database, the system table has no roundcube-version row, and the session table still has the old changed column instead of expires_at.
Cause
Resolution
As a workaround, fix the session table of each affected mailbox database manually:
- Log in to the server via SSH or WHM's Terminal as the
rootuser Set the path of the affected database and create a backup of it:
# DB=/home/USER/etc/DOMAIN/MAILBOX.rcube.db
# sqlite3 "$DB" ".backup '$DB.bak'"Rename the column and create the new index as the account user:
# runuser -u USER -- sqlite3 "$DB" "ALTER TABLE session RENAME COLUMN changed TO expires_at; CREATE INDEX ix_session_expires_at ON session(expires_at);"
Verify that the
sessiontable now has theexpires_atcolumn, then open webmail for the mailbox:# sqlite3 -readonly "$DB" ".schema session"
Warning: We reccomend that you do not rename or remove the .rcube.db file to let Roundcube create a new one. This will cause the mailbox loses its stored contacts and settings.
Note: this temporary workaround fixes only the session table. The roundcube-version row stays missing, so update-roundcube-sqlite-db still fails on this database, and other skipped migrations cannot be ruled out. The roundcube-version will be addressed when CPANEL-59121 is resolved.
Comments
0 comments
Please sign in to leave a comment.