[Dovecot] Files Moving From /New to /Cur

2010-01-18 Thread Tony Rutherford
Using Dovecot 1.2-9 with Maildir and layout=FS.

 

We have our own delivery pushing messages to the /new and then /cur folder
eventually.  When I have an IMAP client attached, there is apparently some
sort of race going on.  I believe that Dovecot is moving files from /new to
/cur (and renaming them) before our own delivery gets the job done. 

 

This is causing a problem for us.  Is there a way to disable this in
Dovecot?  I have the LDA section commented out of the config file..so I
don't think that's in play.   Bottom line is that I don't want Dovecot to
move any files around whether an IMAP client is attached or not (except for
handling the IMAP COPY/APPEND).

 

Regards,

Tony

 



Re: [Dovecot] No filelocking at "shared-mailboxes" dictionary?

2010-01-18 Thread Timo Sirainen
On 19.1.2010, at 1.21, Peer Heinlein wrote:

> I started with an empty file "shared-mailboxes". But after the sync the 
> file "shared-mailboxes" has been crashed. I found broken lines and I'm 
> missing some entrys. 
> 
> Is it possible  that there's no filelocking on that file?

The file is always created by creating a temporary file, locking the file by 
link()ing it to a dotlock file, reading existing data, applying changes, and 
writing the data to it and then rename()ing it over the original file. There 
isn't really any way to corrupt data inside the file, because the whole file is 
always recreated.

> hared/shared-boxes/user/user6.example.com/user4.example.c2442203233424^?
> 1
> ser/user7.example.com/user2.example.com

If it's a Dovecot bug, it's more likely a memory corruption problem. I don't 
see any obvious reasons though. Can you easily reproduce this? Running via 
valgrind could be interesting then.



[Dovecot] No filelocking at "shared-mailboxes" dictionary?

2010-01-18 Thread Peer Heinlein

Using imapsync I changed many ACLs on many accounts simultaneously in 
four concurrent IMAP-sessions.

I started with an empty file "shared-mailboxes". But after the sync the 
file "shared-mailboxes" has been crashed. I found broken lines and I'm 
missing some entrys. 

Is it possible  that there's no filelocking on that file?

I used the ext3 filesystem.


That's what shred-mailboxes looks like at the moment:

shared/shared-box
1
shared/shared-boxes/user/user1.example.com/user2.example.com
1
.example.com/user5.example.com
1
hared/shared-boxes/user/user6.example.com/user4.example.c2442203233424^?
1
ser/user7.example.com/user2.example.com


Peer


dovecot -n:
# 1.2.9: /etc/dovecot/dovecot.conf
# OS: Linux 2.6.27.39-0.2-default x86_64 openSUSE 11.1 (x86_64) 
protocols: imap imaps managesieve   
ssl_cert_file: /etc/ssl/old.pem 
ssl_key_file: /etc/ssl/old.pem  
shutdown_clients: no
login_dir: /var/run/dovecot/login   
login_executable(default): /usr/lib/dovecot/imap-login  
login_executable(imap): /usr/lib/dovecot/imap-login 
login_executable(managesieve): /usr/lib/dovecot/managesieve-login
login_process_per_connection: no 
login_max_processes_count: 512   
max_mail_processes: 1024 
mail_max_userip_connections(default): 40 
mail_max_userip_connections(imap): 40
mail_max_userip_connections(managesieve): 10 
verbose_proctitle: yes   
mail_uid: vmail  
mail_gid: vmail  
mail_location: maildir:~/Maildir 
mail_executable(default): /usr/lib/dovecot/imap-usernamenmigration
mail_executable(imap): /usr/lib/dovecot/imap-usernamenmigration   
mail_executable(managesieve): /usr/lib/dovecot/managesieve
mail_plugins(default): quota imap_quota acl imap_acl  
mail_plugins(imap): quota imap_quota acl imap_acl 
mail_plugins(managesieve):
mail_plugin_dir(default): /usr/lib64/dovecot/modules/imap 
mail_plugin_dir(imap): /usr/lib64/dovecot/modules/imap
mail_plugin_dir(managesieve): /usr/lib64/dovecot/modules/managesieve
namespace:  
  type: private 
  separator: /  
  inbox: yes
  list: yes 
  subscriptions: yes
