Is it possible to get replication working in a virtual user setup
that uses a static userdb ? My environment is fairly simple and typical
- there's a single system user (vmail) that owns all the home dirs
(/var/mail/domain.com/user). The virtual users
([email protected]:secretpassword) are kept in a single file
(/var/mail/domain.com/PASSWD) that's unique per domain, and referenced
as a static userdb : 

passdb {
 driver = passwd-file
 args =
scheme=plain username_format=%u /var/mail/%d/PASSWD
} 

userdb {
 driver
= static
 args = uid=vmail gid=vmail home=/var/mail/%d/%n
} 

I know the
wiki http://wiki2.dovecot.org/Replication states that user listing must
be enabled, but that's not available for a static userdb. The wiki
http://wiki2.dovecot.org/UserDatabase/Static also says that it shouldn't
be a problem because it will use do a passdb lookup instead (except for
PAM which isn't used here). 

Unfortunately, it's not working. I've
testing with ssh : 

dsync_remote_cmd = ssh -l vmail %{host} doveadm
dsync-server -u%u -l%{lock_timeout} -n%{namespace}
mail_replica =
remote:[email protected] 

as well as with straight tcp (SSL for
later) 

mail_replica = tcp:server2.domain.com:999 

/var/log/mail.err
shows the problems ... 

Jun 3 11:30:53 server1 dovecot: auth: Error:
Trying to iterate users, but userdbs don't support it
Jun 3 11:30:53
server1 dovecot: replicator: Error: User listing returned failure
Jun 3
11:30:53 server1 dovecot: replicator: Error: listing users failed, can't
replicate existing data 

Anyone else have it working ? I'm sure it's
something simple that I've just overlooked. 

Thanks - 

D. 
 

Reply via email to