Roundcube Login Failed for New Accounts

vahid07

Verified User
Joined
Apr 16, 2018
Messages
22
Hi

i can login to roundcube with my one email account without any problem. but about another accounts i cant login to them! also i created a new email account without problem but i cant login to it too!

i see these lines in roundcure error log :

Code:
[16-Feb-2019 15:56:29 +0000]: <37nnpg12> DB Error: [1364] Field 'alias' doesn't have a default value (SQL Query: INSERT INTO `users` (`created`, `last_login`, `username`, `mail_host`, `language`) VALUES (now(), now(), '[email protected]', 'localhost', 'fa_IR')) in /var/www/html/roundcubemail-1.3.8/program/lib/Roundcube/rcube_db.php on line 543 (POST /roundcube/?_task=login&_action=login)
[16-Feb-2019 15:56:29 +0000]: <37nnpg12> PHP Error: Failed to create new user in /var/www/html/roundcubemail-1.3.8/program/lib/Roundcube/rcube_user.php on line 688 (POST /roundcube/?_task=login&_action=login)
[16-Feb-2019 15:56:29 +0000]: <37nnpg12> PHP Error: Failed to create a user record. Maybe aborted by a plugin? in /var/www/html/roundcubemail-1.3.8/program/include/rcmail.php on line 652 (POST /roundcube/?_task=login&_action=login)

whats the problem?
 
I encountered the same issue awhile back after creating a new domain under DA and trying to login to its webmail.

Code:
[16-Feb-2019 22:58:04 +0100]: <2733299c> DB Error: [1364] Field 'alias' doesn't have a default value (SQL Query: INSERT INTO `users` (`created`, `last_login`, `username`, `mail_host`, `language`) VALUES (now(), now(), '[email protected]', 'localhost', 'en_US')) in /var/www/html/roundcubemail-1.3.8/program/lib/Roundcube/rcube_db.php on line 543 (POST /webmail/?_task=login&_action=login)
[16-Feb-2019 22:58:04 +0100]: <2733299c> PHP Error: Failed to create new user in /var/www/html/roundcubemail-1.3.8/program/lib/Roundcube/rcube_user.php on line 688 (POST /webmail/?_task=login&_action=login)
[16-Feb-2019 22:58:04 +0100]: <2733299c> PHP Error: Failed to create a user record. Maybe aborted by a plugin? in /var/www/html/roundcubemail-1.3.8/program/include/rcmail.php on line 652 (POST /webmail/?_task=login&_action=login)
 
I found the same on a Plesk forum.
They said as cause:
Roundcube default database structure was modified due to a plugin installation, and it was not completely uninstalled.

And give the same option to repair as was given to BBM in his thread:
1. Make a backup of the database.
2. Check if there is any data in the alias folder.
3. If not, it is safe to assume that it is not used. Drop the column or make it nullable.
4. Presto!

Plesk even advised to remove the column with a database command somewhat like this:
Code:
db "ALTER TABLE roundcubemail.users DROP COLUMN roundcubemail.users.alias"

So it seems you have to check your plugins. Maybe it's sieve? I don't know.

But this error seems to happen regularly in general.
 
I found the same on a Plesk forum.
They said as cause:


And give the same option to repair as was given to BBM in his thread:
1. Make a backup of the database.
2. Check if there is any data in the alias folder.
3. If not, it is safe to assume that it is not used. Drop the column or make it nullable.
4. Presto!

Plesk even advised to remove the column with a database command somewhat like this:
Code:
db "ALTER TABLE roundcubemail.users DROP COLUMN roundcubemail.users.alias"

So it seems you have to check your plugins. Maybe it's sieve? I don't know.

But this error seems to happen regularly in general.

Thank you, do you try it?

i think there is must a dedicated solution for directadmin users:(
 
Last edited:
Thank you, do you try it?
No I did not since I never encountered the issues you're having. However as you can see it fixed things for BBM.

i think there is must a dedicated solution for directadmin users
I don't think so, because this error is happening also on other platforms. Seems to me a plugin issue should be fixed by the plugin programmer. Unless that is DA ofcourse in this case. :)
 
I had the same problem today, I made the column alias nullable and now it works. I hope it is the right solution and that I will not create any new problems in the future.

Thanks
 
1. Make a backup of the database.
2. Check if there is any data in the alias folder.
3. If not, it is safe to assume that it is not used. Drop the column or make it nullable.
4. Presto!

Plesk even advised to remove the column with a database command somewhat like this:
Code:
db "ALTER TABLE roundcubemail.users DROP COLUMN roundcubemail.users.alias"

Hi again

Maybe please guide me step by step to do this? im not familier with sql command through SSH
 
Looking at both the installer .sql commands, and their update commands the user.alias field was dropped in 2012:
Code:
2012080700.sql:ALTER TABLE `users` DROP COLUMN `alias`;
meaning, at some point in the past, an update failed to run correctly.

You could do a one-call way of dropping it, as root in ssh:
Code:
mysql --defaults-extra-file=/usr/local/directadmin/conf/my.cnf -e 'ALTER TABLE da_roundcube.users DROP COLUMN alias;' --host=localhost
John
 
Still not working

Looking at both the installer .sql commands, and their update commands the user.alias field was dropped in 2012:
Code:
2012080700.sql:ALTER TABLE `users` DROP COLUMN `alias`;
meaning, at some point in the past, an update failed to run correctly.

You could do a one-call way of dropping it, as root in ssh:
Code:
mysql --defaults-extra-file=/usr/local/directadmin/conf/my.cnf -e 'ALTER TABLE da_roundcube.users DROP COLUMN alias;' --host=localhost
John

Hi John,

It seems this was fixed for the newest version as I got "ERROR 1091 (42000) at line 1: Can't DROP COLUMN `alias`; check that it exists"

However, I'm still having the same problem as described in the topic. I made a new account to my friend, but the given username cannot login to Roundcube ([email protected]). The CMD change email password URL doesn't work either.

I tried replicating the problem and I got the same result. However, if the user creates a new email address, that works just fine.

Any ideas? Is there a way to stop DA making default inboxes as they're inaccessible. These inboxes cannot be deleted either?
 
Hi John,

It seems this was fixed for the newest version as I got "ERROR 1091 (42000) at line 1: Can't DROP COLUMN `alias`; check that it exists"

However, I'm still having the same problem as described in the topic. I made a new account to my friend, but the given username cannot login to Roundcube ([email protected]). The CMD change email password URL doesn't work either.

I tried replicating the problem and I got the same result. However, if the user creates a new email address, that works just fine.

Any ideas? Is there a way to stop DA making default inboxes as they're inaccessible. These inboxes cannot be deleted either?

If I understand you correctly, you are trying to login to a default system email account in Roundcube by using this user name format: [email protected]

If that is what you are trying to do, then this will not work. The default system email account user name is only "username", only extra email accounts you create has the full email address as username.

So please try to login to Roundcube webmail by using the same username and password as the DirectAdmin account username and password, then it should work.
 
Back
Top