namespace:  
  type: shared  
  separator: /  
  prefix: zz_SHARED_ACCOUNTS/%%u/
  location: maildir:%%h/Maildir:INDEX=~/Maildir/shared/%%u
  list: yes
lda:
  postmaster_address: postmas...@iea-dpc.org
  mail_plugins: quota acl sieve
  mail_plugin_dir: /usr/lib64/dovecot/modules/lda
  quota_full_tempfail: yes
auth default:
  mechanisms: plain login digest-md5 cram-md5
  verbose: yes
  debug: yes
  debug_passwords: yes
  passdb:
driver: passwd-file
args: /etc/dovecot/userdb
  userdb:
driver: passwd-file
args: /etc/dovecot/userdb
  userdb:
driver: static
args: uid=5001 gid=5001
  socket:
type: listen
client:
  path: /var/spool/postfix/private/auth
  mode: 432
  user: postfix
  group: postfix
master:
  path: /var/run/dovecot/auth-master
  mode: 432
  user: vmail
  group: vmail
plugin:
  quota: maildir
  quota_rule: *:storage=102400
  acl: vfile
  acl_shared_dict: file:/var/lib/dovecot/shared-mailboxes
  sieve: ~/.dovecot.sieve
  sieve_dir: ~/sieve


-- 
Heinlein Professional Linux Support GmbH
Linux: Akademie - Support - Hosting

http://www.heinlein-support.de
Tel: 030 / 40 50 51 - 0
Fax: 030 / 40 50 51 - 19

Zwangsangaben lt. §35a GmbHG:
HRB 93818 B / Amtsgericht Berlin-Charlottenburg,
Geschäftsführer: Peer Heinlein  -- Sitz: Berlin


Re: [Dovecot] Fail to handle . and - in mailaddresses

2010-01-18 Thread Mika
> On 14.1.2010, at 11.13, Mika wrote:
>
>>> From Deliver logfile:
>> deliver(...---...@domain.com): Jan 14 08:18:24 Info:
>> msgid=<798c378b1001132318y4a027757m37a668f48730...@mail.gmail.com>:
>> saved
>> mail to INBOX
>>
>> # Does not seem to end up in any of the files in Maildir, new/tmp
>> folders
>> are empty.
>
> Well, it went somewhere. Set mail_debug=yes to see where.
>
>

After a bit of digging i found that the mail ended up in
/opt/vmail/%d/...---... instead of /opt/vmail/%d/user. I will poke around
with mail_debug and see what I can dig up.

 postmap -q ...---...@domain.com mysql:/etc/postfix/mysql-alias-maps.cf

Expands the correct alias.

//Mika



Re: [Dovecot] sieve: discarding vacation response

2010-01-18 Thread wenjie zheng
On Fri, Jan 15, 2010 at 6:27 PM, Stephan Bosch  wrote:
> wenjie zheng wrote:
> [...]
>
>> rcpt to:
>> 250 2.1.5 OK
>> DATA
>> 354 OK
>> From: 
>> To: foo
>> Subject: hello
>>
>> Hello there
>>
> The vacation action requires that the mail explicitly lists the recipient in
> the To/Cc/etc headers of the message. Your test message does not contain the
> user's address in the To: header.
>

Thank you again.

Wenjie


Re: [Dovecot] Upgrade path questions

