I'm using Postfix/Dovecot/Roundcube on Ubuntu 20.04
Jul 3 15:30:22 fast roundcube: <en9u6fuf> [1] UPDATE mailbox SET password='7f7fc0890ac49a7e9f741f9c7e4d7e3dfc660664c98bfcac3f0a2ba6a' WHERE username ='test@example.com.au';
Jul 3 15:30:22 fast roundcube: <en9u6fuf> DB Error: [1142] UPDATE command denied to user 'postfix'@'localhost' for table 'mailbox' (SQL Query: UPDATE mailbox SET password='7f7fc0890ac49a7e9f741f9c7e4d7e3dfc660664c98bfcac3f0a2ba6a' WHERE username ='test@example.com.au') in /var/....../roundcube/program/lib/Roundcube/rcube_db.php on line 566 (POST /?_task=settings&_action=plugin.password-save)
in /var/..../plugins/password/config.inc.php:
$config['password_db_dsn'] = 'mysql://postfix:xxxxxxxx@localhost/postfix';
$config['password_query'] = 'UPDATE mailbox SET password=%P WHERE username =%u';
I tried copy/paste from the log file into the command line and the sql works correctly [see edit below!]. I've checked the postfix password.
It kinda looks like a permission problem, but I can't work out where.
[edit] I've just checked and it seems that postfix doesn't have "UPDATE" privilege on mysql. When I tried the mysql command I was logged into mysql as root, so of course it worked.
Grants for postfix@localhost |
+------------------------------------------------------+
| GRANT USAGE ON *.* TO `postfix`@`localhost` |
| GRANT SELECT ON `postfix`.* TO `postfix`@`localhost`|
+------------------------------------------------------+
2 rows in set (0.00 sec)
Before I rush in and screw something up, is this the problem? Given that I have a pretty standard install, is this in the documentation anywhere?
Also, there is this line in the password config:
$config['password_dovecot_passwdfile_path'] = '/etc/mail/imap.passwd';
but I have no idea what it is for. This path/file doesn't exist on my system.