2010-01-18 Thread Josep L. Guallar-Esteve
On Wednesday 13 January 2010 03:14:42 pm Thomas M Goerger wrote:
> Hi,
> 
> We are currently running Dovecot v1.1.6 on our servers, and are
> contemplating an upgrade to 1.2, or 2.0 soon.  We are wondering how many
> organizations are still running a 1.1 version of Dovecot, and if anyone
> has any thoughts on this transition.  Have you upgraded from 1.1 to 1.2?
> What are your experiences with this?  Have you upgraded from 1.1 to 2.0
> directly?  What are your experiences this way?  We are also running an
> environment with both mbox and maildir formats.  How many of you are
> running similarly, or are running solely maildir or mbox?  We're just
> looking to gather information going forward, and anything you might be
> able to contribute would be very helpful.
> 
> Thanks!
> 
> * Tom Goerger  -  Email/Unix System Administrator *
> * University of MinnesotaEmail:  t...@umn.edu *

Hi Tom,

We are running 1.1.x (http://atrpms.net/dist/el4/dovecot-1.1.x/), after a 
recent upgrade from 0.99 on a CentOS 4 system. The upgrade went flawlessly 
after reading the wiki, asking a couple of questions here and testing first 
with a test system.

Then I looked at 1.2. I saw there was some possible issues with our set up, so 
I went with the good old and tried 1.1.x instead.

So far 1.1.x is has performed beautiful, so if it is not broken, no reason to 
fix it.

Down the line, I'll plan to upgrade to 1.2.x , after 2.0.x is fully stable. Of 
course I'll need some time, no current projects in /dev/TODO and a good reason 
to change something that works just fine :-)

Regards,
Josep
-- 
Josep L. Guallar-Esteve - IT Department - Eastern Radiologists, Inc.



This transmission is intended for the use of the entity or individual to which
or whom it is addressed.  The transmission or any documents accompanying the
transmission may contain confidential information.  If you are not the intended
recipient, you are hereby notified that any disclosure, copying, distribution,
or action taken in reliance on the contents of the transmission or the
documents is strictly prohibited. If you have received this confidential
transmission in error, please destroy it and any accompanying documents and
notify the sender immediately.  Thank you.


Re: [Dovecot] Inotify instance limit for user exceeded

2010-01-18 Thread mail...@securitylabs.it

On 18/01/2010 14:49, Lampa wrote:

Hello,

i saw in my log followed messages:

dovecot: 2010-01-18 13:20:54 Warning: IMAP(us...@domain1.com): Inotify
instance limit for user exceeded, disabling.
dovecot: 2010-01-18 13:21:01 Warning: IMAP(us...@domain2.com): Inotify
instance limit for user exceeded, disabling.
dovecot: 2010-01-18 13:21:23 Warning: IMAP(us...@domain2.com: Inotify
instance limit for user exceeded, disabling.
   


Hello, I've solved a similar trouble with:

fs.inotify.max_user_instances = 256

in /etc/sysctl.conf

The default is 128.



[Dovecot] Inotify instance limit for user exceeded

2010-01-18 Thread Lampa
Hello,

i saw in my log followed messages:

dovecot: 2010-01-18 13:20:54 Warning: IMAP(us...@domain1.com): Inotify
instance limit for user exceeded, disabling.
dovecot: 2010-01-18 13:21:01 Warning: IMAP(us...@domain2.com): Inotify
instance limit for user exceeded, disabling.
dovecot: 2010-01-18 13:21:23 Warning: IMAP(us...@domain2.com: Inotify
instance limit for user exceeded, disabling.

dovecot -c dovecot-domain1.com.conf -n:
# 1.0.10: dovecot-domain1.com.conf

remax-czech.cz
base_dir: /var/run/domain1.com
log_path: /var/log/dovecot/domain1.com/dovecot.log
info_log_path: /var/log/dovecot/domain1.com/info.log
log_timestamp: %F %T
protocols: imap imaps pop3 pop3s
listen: 127.0.0.1
ssl_cert_file: /usr/local/ssl/mail/domain1.comserver.crt
ssl_key_file: /usr/local/ssl/mail/domain1.com/server.key
disable_plaintext_auth: no
verbose_ssl: yes
login_dir: /var/run/dovecot-domain1.com/login
login_executable(default): /usr/local/dovecot/bin/dovecot/imap-login
login_executable(imap): /usr/local/dovecot/bin/dovecot/imap-login
login_executable(pop3): /usr/local/dovecot/bin/dovecot/pop3-login
login_max_processes_count: 40
login_max_connections: 42
max_mail_processes: 2000
verbose_proctitle: yes
first_valid_uid: 507
last_valid_uid: 507
first_valid_gid: 502
last_valid_gid: 502
fsync_disable: yes
mail_executable(default): /usr/local/dovecot/bin/dovecot/imap
mail_executable(imap): /usr/local/dovecot/bin/dovecot/imap
mail_executable(pop3): /usr/local/dovecot/bin/dovecot/pop3
mail_process_size: 300
mail_plugin_dir(default): /usr/local/dovecot-1.0.10/lib/dovecot/imap
mail_plugin_dir(imap): /usr/local/dovecot-1.0.10/lib/dovecot/imap
mail_plugin_dir(pop3): /usr/local/dovecot-1.0.10/lib/dovecot/pop3
pop3_uidl_format(default):
pop3_uidl_format(imap):
pop3_uidl_format(pop3): %08Xu%08Xv
auth default:
  mechanisms: plain login
  user: vmail
  verbose: yes
  passdb:
driver: vpopmail
  userdb:
driver: vpopmail

There is about 2500 users on domain1.com, so i should raise max_mail_processes ?

-- 
Lampa


Re: [Dovecot] unlinking

2010-01-18 Thread Timo Sirainen
On 15.1.2010, at 18.46, David Halik wrote:

> Jan 15 10:04:04 gehenna13.rutgers.edu dovecot: IMAP(user): 
> unlink(/rci/nqu/rci/u8/user/dovecot/.such and such 
> maildir/.nfs001e95102b8d) failed: Device or resource busy

Wonder why it's unlinking those files. You could try if maildir_stat_dirs=yes 
helps at all.

> Jan 15 10:04:04 gehenna13.rutgers.edu dovecot: IMAP(user): 
> unlink_directory(/rci/nqu/rci/u8/user/dovecot/.such and such maildir) failed: 
> Device or resource busy

I suppose some mailbox is being deleted, but another session still has it 
selected. Not much chance of being able to do this then..



Re: [Dovecot] unlinking

2010-01-18 Thread Steffen Kaiser

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Mon, 18 Jan 2010, Steffen Kaiser wrote:


Seems like the file went away on the NFS server while it was in use /


Did not mean "the" file, but "a" file. The filename ".nfs***" does not 
reflect the original one.


Regards,

- -- 
Steffen Kaiser

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iQEVAwUBS1QijL+Vh58GPL/cAQKLrggAymQUIDHQ/AU/c5yKIWtxIW0+3hk/jAFa
ObMVDmS+/JTh9Og08TjE4UXIz4r2eHynTot/hP0dDIUfj1q3y6OfHiA3ja1m9n1K
LqsjQRFejxMZmehIUuFPAZnrFkuPQjkf1aGQTPaCnn0/w+VRDuj62wAvgA4x4uKm
VrYHdtwgXyNU/nVIWPo2Bb6cX6tnGYyODzDMLlx+xc0zjlH4/eEUXIJL4FQ80KRR
QM5wlXqal85DmWZuq/nciNtSVnW2dqntaKfF47HNfDe2Vf1uyFXSakSjOCEy9MhL
krm/LkbTMKeEbs0OxEn065w5BOo2YOB+LIixQvjHpu9Q/4IibFuuqg==
=tVjT
-END PGP SIGNATURE-


Re: [Dovecot] unlinking

2010-01-18 Thread Steffen Kaiser

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Fri, 15 Jan 2010, David Halik wrote:

Jan 15 10:04:04 gehenna13.rutgers.edu dovecot: IMAP(user): 
unlink(/rci/nqu/rci/u8/user/dovecot/.such and such 
maildir/.nfs001e95102b8d) failed: Device or resource busy


Seems like the file went away on the NFS server while it was in use / 
opened on the local host.


Jan 15 10:04:04 gehenna13.rutgers.edu dovecot: IMAP(user): 
unlink_directory(/rci/nqu/rci/u8/user/dovecot/.such and such maildir) failed: 
Device or resource busy


Same here.

Are there two or more servers access the same NFS store simultaneously?

Regards,

- -- 
Steffen Kaiser

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iQEVAwUBS1QiNr+Vh58GPL/cAQJEBgf+MmfPZrF/1zvqJLSI8gqJyxHHbxdah5ll
havko7W8RahKXv861250esjHb57Jx8li9sHGI0bvY5asJaCW6S6miOJHJ9uYM++3
/9VocNL3uHLbaOkWlj3Q7ryIl4/IOIpxz8HlbcKz7zoLM6dIwX29rU0N8AJNdjEL
3ah1TZ4FUwOz8BAIFAY/ZpPNwPbdqnDvr2/rvXqtg3MvGXEdWriPYa/9W2ibaz3R
Jl6kdNxbxyAl0R7YDD/HDD+ON22wxt5gWoeGcralyDxsKbiLNFHQOIeKEKlNxIts
nlJ7xKeWbknrFMrQ0+Kq5xk1whn8/KCoHXjdoDbgoFSUL5Imc3YK1A==
=u42Q
-END PGP SIGNATURE-


Re: [Dovecot] Strange permission problem with Maildir

2010-01-18 Thread Timo Sirainen
On 14.1.2010, at 23.23, tkin1t3asy wrote:

> POP3(username): stat(/home/username/Maildir/tmp) failed: Permission denied
> (euid=500(username) egid=500(username) missing +x perm:
> /home/username/Maildir)
..
> as you can see below the permissions are correct:
> 
> r...@host:/home/username# ls -al Maildir/
> total 744
> drwx--  8 username username220 2010-01-13 06:27 .

a) Multiple uids use the same uid. Check with ls -ln to be sure the uid really 
is 500 and not something else.

b) SELinux or something similar prevents the access because the directory has 
wrong label or something.

c) Some other filesystem ACL permission issue.



Re: [Dovecot] Fail to handle . and - in mailaddresses

2010-01-18 Thread Timo Sirainen
On 14.1.2010, at 11.13, Mika wrote:

>> From Deliver logfile:
> deliver(...---...@domain.com): Jan 14 08:18:24 Info:
> msgid=<798c378b1001132318y4a027757m37a668f48730...@mail.gmail.com>: saved
> mail to INBOX
> 
> # Does not seem to end up in any of the files in Maildir, new/tmp folders
> are empty.

Well, it went somewhere. Set mail_debug=yes to see where.



Re: [Dovecot] how-to use dsync to do a 2 ways replication ?

2010-01-18 Thread Timo Sirainen
On 13.1.2010, at 22.48, Eric Belhomme wrote:

> So I compiled dovecot 2.0 beta 1 in order to use dsync utility...

You should try with the latest hg version. Or wait until I'll release beta2. 
Hopefully by next weekend.

> I logged on the first server with an IMAP client then I copied many
> email through IMAP, then I launched dsync as root :
> 
> /usr/local/dovecot2/bin/dsync -v mirror 'ssh
> eole.it.fr.eve /usr/local/dovecot2/bin/dsync'
> r...@eole.it.fr.eve's password: 
> dsync-local(root): Error: Can't create mailbox ssh: Mailbox already
> exists
..
> It seems dsync tries to use my system user database instead of
> the /etc/dovecot/userpasswd file !

Give it -u username parameter. It currently supports syncing only one user at a 
time.

Re: [Dovecot] Upgrade path questions

2010-01-18 Thread Steffen Kaiser

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Wed, 13 Jan 2010, Thomas M Goerger wrote:


We are currently running Dovecot v1.1.6 on our servers, and are
contemplating an upgrade to 1.2, or 2.0 soon.  We are wondering how many
organizations are still running a 1.1 version of Dovecot, and if anyone


Oh, why not stretch this question ;-)

How many are still running v1.0?
(oh, don't forget Debian distros) How many are running v0.99?

Because I find ACLs quite needed, I'm looking into moving from v1.0 to 
v1.2 or v2.0.


Regards,

- -- 
Steffen Kaiser

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iQEVAwUBS1QeKb+Vh58GPL/cAQInKgf/QtHy2e/cj2yMCM54bnDptXf4zHwNNWXI
tnmsxlXdHaRVjl18W+aQf2NWGa/SKSFyFv2X8Ei723neqVwKMl8Qu93rDaEu73yB
sjfZII8p9MaSbFiL9np1qqrBz+mzgLlzOz1prEjX0+MJX57TSdRaAC5naHH2mEZQ
74yP3px5kc3whv9QNcRcduqKcKKk9FYxOxKj+tgWvKbtmt5scQ4X856Q3hDuaLL0
b7zd6SUHwSe51KOo8YyXn9rceUdBjtmHupRtjEQRXCyWVZAMOawxo7wltnyPjkP2
IdfJjSKboLSEDMKtKio5+mpTcThjfVpcjh72IgP2zSOxp1oReDDtAQ==
=PfKv
-END PGP SIGNATURE-


[Dovecot] Strange permission problem with Maildir

2010-01-18 Thread tkin1t3asy

I have this very strange problem with Dovecot spitting out a file permissions
error but further testing seems to show it being an inaccurate message.

POP3(username): maildir: data ~/Maildir
POP3(username): maildir++: root =/home/ssb201/Maildir, index=, control=,
inbox=/home/ssb201/Maildir
POP3(username): stat(/home/username/Maildir/tmp) failed: Permission denied
(euid=500(username) egid=500(username) missing +x perm:
/home/username/Maildir)
POP3(username): Couldn't open INBOX...

as you can see below the permissions are correct:

r...@host:/home/username# ls -al Maildir/
total 744
drwx--  8 username username220 2010-01-13 06:27 .
drwxr-xr-x 18 username username 80 2010-01-13 06:14 ..
drwx--  2 username username108480 2010-01-14 20:56 cur
-rw---  1 username username65272 2010-01-14 20:56 dovecot.index
-rw---  1 username username382976 2010-01-14 20:56
dovecot.index.cache
-rw---  1 username username6836 2010-01-14 20:56 dovecot.index.log
-rw---  1 username username309472 2010-01-14 20:56 dovecot-uidlist
-rw---  1 username username8 2010-01-14 20:56 dovecot-uidvalidity
-rw---  1 username username0 2010-01-14 20:56
dovecot-uidvalidity.4a090e80
drwx--  2 username username40 2010-01-14 20:56 new
drwx--  2 username username40 2010-01-14 20:56 tmp

if I rename ~/Maildir to ~/Maildir.orig and let dovecot create a new
directory it works fine with no errors.

r...@host:/home/username# ls -al Maildir
total 28
drwx--  5 username username220 2010-01-14 21:19 .
drwxr-xr-x 19 username username100 2010-01-14 21:19 ..
drwx--  2 username username40 2010-01-14 21:19 cur
-rw---  1 username username16384 2010-01-14 21:19
dovecot.index.cache
-rw---  1 username username468 2010-01-14 21:19 dovecot.index.log
-rw---  1 username username70 2010-01-14 21:19 dovecot-uidlist
-rw---  1 username username8 2010-01-14 21:19 dovecot-uidvalidity
-rw---  1 username username0 2010-01-14 21:19
dovecot-uidvalidity.4b4f8a6e
drwx--  2 username username60 2010-01-14 21:19 new
drwx--  2 username username40 2010-01-14 21:19 tmp

If I rename the newly created ~/Maildir to ~/Maildir.new, and rename
~/Maildir.orig to ~/Maildir the original directory works now with no "+x
perm" error. This would seem to imply that dovecot is modifying something,
somewhere else on the system when it creates the mail directory. What could
this be?
-- 
View this message in context: 
http://old.nabble.com/Strange-permission-problem-with-Maildir-tp27168284p27168284.html
Sent from the Dovecot mailing list archive at Nabble.com.



[Dovecot] Fail to handle . and - in mailaddresses

2010-01-18 Thread Mika

Hi,

I seem to have run into a bug. Dot and dash is allowed chars in mail
addresses, so a ...---...@ should work. Filtered out domainname and IP's
for security reasons. And yes this works with MDaemon as example. 

Setup is postfix using Dovecot for deliver.

Version: 1.2.9
OS: Linux ADM64 (Ubuntu 8.04LTS)

Tried to deliver mail to rfc compliant mail address ...---...@domain. 

# 1.2.9: /opt/dovecot/etc/dovecot.conf
# OS: Linux 2.6.24-25-server i686 Ubuntu 8.04.3 LTS ext3
log_path: /var/log/dovecot
protocols: imaps imap
listen: 127.0.0.1
ssl_listen: :943
ssl_cert_file: /etc/ssl/certs/secure.crt
ssl_key_file: /etc/ssl/private/secure.key
login_dir: /opt/dovecot/var/run/dovecot/login
login_executable: /opt/dovecot/libexec/dovecot/imap-login
mail_gid: 1005
mail_location: maildir:/opt/vmail/%d/%n/Maildir
lda:
  postmaster_address: postmas...@domain.com
  sendmail_path: /usr/sbin/sendmail
  auth_socket_path: /var/run/dovecot/auth-master
  log_path: /opt/vmail/dovecot-deliver.log
auth default:
  mechanisms: plain login
  passdb:
driver: pam
  passdb:
driver: sql
args: /opt/dovecot/etc/dovecot-sql.conf
  userdb:
driver: passwd
  userdb:
driver: static
args: uid=5000 gid=5000 home=/opt/vmail/%d/%n allow_all_users=yes
  socket:
type: listen
client:
  path: /var/spool/postfix/private/auth
  mode: 432
  user: postfix
  group: postfix
master:
  path: /var/run/dovecot/auth-master
  mode: 384
  user: vmail

>From Deliver logfile:
deliver(...---...@domain.com): Jan 14 08:18:24 Info:
msgid=<798c378b1001132318y4a027757m37a668f48730...@mail.gmail.com>: saved
mail to INBOX

# Does not seem to end up in any of the files in Maildir, new/tmp folders
are empty.
Maildir/cur# grep ...---...@domain.com *
Maildir/cur# 



//Mika


[Dovecot] how-to use dsync to do a 2 ways replication ?

2010-01-18 Thread Eric Belhomme
Hi,

I want to set-up two dovecot imap servers, with active-active replicated
maildirs. The goal is to have a hosted public server on Internet, and a
private server on my LAN to speed-up local connections.

So I compiled dovecot 2.0 beta 1 in order to use dsync utility...
Actually my config is pretty simple as I just want to setup a proof of
concept before going ahead in this way :

(Both servers are Debian Lenny with excatly the same config)

mail0:~# /usr/local/dovecot2/sbin/dovecot -n
# 2.0.beta1: /etc/dovecot2/dovecot/dovecot.conf
# OS: Linux 2.6.26-2-686 i686 Debian 5.0.3 
auth_debug = yes
auth_verbose = yes
login_trusted_networks = 172.16.64.0/18
mail_location = maildir:%h
passdb {
  args = /etc/dovecot/userpasswd
  deny = no
  driver = passwd-file
}
postmaster_address = postmas...@example.com
service pop3-login {
  inet_listener {
port = 110
  }
  inet_listener {
port = 995
ssl = yes
  }
}
service imap-login {
  inet_listener {
port = 143
  }
  inet_listener {
port = 993
ssl = yes
  }
}
ssl_cert =  541e9f2850234e4b3a2bd0cf7273)
dsync-local(root): Error: msg iteration failed: Couldn't open mailbox
dsync-remote(root): Error: Can't create mailbox debtags: Mailbox already
exists
dsync-remote(root): Error: Can't create mailbox aptitude: Mailbox
already exists
dsync-remote(root): Error: Can't create mailbox ssh: Mailbox already
exists
dsync-remote(root): Error: Mailbox debtags changed its GUID
(501e9f2850234e4b3a2bd0cf7273 -> d1fc9a2d85154e4b4718b31a5865)
dsync-remote(root): Error: msg iteration failed: Couldn't open mailbox
dsync-remote(root): Error: command MSG-LIST failed
dsync-local(root): Error: Mailbox ssh changed its GUID
(cdfc9a2d85154e4b4718b31a5865 -> 541e9f2850234e4b3a2bd0cf7273)
dsync-local(root): Error: Mailbox aptitude changed its GUID
(cffc9a2d85154e4b4718b31a5865 -> 521e9f2850234e4b3a2bd0cf7273)
dsync-local(root): Error: Mailbox debtags changed its GUID
(d1fc9a2d85154e4b4718b31a5865 -> 501e9f2850234e4b3a2bd0cf7273)
dsync-local(root): Error: Mailbox ssh changed its GUID
(cdfc9a2d85154e4b4718b31a5865 -> 541e9f2850234e4b3a2bd0cf7273)
dsync-local(root): Error: Mailbox aptitude changed its GUID
(cffc9a2d85154e4b4718b31a5865 -> 521e9f2850234e4b3a2bd0cf7273)
dsync-local(root): Error: Mailbox debtags changed its GUID
(d1fc9a2d85154e4b4718b31a5865 -> 501e9f2850234e4b3a2bd0cf7273)
mail0:~# dsync-remote(root): Error: Mailbox debtags changed its GUID
(501e9f2850234e4b3a2bd0cf7273 -> d1fc9a2d85154e4b4718b31a5865)
dsync-remote(root): Error: Mailbox aptitude changed its GUID
(521e9f2850234e4b3a2bd0cf7273 -> cffc9a2d85154e4b4718b31a5865)
dsync-remote(root): Error: Mailbox ssh changed its GUID
(541e9f2850234e4b3a2bd0cf7273 -> cdfc9a2d85154e4b4718b31a5865)
dsync-remote(root): Error: Mailbox debtags changed its GUID
(501e9f2850234e4b3a2bd0cf7273 -> d1fc9a2d85154e4b4718b31a5865)
dsync-remote(root): Error: Mailbox aptitude changed its GUID
(521e9f2850234e4b3a2bd0cf7273 -> cffc9a2d85154e4b4718b31a5865)
dsync-remote(root): Error: Mailbox ssh changed its GUID
(541e9f2850234e4b3a2bd0cf7273 -> cdfc9a2d85154e4b4718b31a5865)


It seems dsync tries to use my system user database instead of
the /etc/dovecot/userpasswd file !

I found dsync doc on the wiki at http://wiki2.dovecot.org/Tools/dsync
but this is not really clear for me...

So maybe someone can tell me what's wrong ?

Regards,

-- 
Eric Belhomme




Re: [Dovecot] Adding support for a new storage format - plugin?

2010-01-18 Thread Timo Sirainen
On 18.1.2010, at 8.23, Brad Hards wrote:

> Background:
> I'm interested in dovecot to provide IMAP access to an existing database 
> backed server store (http://www.openchange.org for more details). The goal is 
> to provide parallel access using either IMAP or the exchange RPC protocol.

I've also previously thought about adding support for OpenChange, but I've 
never really had time to even start looking much into it. Or actually it's 
really the other way around, I'd want to add Exchange RPC support for Dovecot's 
storage backends.

> If I understand this stuff:
> * I can potentially provide access to the store using a plugin. It looks like 
> the virtual mailbox plugin is a potential example here.

Well, implementing the store using a plugin is exactly the same as implementing 
it inside Dovecot's lib-storage code. So any of the lib-storage backends could 
be used as an example.

> * I may need to also provide an authentication plugin (not sure whether I can 
> just re-use the existing ldap backend - quite possibly a useful option in my 
> scenario)

Dovecot can authenticate against AD with LDAP backend, so I'd hope that would 
be enough.

> * I probably can't use the existing SQL code, since it uses its own schema.

What SQL code? You mean the SQL mail backend code I wrote years ago and never 
finished?