acl shared maildir with virtual users
Can anyone point out where i'm going wrong with my dovecot sharedinbox setup with ACL i'm contemplating giving up with dovecot alltogether i've spent 3 days trying different paths to the virtual users mailboxes I seem to have two issues my acls are getting written to my sql db fine in roundcube i can see the shared folder but cant subscribe to it in thunderbird if i go to namespaces it sees the shared. namespace but its not listing anything in it even though my acls are written to the db please someone tell me what i'm missing i'm betting its something silly but i've been over and over the wiki here is my conf and below it an extract of my debug log # 2.2.28 (bed8434): /etc/dovecot/dovecot.conf # OS: Linux 2.6.32-642.3.1.el6.x86_64 x86_64 CentOS release 6.9 (Final) auth_cache_size = 1 M auth_debug = yes auth_debug_passwords = yes auth_mechanisms = plain login auth_policy_hash_mech = sha512 auth_policy_hash_nonce = 78204771 auth_policy_hash_truncate = 64 auth_policy_request_attributes = auth_database=mail database=mail service=dovecot username=%{orig_user} authtoken_hash=$0$0$%{hashed_password} local_host=%{real_lip} local_port=%{real_lport} remote_host=%{real_rip} remote_port=%{real_rport} auth_policy_server_api_header = X-API-Key:dovecot: auth_policy_server_timeout_msecs = 3000 auth_policy_server_url = http://127.0.0.1:579/dovecot-auth-policy auth_username_chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!#$-=?^_{}~./@+%" auth_verbose = yes dict { acl = sqlite:/usr/local/cpanel/etc/dovecot/dovecot-dict-shares.conf.ext expire = sqlite:/usr/local/cpanel/etc/dovecot/dovecot-dict-expire.conf.ext } disable_plaintext_auth = no first_valid_uid = 201 lda_mailbox_autocreate = yes lmtp_save_to_detail_mailbox = yes login_greeting = Welcome to Motorsport Tools mail_access_groups = dovecot mail_debug = yes mail_plugins = acl quota quota_clone fts fts_solr mail_prefetch_count = 20 mailbox_list_index = yes namespace inbox { inbox = yes location = mailbox Archive { auto = create special_use = \Archive } mailbox Archives { auto = no special_use = \Archive } mailbox Drafts { auto = subscribe special_use = \Drafts } mailbox Junk { auto = create special_use = \Junk } mailbox Sent { auto = subscribe special_use = \Sent } mailbox "Sent Messages" { auto = no special_use = \Sent } mailbox Trash { auto = subscribe special_use = \Trash } mailbox spam { auto = create special_use = \Junk } prefix = INBOX. separator = . type = private } passdb { args = /usr/local/cpanel/etc/dovecot/cpauthd-dict.conf driver = dict result_failure = return-fail } passdb { args = /usr/local/cpanel/bin/dovecot-wrap driver = checkpassword skip = authenticated } plugin { acl = vfile:cache_secs=86400 acl_anyone = allow acl_shared_dict = proxy::acl expire_cache = yes fts = solr fts_solr = url=http://lTkFlGxjRar1hZAW:Ocj1FRRvlUs5Udj6@127.0.0.1:8984/solr/dovecot/ quota_exceeded_message = Mailbox is full please archive you old mail zlib_save = gz } protocols = lmtp imap service auth { unix_listener auth-client { mode = 0666 } } service config { vsz_limit = 2 G } service dict { unix_listener dict { group = dovecot mode = 0660 } } service imap-login { client_limit = 500 inet_listener imap { address = *,:: } inet_listener imaps { address = *,:: } process_limit = 100 process_min_avail = 8 service_count = 0 vsz_limit = 128 M } service imap { process_limit = 1024 vsz_limit = 512 M } service lmtp { client_limit = 1 process_limit = 500 unix_listener lmtp { group = mail mode = 0660 user = mailnull } vsz_limit = 512 M } service managesieve-login { client_limit = 500 process_limit = 100 process_min_avail = 8 service_count = 0 vsz_limit = 128 M } service managesieve { process_limit = 1024 vsz_limit = 512 M } service quota-status { executable = quota-status -p postfix unix_listener quota-status { mode = 0666 } } ssl = required ssl_cert =
Re: Looking for way to monitor dsync, confirm it is or isn't running
Earlier, I asked: >> I would like to be able to run some sort of periodic health check to >> confirm that dsync is (or is not) running properly between the two >> sites, and alert me if dsync is failing or lagging excessively. Does >> anyone know of a tool to do this? and Michael Grimm replied: > doveadm replicator status > > If those numbers tend to become significantly larger than 0, then > replication has issues. I do not use that for health checking . . . > but used it once in a while when suspecting issues with replication. Thanks. As a followup question: If "doveadm replicator status" shows problems, are there any commands available to pinpoint exactly which request(s) is/are causing the problem(s)? One of the sites I am administering, for example, has been reporting 1 "queued 'full resync' requests" and 9 "waiting 'failed' requests" for the past couple of days. But I have no idea how to resolve the issue. Suggestions welcome. Rich Wales ri...@richw.org
Looking for way to monitor dsync, confirm it is or isn't running
I am syncing two Dovecot sites using the dsync function. I would like to be able to run some sort of periodic health check to confirm that dsync is (or is not) running properly between the two sites, and alert me if dsync is failing or lagging excessively. Does anyone know of a tool to do this? (If possible, something I can set up to run periodically in Nagios?) Thanks for any suggestions. Rich Wales ri...@richw.org
Re: the prefix number of the configuration filename
> Hi all, I am very curious about the prefix number of the configuration > filename, such as 10-auth.conf What are those meanings of 10,15,20 > and 90 ? The configuration files are read and processed according to the sorting order of their names. Adding the numeric prefixes allows the order in which the files are processed to be determined independently of their names. So, in this case, the config files with names starting with 10 are read first (i.e., 10-director.conf is processed first). If the number prefixes weren't there, then the "acl.conf" file would be processed first (instead of near the end). It matters what order the configuration files are processed in because later files can override parameters set by earlier files. Rich Wales ri...@richw.org
Health check for dsync?
I am syncing two Dovecot sites using dsync. Are there any tools available to confirm that dsync is (or is not) running properly between the two sites? (E.g., something I could run periodically in Nagios?) Rich Wales ri...@richw.org
[Dovecot] Config problem: want SSL + local roundcube
Hi, Have used dovecot for many years, happy that it worked well without me needing to do anything much! But since the upgrade from v1 to v2.1.7-7 I've come across some config probs. I want IMAP and to force TLS for all internet connections. However, I run RoundCube on the same server (over https) and this needs access too, but this doesn't need to be TLS because it's local anyway. The auto-config update script made some changes, it added the following to force SSL. service imap-login { inet_listener imap { port = 0 } } ssl = required But this seems to forbid the local roundcube service from logging in. Can anyone help me with my config? I had a stab, adding the following, but it didn't work. Was a complete guess anyway! remote 127.0.0.1 { ssl = no service imap-login { inet_listener imap { port = 143 } } } Here's my full config: # 2.1.7: /etc/dovecot/dovecot.conf # OS: Linux 2.6.32-5-amd64 x86_64 Debian 7.2 ext3 auth_default_realm = artfulrobot.com log_timestamp = %Y-%m-%d %H:%M:%S mail_location = maildir:/home/virtual/%d/%n mail_privileged_group = mail passdb { args = username_format=%n /etc/exim4/virtual_domains/%d/passwords driver = passwd-file } protocols = imap service auth { unix_listener auth-client { group = Debian-exim mode = 0660 } user = root } service imap-login { inet_listener imap { port = 0 } } ssl = required ssl_cert = /etc/ssl/certs/mail.artfulrobot.com-with-chain.crt ssl_key = /etc/ssl/private/mail.artfulrobot.com.key userdb { args = uid=1001 gid=1001 driver = static } userdb { driver = passwd } Thanks, Rich
Re: [Dovecot] Config problem: want SSL + local roundcube
On 05/11/13 15:56, Reindl Harald wrote: does it hurt? no! My SSL certificate is of course invalid for 127.0.0.1 and I could not get RC to connect on port 993 for some reason (although that's probably for a RC mailing list, granted).
Re: [Dovecot] Config problem: want SSL + local roundcube
Ok, thanks for your time, let's end this thread. Seems it's probably more a RC thing than a Dovecot thing. Still can't get it to work (yes I'd already RTFM'ed and tried all the various RC config options) but happy to ask over at RC instead. Thanks. Rich
Re: [Dovecot] Replication fails with Remote dsync doesn't use compatible protocol
richatwork dovecot: doveadm: Error: dsync-remote(richatwork): Error: dsync(local): Remote dsync doesn't use compatible protocol I was finally able to get replication working by abandoning the wrapper script approach and, instead, putting a mail_replica value on each line of the userdb file -- like this: richatwork:hashed password here:5003:5003::/home/mail/richatwork::userdb_mail_replica=remote:richatw...@pigeon.richw.org The root dsync public key in each individual account's .ssh/authorized_keys file has a command= parameter invoking /usr/bin/doveadm dsync-server with the appropriate -u option. As I noted in an earlier e-mail, if you put a command= parameter on a public key in the authorized_keys file, you don't need to specify the command in the ssh command line -- in fact, there is no point to doing that (any command in the ssh command line is ignored if the public key on the target has a command= parameter). Now that I have replication working, I have another question: Is it sufficient to configure just one server for replication in order to have changes propagated in both directions? Or do I need to configure replication on both servers (with each one replicating to the other)? Rich Wales ri...@richw.org
[Dovecot] Replication fails with Remote dsync doesn't use compatible protocol
I can't get replication to work in Dovecot 2.2.1. I'm getting the following error on the machine where I'm initiating the replication: richatwork dovecot: doveadm: Error: dsync-remote(richatwork): Error: dsync(local): Remote dsync doesn't use compatible protocol Both the local and remote servers are running identical versions of Dovecot (2.2.1), so I don't understand why I would be having any sort of compatible protocol problem. Any ideas? I posted the dovecot -n output for both servers in my earlier e-mail on this issue, which I sent about 24 hours ago (and which I assume was too long for people to be willing to read). Rich Wales ri...@richw.org
Re: [Dovecot] Replication -- multiple users, three or more servers?
I've ALMOST got this to work, but I'm still running into a problem. First, here's what I'm doing so far. If my understanding of what's going on (described below) is off, I trust someone will correct me. Also, when/if I get these details straight, I'm willing to help update the Replication wiki page to make it clearer and more accurate. I followed Obi-wan's admonition (Use the source, Luke) and figured out that when the mail_replica value starts with remoteprefix:, the behaviour is identical to remote: EXCEPT that the data stream sent to the remote server starts with a line containing the mail account name followed by a newline character. Also, it appears that the dsync_remote_cmd is run by default as root on the local server. I'm assuming for the moment that %{user} and %{host} in dsync_remote_cmd are being replaced by the user and host information in the mail_replica value. If the public key value included in authorized_keys for the target account on the remote server contains a command= parameter, the ssh documentation says that this command will override any command given on the ssh command line on the local server. Thus, it should not really be necessary to include a remote command on the tail end of the ssh specified in dsync_remote_cmd. Note, BTW, that the authorized_keys2 file (mentioned in the current documentation) is deprecated now in SSH; all public keys on the remote server should be in authorized_keys now. I also discovered that in order to get ssh to work properly in a non-interactive scenario -- without any prompting for typed input (which would break things) -- I needed to run the ssh command once by hand, to cache the remote server's host key information in the local known_hosts file. So, with all the above in mind, I added the following to the Dovecot configuration on the local host. (My local host is named richatwork, and my remote host is named pigeon.) mail_plugins = $mail_plugins notify replication service replicator { process_min_avail = 1 } dsync_remote_cmd = /usr/bin/ssh -i /root/.ssh/dsync_dsa %{user}@%{host} plugin { mail_replica = remoteprefix:r...@pigeon.richw.org } I added the public key value (from /root/.ssh/dsync_dsa.pub) to the /root/.ssh/authorized_keys file on the remote host (pigeon), with the command= parameter set to the name of a script on the remote host with the following content: #! /bin/sh read username exec /usr/bin/doveadm dsync-server -u $username With the above setup, replication ALMOST seems to work, EXCEPT that it's failing with the following error in the local host's mail.log: richatwork dovecot: doveadm: Error: dsync-remote(richatwork): Error: dsync(local): Remote dsync doesn't use compatible protocol Both servers are running the identical version of Dovecot (2.2.1), so I'm confused as to why I would be getting a protocol mismatch. Is there some other configuration option I need to check? Rich Wales ri...@richw.org =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= dovecot -n output on the local server (richatwork): # 2.2.1 (e819374de157): /etc/dovecot/dovecot.conf # OS: Linux 3.2.0-40-generic-pae i686 Ubuntu 12.04.2 LTS auth_username_format = %Ln auth_verbose = yes dsync_remote_cmd = /usr/bin/ssh -i /root/.ssh/dsync_dsa %{user}@%{host} login_greeting = richatwork.richw.org (%{lip}) Dovecot ready; hello, %{rip} mail_location = maildir:~/Maildir mail_plugins = notify replication managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave namespace inbox { inbox = yes location = mailbox Drafts { special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { special_use = \Sent } mailbox Sent Messages { special_use = \Sent } mailbox Trash { special_use = \Trash } prefix = separator = . } passdb { args = scheme=crypt username_format=%n /etc/dovecot/private/userdb driver = passwd-file } plugin { mail_replica = remoteprefix:r...@pigeon.richw.org sieve = ~/.dovecot.sieve sieve_dir = ~/sieve sieve_max_actions = 1000 } protocols = imap lmtp sieve service auth-worker { user = $default_internal_user } service auth { unix_listener /var/spool/postfix/private/auth { group = postfix mode = 0666 user = postfix } unix_listener auth-userdb { group = user = } } service imap { executable = imap postlogin } service lmtp { inet_listener lmtp { address = 127.0.0.1 port = 24 } process_min_avail = 5 } service postlogin { executable = script-login -d rawlog -t } service replicator { process_min_avail = 1 } ssl_cert = /etc/apache2/ssl/richatwork.pem ssl_key = /etc/apache2/ssl/richatwork.pem userdb { args = username_format=%n /etc/dovecot/private/userdb driver = passwd-file } protocol lmtp { mail_plugins = notify
Re: [Dovecot] Replication -- multiple users, three or more servers?
Replying to Timo: Everything is the same as in that wiki page, except you need to have userdb field override the mail_replica setting. Or I guess you wouldn't want to have a default mail_replica at all, so users won't accidentally get replicated to wrong place. See http://wiki2.dovecot.org/UserDatabase/ExtraFields OK, thanks. Is there a debugging option I can specify here to cause Dovecot to generate more verbose logging output, so I can see exactly what is happening (and what is not working) when I try to run replication? In the Replication wiki page, you show one example using the string remote: at the start of the mail_replica value, and another example starting with remoteprefix:. What is the difference between these? Or is there a typo here? I tried searching the wiki but couldn't find anything explaining this. The example with a dsync wrapper script seems to be describing a situation where the first line of text sent to the remote host consists of the user name (which is read by the wrapper script and passed as a command-line argument to dsync-server). Is this what remoteprefix: does, in contrast to remote:? In the dsync wrapper script example, is vmail in the mail_replica value an example of a user ID to be used on the remote host? What user ID is used on the local host? I think one reason why my tests so far haven't been working may be that I'm not sure which user ID is being used on each end, so my SSH keys aren't being used properly and the connection is failing. Finally, the Replication wiki page mentions the authorized_keys2 file, which (AFAIK) is deprecated in the current SSH -- all authorized keys should be in a single authorized_keys file on the target host, right? Rich Wales ri...@richw.org
[Dovecot] Replication -- multiple users, three or more servers?
I'm running Dovecot 2.2.1 on an Ubuntu 12.04.2 server, with half a dozen accounts for various family members. I want to set up replication involving at least three Ubuntu servers, with different users replicated on different sets of servers. For example, I might have mail for user1 replicated on server1, server2, and server3... while mail for user2 would be on server1 and server2... and mail for user3 would be on server1 and server3. I've read the wiki page (http://wiki2.dovecot.org/Replication), but I'm still confused. I'd love to see an example that clearly shows how to set up specific individual mail users to be replicated on a different set of servers for each user, like what I described above. Rich Wales ri...@richw.org
[Dovecot] Pros and cons of having folders under INBOX vs. not
I have some questions about whether I should set up folders under INBOX vs. having them outside the INBOX namespace. I'm setting up a new Dovecot 2.2.0 on an Ubuntu 12.04.2 server. My plan is to move my users (family members) to this new server from an old Cyrus server. Everybody is currently using (and will continue to use) IMAP, and either Thunderbird or SquirrelMail as their e-mail client. I'm using the maildir mailbox format on this new Dovecot server. No one is using the new Dovecot server yet, so I'm still free to do additional tweaking of the server configuration. When I used imapsync to copy everyone's mail to the new server, I found that all the folders (other than INBOX) were renamed. On the old Cyrus server, all the folders are subfolders of INBOX, but the folders on the new Dovecot server are not. (For example, a folder named INBOX.Dovecot on the old server was renamed to Dovecot on the new server by the imapsync utility.) Can I just keep things this way on the new server? Or are my users going to run into problems if folders are not all under INBOX? I do realize that IMAP servers can be set up either to put everything under INBOX, or not, but I'm not familiar with all the pros/cons. And if I do need (or want) to put all the folders under INBOX, can I simply rename the existing folders in each user's Maildir (and also edit folder names accordingly in everyone's subscriptions file)? Or will Dovecot be broken unless I recopy everything from scratch (with a command-line option to imapsync to put everything in the INBOX destination namespace)? Rich Wales ri...@richw.org
Re: [Dovecot] mdbox and folders containing both messages and sub-folders
Repying to Timo Sirainen: What is the error message exactly? I'm wondering if the error is coming from Dovecot or if Larch is somehow confused internally and giving bogus errors. Certainly a reasonable question. I tried to enable full debugging output in both Dovecot and Larch, but I couldn't get anything helpful. Is there a way to make Dovecot report all IMAP commands and responses, so I can see exactly what the client is asking for, and exactly why Dovecot is refusing to do it? Alternatively, does anyone here know Ruby (the language Larch is written in) well enough to say how to make its low-level IMAP module give a full logging of all commands and responses? For what it may or may not be worth, I'm trying my same mail migration test using Maildir instead of mdbox, and it appears to be working fine. Rich Wales ri...@richw.org
Re: [Dovecot] mdbox and folders containing both messages and sub-folders
Replying to Timo Sirainen: But didn't you say Larch was giving some errors already? Yes, but the Larch error message said only mailbox cannot contain messages, followed by the name of the folder into which it couldn't store a message. I looked at the Larch source code (written in Ruby, a language I have never used and don't really know at all), and this particular error message appears to be generated when Larch is unable to select or create a given mailbox. Exactly what the IMAP rejection response from Dovecot is, I can't tell; it's not being reported anywhere as far as I can see. Maybe Larch has some mbox-specific code and it thinks that dbox looks similar.. Larch isn't accessing Dovecot's internal mailbox structure at all -- it's just talking to the IMAP server. I'm not sure what sort of mbox-specific code could be involved in such a scenario. Is there anything about mbox vs. dbox that would be reflected in the way a Dovecot server behaves when using IMAP? I think what I really need here is a way to look at the actual, literal IMAP commands and responses (not just abstract interpretations of the errors from Dovecot, Larch, or any other program). Without that information, I don't see how I can tell what the problem is, or whether it's in Dovecot or Larch. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Replying to Robert Schetterer: Is there a way to make Dovecot report all IMAP commands and responses, so I can see exactly what the client is asking for, and exactly why Dovecot is refusing to do it? verbose logging and mail logger plugin http://wiki2.dovecot.org/Logging http://wiki2.dovecot.org/Plugins/MailLog I enabled these -- at least, I think I did; see my doveconf -n output below -- but I'm still not getting a full description of the IMAP commands and responses. Is there any way to see the actual, literal IMAP dialogue? Alternatively, does anyone here know Ruby (the language Larch is written in) well enough to say how to make its low-level IMAP module give a full logging of all commands and responses? no, perhaps try imapsync, it [has always] worked for me I'm confused by the licensing status of Imapsync. The official web site for Imapsync says it is a commercial product (50 EUR). I found another web site (fedorahosted.org) that claims to have the latest Imapsync as a free download, but I'm unsure as to whether this copy is legitimate or pirated. Can anyone clear this up for me? I had originally preferred to use Imapsync, but I'm not prepared to pay 50 EUR for it, and I don't want to use a pirated free copy. show dovecot conf and log OK, see below for my current output of doveconf -n. Note that I'm trying out Maildir right now; when I was using mdbox, my mail_location configuration line read as follows: mail_location = mdbox:~/mdbox:DIRNAME=.indexes:INDEX=~/mdbox/indexes or like this: mail_location = mdbox:~/mdbox:DIRNAME=.indexes As for the log output (in /var/log/mail.log), there were no error messages of any kind. There were a bunch of Debug: Namespace messages saying path doesn't exist yet, using default permissions, but that's all. I'm including (see below) an excerpt from my log output, showing the results of one session. Again, I'm assuming at this point that I'm going to need to see the literal, low-level IMAP commands and responses before I can tell if this is a bug in Dovecot, a bug in Larch, or something else. Rich Wales ri...@richw.org =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= # 2.2.rc5 (c24783148d78): /etc/dovecot/dovecot.conf # OS: Linux 3.5.0-26-generic x86_64 Ubuntu 12.04.2 LTS auth_verbose = yes mail_debug = yes mail_location = maildir:~/Maildir namespace inbox { inbox = yes location = mailbox Drafts { special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { special_use = \Sent } mailbox Sent Messages { special_use = \Sent } mailbox Trash { special_use = \Trash } prefix = separator = . } passdb { driver = pam } plugin { mail_log_events = delete undelete expunge copy mailbox_delete mailbox_rename mail_log_fields = uid box msgid size sieve = ~/.dovecot.sieve sieve_dir = ~/sieve } protocols = imap ssl_cert = /etc/apache2/ssl/pigeon.pem ssl_key = /etc/apache2/ssl/pigeon.pem userdb { driver = passwd } protocol imap { imap_client_workarounds = delay-newmail tb-extra-mailbox-sep tb-lsub-flags mail_plugins = mail_log notify } =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= imap-login: Login: user=randerzo, method=PLAIN, rip=127.0.0.1, lip=127.0.0.1, mpid=29976, secured, session=vZi1RrjZFgB/AAAB imap(randerzo): Debug: Effective uid=5006, gid=5006, home=/home/mail/randerzo imap(randerzo): Debug: Namespace inbox: type=private, prefix=, sep=., inbox=yes, hidden=no, list=yes, subscriptions=yes location=mdbox:~/mdbox:DIRNAME=.indexes imap(randerzo
Re: [Dovecot] Imapsync - WAS: Re: mdbox and folders containing both messages and sub-folders
Replying to Charles Marcus: https://github.com/imapsync/imapsync Note the contents of the license file: Quite bizarre. So the author of the program is selling it for 50 EUR, but at the same time he has released the latest version of the source (the same as what he's selling) via a free licence. (!?!) OK, thanks for setting my mind at ease. Rich Wales ri...@richw.org
Re: [Dovecot] mdbox and folders containing both messages and sub-folders
Replying to e-frog: http://wiki2.dovecot.org/Debugging/Rawlog Thanks. I'll try this and (hopefully) be able to tell what's going on. Rich Wales ri...@richw.org
Re: [Dovecot] mdbox and folders containing both messages and sub-folders
I retried my test with raw IMAP logging in effect. Each test involved importing about 900 messages into an empty account on my Dovecot server, using the Larch program. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= When I use the mdbox format, there are a bunch of LIST and LSUB commands whose responses mention INBOX.Trash with the \Noselect and \HasChildren flags (the Trash folder for this particular account happens to contain subfolders). Before trying to save a message in the Trash folder, the client did a SUBSCRIBE INBOX.Trash (which succeeded) followed by a STATUS INBOX.Trash (which failed with NO Mailbox doesn't exist). =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= When I use the Maildir format, the raw log never mentions the \Noselect flag in connection with the INBOX.Trash folder. Before trying to save a message in the Trash folder, the client did a CREATE INBOX.Trash, SUBSCRIBE INBOX.Trash, STATUS INBOX.Trash, and SELECT INBOX.Trash -- all of which succeeded -- and then an APPEND INBOX.Trash command was given, which also succeeded. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= So, with the mdbox format, Larch did not CREATE the folder before trying to SELECT it. And Dovecot was flagging INBOX.Trash with a \Noselect flag (which was not the case with the Maildir format). I'm not familiar enough with Dovecot or IMAP to know exactly what this difference means, but hopefully it will reveal something to someone here. Let me know if you need to see other stuff in these raw logs that I didn't mention here. Rich Wales ri...@richw.org
[Dovecot] mdbox and folders containing both messages and sub-folders
I've got Dovecot 2.2r5 (Ubuntu package version 2:2.2.0~rc5-0~auto+1 from the testing-auto/dovecot-2.2 repository on xi.rename-it.nl) running on a brand-new Ubuntu 12.04.2 server. I'm trying to configure Dovecot (using the mdbox mailbox format) to allow folders to contain both messages and sub-folders. However, it's not working consistently. I need to have folders with both messages and sub-folders because I'm trying to migrate mail from an existing (but soon-to-be-retired) Cyrus server, and the existing body of mail has folders of this sort. I'm currently using the following configuration line: mail_location = mdbox:~/mdbox:DIRNAME=.indexes:INDEX=~/mdbox/indexes and am using the Larch program to do an IMAP-to-IMAP copy of one of my family member's mail from the old Cyrus server to the new Dovecot server. When I examine the mailboxes directory tree, I see some directories that (correctly) contain both the renamed .indexes directory and also directories for IMAP subfolders. However, the Larch output is showing many errors of the form mailbox cannot contain messages, and some of the messages could not be migrated because of this problem. Am I doing something wrong? Or is the folders containing both messages and sub-folders feature simply broken for the mdbox format -- meaning presumably that I'll be forced either to use the Maildir format, or else abandon Dovecot entirely and install Cyrus on my new mail server instead? Rich Wales ri...@richw.org
Re: [Dovecot] looking for Dovecot-code + SQL consultants
Hi, I've already received a number of replies from providers offering to help out. I'll be in touch with each, and am certain we'll be able to find the right solution from among them. Thanks for the responses, Rich On Tue, Nov 1, 2011 at 1:53 PM, Rich pgnet.dev+rich-dove...@gmail.com wrote: Hi, We're using Dovecot2. Trying, given our own spread-too-thin bandwidth, to make it work within our evolving SQL application environment. When there's a problem, we post to this list (e.g., http://www.dovecot.org/list/dovecot/2011-October/061609.html), but aren't getting any/timely responses. We've decided to look for a consultant (hourly or retainer) that can be available for working with our in-house staff to straighten these issues out -- by helping us identify fix our own mess, and by working to get fixes pushed to Dovecot project code, where appropriate. If you provide these services, rather than simply deployment or hosting, and are available, please drop me a line *offlist*. We're in the San Francisco area, and local is best, but remote work is certainly an option. Thanks, Rich
[Dovecot] looking for Dovecot-code + SQL consultants
Hi, We're using Dovecot2. Trying, given our own spread-too-thin bandwidth, to make it work within our evolving SQL application environment. When there's a problem, we post to this list (e.g., http://www.dovecot.org/list/dovecot/2011-October/061609.html), but aren't getting any/timely responses. We've decided to look for a consultant (hourly or retainer) that can be available for working with our in-house staff to straighten these issues out -- by helping us identify fix our own mess, and by working to get fixes pushed to Dovecot project code, where appropriate. If you provide these services, rather than simply deployment or hosting, and are available, please drop me a line *offlist*. We're in the San Francisco area, and local is best, but remote work is certainly an option. Thanks, Rich
[Dovecot] Are you successfully using using SQL queries to manage Dovecot2 Quota Values Limits?
On Mon, Oct 24, 2011 at 11:14 AM, Rich pgnet.dev+rich-dove...@gmail.com wrote: I'm able to consistently reproduce this problem/behavior, but not workaround or fix it, yet. Rich On Wed, Oct 19, 2011 at 7:41 AM, Rich pgnet.dev+rich-dove...@gmail.com wrote: I've made some progress, but quota 'Limit' is still not fully functioning for me. A couple of changes have helped: Specifying a %u% as username format, /etc/dovecot/conf.d/90-quota.conf plugin { - quota = dict:User Quota::proxy::quota + quota = dict:User Quota:%u:proxy::quota quota_rule = *:bytes=1073741824:messages=1 quota_rule2 = Trash:storage=+10%% } using 'username' rather than 'user' in the user iteration query /etc/dovecot/sql/virtmail-userdb-sql.cf driver = mysql connect = host=/var/run/mysql/mysql.sock dbname=my_db user=my_user password=my_pass user_query = CALL UserDBQuery('%n','%d'); - iterate_query = SELECT `MAILBOX_user_domain` AS user FROM `PARAMS`; + iterate_query = SELECT `MAILBOX_user_domain` AS username FROM `PARAMS`; and adding to my user_query, CREATE PROCEDURE `UserDBQuery`( ... SELECT ... concat('*:bytes=', quota_bytes, ':messages=1') AS quota_rule, ... Now, at init, doveadm quota get -A Username Quota name Type Value Limit % myu...@domain1.com User quota STORAGE 0 0 0 myu...@domain1.com User quota MESSAGE 0 1 0 myu...@domain2.com User quota STORAGE 0 0 0 myu...@domain2.com User quota MESSAGE 0 1 0 mysql select * from PARAMS; ++++-+ | ai | MAILBOX_user_domain | quota_bytes | quota_msgs | +++-++ | 1 | myu...@domain1.com | 0 | 0 | | 2 | myu...@domain2.com | 0 | 0 | ++++-+ 2 rows in set (0.00 sec) and, after sending a single message to 'myu...@domain1.com', I do see that Dovecot now recognizes/calculates a quota change, and only for one domain, doveadm quota get -A Username Quota name Type Value Limit % myu...@domain1.com User quota STORAGE 3 3 100 myu...@domain1.com User quota MESSAGE 1 1 0 myu...@domain2.com User quota STORAGE 0 0 0 myu...@domain2.com User quota MESSAGE 0 1 0 mysql select * from PARAMS; ++++-+ | ai | MAILBOX_user_domain | quota_bytes | quota_msgs | +++-++ | 1 | myu...@domain1.com | 3269 | 1 | | 2 | myu...@domain2.com | 0 | 0 | ++++-+ 2 rows in set (0.00 sec) But, the Limit's wrong. It's not picking up the global Limit from /etc/dovecot/conf.d/90-quota.conf ... -- quota_rule = *:bytes=1073741824:messages=1 ... and once a message quota Value is calculated, the Limit is set == Value, resulting in an incorrrect quota %-age of 100%. Is Limit supposed to be specified per-user? Rich
[Dovecot] [bug] Changing dovecot 'quota' Value incorrectly overwrites Limit with same value
I'm able to consistently reproduce this problem/behavior, but not workaround or fix it, yet. Rich On Wed, Oct 19, 2011 at 7:41 AM, Rich pgnet.dev+rich-dove...@gmail.com wrote: I've made some progress, but quota 'Limit' is still not fully functioning for me. A couple of changes have helped: Specifying a %u% as username format, /etc/dovecot/conf.d/90-quota.conf plugin { - quota = dict:User Quota::proxy::quota + quota = dict:User Quota:%u:proxy::quota quota_rule = *:bytes=1073741824:messages=1 quota_rule2 = Trash:storage=+10%% } using 'username' rather than 'user' in the user iteration query /etc/dovecot/sql/virtmail-userdb-sql.cf driver = mysql connect = host=/var/run/mysql/mysql.sock dbname=my_db user=my_user password=my_pass user_query = CALL UserDBQuery('%n','%d'); - iterate_query = SELECT `MAILBOX_user_domain` AS user FROM `PARAMS`; + iterate_query = SELECT `MAILBOX_user_domain` AS username FROM `PARAMS`; and adding to my user_query, CREATE PROCEDURE `UserDBQuery`( ... SELECT ... concat('*:bytes=', quota_bytes, ':messages=1') AS quota_rule, ... Now, at init, doveadm quota get -A Username Quota name Type Value Limit % myu...@domain1.com User quota STORAGE 0 0 0 myu...@domain1.com User quota MESSAGE 0 1 0 myu...@domain2.com User quota STORAGE 0 0 0 myu...@domain2.com User quota MESSAGE 0 1 0 mysql select * from PARAMS; ++++-+ | ai | MAILBOX_user_domain | quota_bytes | quota_msgs | +++-++ | 1 | myu...@domain1.com | 0 | 0 | | 2 | myu...@domain2.com | 0 | 0 | ++++-+ 2 rows in set (0.00 sec) and, after sending a single message to 'myu...@domain1.com', I do see that Dovecot now recognizes/calculates a quota change, and only for one domain, doveadm quota get -A Username Quota name Type Value Limit % myu...@domain1.com User quota STORAGE 3 3 100 myu...@domain1.com User quota MESSAGE 1 1 0 myu...@domain2.com User quota STORAGE 0 0 0 myu...@domain2.com User quota MESSAGE 0 1 0 mysql select * from PARAMS; ++++-+ | ai | MAILBOX_user_domain | quota_bytes | quota_msgs | +++-++ | 1 | myu...@domain1.com | 3269 | 1 | | 2 | myu...@domain2.com | 0 | 0 | ++++-+ 2 rows in set (0.00 sec) But, the Limit's wrong. It's not picking up the global Limit from /etc/dovecot/conf.d/90-quota.conf ... -- quota_rule = *:bytes=1073741824:messages=1 ... and once a message quota Value is calculated, the Limit is set == Value, resulting in an incorrrect quota %-age of 100%. Is Limit supposed to be specified per-user? Rich
Re: [Dovecot] 'doveadm quota get' dictionary SQL query ignores specified '@domain' part of username. bad config or bug?
I've made some progress, but quota 'Limit' is still not fully functioning for me. A couple of changes have helped: Specifying a %u% as username format, /etc/dovecot/conf.d/90-quota.conf plugin { - quota = dict:User Quota::proxy::quota + quota = dict:User Quota:%u:proxy::quota quota_rule = *:bytes=1073741824:messages=1 quota_rule2 = Trash:storage=+10%% } using 'username' rather than 'user' in the user iteration query /etc/dovecot/sql/virtmail-userdb-sql.cf driver = mysql connect = host=/var/run/mysql/mysql.sock dbname=my_db user=my_user password=my_pass user_query = CALL UserDBQuery('%n','%d'); - iterate_query = SELECT `MAILBOX_user_domain` AS user FROM `PARAMS`; + iterate_query = SELECT `MAILBOX_user_domain` AS username FROM `PARAMS`; and adding to my user_query, CREATE PROCEDURE `UserDBQuery`( ... SELECT ... concat('*:bytes=', quota_bytes, ':messages=1') AS quota_rule, ... Now, at init, doveadm quota get -A UsernameQuota name TypeValue Limit % myu...@domain1.com User quota STORAGE 0 0 0 myu...@domain1.com User quota MESSAGE 0 1 0 myu...@domain2.com User quota STORAGE 0 0 0 myu...@domain2.com User quota MESSAGE 0 1 0 mysql select * from PARAMS; ++++-+ | ai | MAILBOX_user_domain| quota_bytes | quota_msgs | +++-++ | 1 | myu...@domain1.com| 0 | 0 | | 2 | myu...@domain2.com| 0 | 0 | ++++-+ 2 rows in set (0.00 sec) and, after sending a single message to 'myu...@domain1.com', I do see that Dovecot now recognizes/calculates a quota change, and only for one domain, doveadm quota get -A UsernameQuota name TypeValue Limit % myu...@domain1.com User quota STORAGE 3 3 100 myu...@domain1.com User quota MESSAGE 1 1 0 myu...@domain2.com User quota STORAGE 0 0 0 myu...@domain2.com User quota MESSAGE 0 1 0 mysql select * from PARAMS; ++++-+ | ai | MAILBOX_user_domain| quota_bytes | quota_msgs | +++-++ | 1 | myu...@domain1.com|3269 | 1 | | 2 | myu...@domain2.com| 0 | 0 | ++++-+ 2 rows in set (0.00 sec) But, the Limit's wrong. It's not picking up the global Limit from /etc/dovecot/conf.d/90-quota.conf ... -- quota_rule = *:bytes=1073741824:messages=1 ... and once a message quota Value is calculated, the Limit is set == Value, resulting in an incorrrect quota %-age of 100%. Is Limit supposed to be specified per-user? Rich
[Dovecot] Is '*:bytes= quota specification the quota 'Value', or 'Limit'?
Docs for quota configuration http://wiki2.dovecot.org/Quota/Configuration#Limit_configuration state that the 'bytes=' specification defines the quota **LIMIT** bytes: Quota limit in bytes, 0 means unlimited as used in plugin { ... quota_rule = *:bytes=1000 ... BUT, documentation for quota dict http://wiki2.dovecot.org/Quota/Dict states MySQL uses the following queries to update the quota and provides an SQL example of Dovecot decrementing the 'bytes' value, UPDATE table SET bytes=bytes-14433,messages=messages-2 ... I'm working on a current problem (http://dovecot.org/list/dovecot/2011-October/061538.html) with 'doveadm' reporting mixing up quote Value Limit. Question: Is 'bytes' supposed to contain the Value, or the Limit? Rich
[Dovecot] 'doveadm quota get' dictionary SQL query ignores specified '@domain' part of username. bad config or bug?
Hi, I'm setting up SQL quota usage in Dovecot2. I've created a MAILBOX parameter table, 'PARAMS', that contains unique user@domain pairs, with quota data. mysql select * from PARAMS; ++++-++ | ai | MAILBOX_user_domain| quota | quota_bytes | quota_msgs | ++++-++ | 1 | myu...@domain1.com| 1073741824 | 0 | 0 | | 2 | myu...@domain2.com| 10 | 0 | 0 | ++++-++ 2 rows in set (0.00 sec) I've specified dict usage for quota, /etc/dovecot/dovecot.conf !include conf.d/*.conf protocols = imap lmtp dict { quota = mysql:/etc/dovecot/dovecot-dict-sql.conf.ext } created the maps, /etc/dovecot/dovecot-dict-sql.conf.ext connect = host=/var/run/mysql/mysql.sock dbname=my_db user=my_user password=my_pass map { pattern= priv/quota/storage table = PARAMS username_field = MAILBOX_user_domain value_field= quota_bytes } map { pattern= priv/quota/messages table = PARAMS username_field = MAILBOX_user_domain value_field= quota_msgs } assigned the global values and backend, /etc/dovecot/conf.d/90-quota.conf plugin { quota = dict:User Quota::proxy::quota quota_rule = *:storage=1GB:messages=1 quota_rule2 = Trash:storage=+10%% } and specified the user iteration query /etc/dovecot/sql/virtmail-userdb-sql.cf driver = mysql connect = host=/var/run/mysql/mysql.sock dbname=my_db user=my_user password=my_pass user_query = CALL UserDBQuery('%n','%d'); iterate_query = SELECT `MAILBOX_user_domain` AS user FROM `PARAMS`; Verifying operation with with `doveadm`, I get a result from a !error query, doveadm quota get -u myu...@domain1.com Quota name TypeValue Limit % User quota STORAGE 0 1048576 0 User quota MESSAGE 0 1 0 doveadm quota get -u myu...@domain2.com Quota name TypeValue Limit % User quota STORAGE 0 1048576 0 User quota MESSAGE 0 1 0 But notice that there's no specificity by *domain*. Despite being provided the full user@domain, matched to the map, username_field = MAILBOX_user_domain the Dovecot dict query seems to ignore the domain part, and simply matches on the first of the tow identical user parts. Specifying -A doesn't help, doveadm quota get -A UsernameQuota name Type Value Limit % myu...@domain1.com User quota STORAGE 0 1048576 0 myu...@domain1.com User quota MESSAGE 0 1 0 myu...@domain2.com User quota STORAGE 0 1048576 0 myu...@domain2.com User quota MESSAGE 0 1 0 What needs to be done to get domain-specificity in the 'doveadm quota get' query? Is my configuration off, or incomplete, or is this a bug? Thanks, Rich
Re: [Dovecot] Dovecot upgrades break Blackberry instant email (BIS)
Worked perfectly! Is it something that can be disabled after a few days or is there no harm in keeping it in the config? (And congrats on your work on Dovecot Timo. Great piece of software.) On 31/08/2010 17:53, Timo Sirainen wrote: On Tue, 2010-08-31 at 17:41 +0100, interfaSys sàrl wrote: I don't find this very convenient and was wondering if there was something that could be done on the Dovecot side? imap_capability = +IDLE I'm thinking about making this default.. Assuming Blackberry people don't happen to fix it themselves soon, which would be nice but maybe not that realistic to expect. Anyway, http://dovecot.org/list/dovecot/2010-April/048147.html explains what's happening.
Re: [Dovecot] Capability problems dovecot 2.0
While I recognize that Timo has some valid points here with regard to determining capabilities before vs. after login, I definitely would consider breaking compatibility with Thunderbird to be a MAJOR, MAJOR showstopper, regardless of the reasons for doing it. -- Rich Wales / ri...@richw.org / ri...@stanford.edu Wikipedia: http://en.wikipedia.org/wiki/User:Richwales Facebook: http://www.new.facebook.com/profile.php?id=206680
Re: [Dovecot] Capability problems dovecot 2.0
I never said anything about breaking Thunderbird. Sorry if I misinterpreted your response to reg9...@yahoo.de (when he said that your proposed change would actually just break with a rather common client and change behaviour to all previous versions). -- Rich Wales / ri...@richw.org / ri...@stanford.edu Wikipedia: http://en.wikipedia.org/wiki/User:Richwales Facebook: http://www.new.facebook.com/profile.php?id=206680
[Dovecot] Maildir with LAYOUT=fs not working
I'm considering converting a Cyrus system (managing my family's e-mail) to Dovecot. I'm trying Dovecot 1.1.15 on an Ubuntu 9.04 (2.6.28-11-server) system. My production server is currently running Cyrus 2.3.14. Since I have a huge number of folders and subfolders, I need to use LAYOUT=fs. However, it's not working consistently. I tried setting up a test account in Thunderbird (2.0.0.21), and I was able to create folders under the Inbox, and they showed up as nested subdirectories under my ~/Maildir on my mail server. So far, so good. However, when I tried a home-grown Perl script (an archival scheme for my work e-mail), Dovecot wouldn't create subfolders properly; instead of nesting them (as I thought LAYOUT=fs would do), it used a flat layout. Here is a trace (generated by my Perl script) of an IMAP session. This was supposed to log in as the user stanford (the name of my archival account); create a folder named 2009 if not already present; create (again, if not already there) a 2009-05 folder inside the 2009 folder; and, finally, save a message (marked as seen) inside the 2009-05 folder. 1 LOGIN 1 OK Logged in. 2 STATUS user.stanford.2009 (MESSAGES)* STATUS user.stanford.2009 (MESSAGES 0) 2 OK Status completed. 3 STATUS user.stanford.2009.2009-05 (MESSAGES)* STATUS user.stanford.2009.2009-05 (MESSAGES 3) 3 OK Status completed. 4 APPEND user.stanford.2009.2009-05 (\Seen) {4043} + OK (message text here . . .) 4 OK [APPENDUID 1243306507 4] Append completed. 5 LOGOUT* BYE Logging out The above works perfectly when I'm talking to my Cyrus server. However, when I tried the same thing with Dovecot, I got a folder named user.stanford.2009 in the stanford account's Maildir, and then another folder named user.stanford.2009.2009-05 (again, in the Maildir -- NOT nested in the user.stanford.2009 folder) -- and the message was stored in the user.stanford.2009.2009-05 folder. I tried changing my Perl script to use INBOX instead of user.stanford -- but the result was basically the same, except I got new folders named INBOX.2009 and INBOX.2009.2009-05 directly in my archival account's Maildir. Finally, I tried omitting any prefix at all on the folder names, and I got new folders named 2009 and 2009.2009-05 -- again, directly in Maildir -- no nesting of one folder within another. I suppose I actually have two issues here -- the lack of folder nesting (even with LAYOUT=fs), and also Dovecot's failure to recognize a user.XXX. prefix on a mailbox name as designating user XXX's inbox (something that seems to work fine on Cyrus). My Cyrus server currently has over 1,600 folders and subfolders, so I absolutely can't / won't consider switching it to Dovecot unless I can get the nested filesystem layout working. Any thoughts? -- Rich Wales / ri...@richw.org / ri...@stanford.edu Wikipedia: http://en.wikipedia.org/wiki/User:Richwales Facebook: http://www.new.facebook.com/profile.php?id=206680
Re: [Dovecot] Using deliver with postfix
On Sat, Sep 20, 2008 at 05:47:26AM +0200, mouss wrote: in your case, see the Multiple UIDs section in http://wiki.dovecot.org/LDA (you need setuid...). I'm sorry, I'm still having trouble... /usr/local/libexec/dovecot/postfix/deliver -d ${USER}. Command output: /usr/local/libexec/dovecot/postfix/deliver: Permission denied #ls -la /usr/local/libexec/dovecot/postfix/ drwx-- 2 postfix postfix 512 Sep 24 16:07 ./ drwxr-xr-x 3 root wheel 512 Sep 24 16:07 ../ -r-sr-sr-x 1 root postfix 676396 Sep 24 16:07 deliver* The postfix documentation says the delivery agent is run under the recipient's ID, so I can see why there's a permissions problem. If I don't specify -d it doesn't access auth-master, so I can run it without setuid or permissions issues, but will there other problems? Thanks! Rich
Re: [Dovecot] Using deliver with postfix
Thanks for your help mouss! On Fri, Sep 19, 2008 at 10:22:40AM +0200, mouss wrote: Rich Winkel wrote: Hi, I'm trying to set up dovecot 1.1.2 and postfix 2.5.4 on freebsd 7.0. I'm getting permissions problems on auth-master and I'm not sure of the correct settings to use. In postfix's main.cf I have mailbox_command=/usr/local/libexec/dovecot/deliver -d $USER In dovecot.conf I have: socket listen { master { path = /var/run/dovecot/auth-master mode = 0660 user = dovecot group = postfix } leave the master as it was and add a client for postfix: client { path = /var/spool/postfix/private/dovecot mode = 0660 user = postfix group = postfix } I'm confused. So deliver doesn't need access to the master socket? Because it uses the master (not the client) in the default setup ... Also how does this differ in terms of permissions from my current setup? In both cases you would have group postfix rw perms on the socket. And looking at the docs, I'm doubly confused! It says mailbox_command runs with the userid of the recipient. So how is it supposed to access this socket in any case? I take it I don't want to give 666 perms to the socket ... Sorry for my ignorance ... Rich
[Dovecot] Using deliver with postfix
Hi, I'm trying to set up dovecot 1.1.2 and postfix 2.5.4 on freebsd 7.0. I'm getting permissions problems on auth-master and I'm not sure of the correct settings to use. In postfix's main.cf I have mailbox_command=/usr/local/libexec/dovecot/deliver -d $USER In dovecot.conf I have: socket listen { master { path = /var/run/dovecot/auth-master mode = 0660 user = dovecot group = postfix } ... # ls -l /var/run/dovecot/auth-master srw-rw 1 dovecot postfix 0 Sep 18 18:26 /var/run/dovecot/auth-master= In maillog I'm getting: deliver(sumbuddy): Can't connect to auth server at /var/run/dovecot//auth-master: Permission denied (I'm not sure where it's getting the // in the path either ...) Also I'm confused about whether I need the postfix options: maildrop_destination_recipient_limit=1 dovecot_destination_concurrency_limit=1 or even whether these are current options in my version of postfix (they don't appear in main.cf.default) Does deliver require such limits on concurrency or # of recipients? Thanks!! Rich
[Dovecot] Sieve fileinto a subfolder fails -- more info, possible workaround
After looking at the way Maildir represents subfolders, I changed the sieve line from fileinto Lists/NCCC; to fileinto Lists.NCCC; and now it files into the NCCC subfolder of Lists as I wanted. I'm not sure whether this is the expected behavior or just an accident that plugging that string into the file name happens to result in the right name. I haven't tried, but if it's just passing the fileinto argument along with minimal inspection, I'm afraid the answer might be use Lists/NCCC if mail is in mbox format but Lists.NCCC if mail is in Maildirs, and it certainly seems that users editing their sieve scripts shouldn't have to know that. Rich dovecot -n shows: # 1.0.10: /etc/dovecot/dovecot.conf log_timestamp: %Y-%m-%d %H:%M:%S login_dir: /var/run/dovecot/login login_executable: /usr/lib/dovecot/imap-login mail_privileged_group: mail mail_location: maildir:/arda/export/mail/%u/Maildir auth default: passdb: driver: pam userdb: driver: passwd
[Dovecot] mbox purge routine?
Can someone direct me to a unix utility for purging old messages from mbox's? It seems entourage isn't doing it. Thanks, Rich
Re: [Dovecot] Can't sync delivery mail
On Sat, Oct 27, 2007 at 07:08:55PM +0300, Timo Sirainen wrote: On Wed, 2007-10-24 at 16:27 -0500, Rich Winkel wrote: Dovecot 1.0.3 Deliver is saying this on two specific emails. Other emails to these 2 users are going through fine. Looking at the mail headers the only thing questionable I see is: From: AMS Publication Division@ams.org Is this the problem? Contents of the messages shouldn't matter. This error should never happen. Doesn't Dovecot log anything else? Could you try this patch and show me what it logs: http://hg.dovecot.org/dovecot-1.0/rev/d58f7f66faa3 It now says: Can't sync delivery mail: BUG: Unknown internal error A sample offending message (in sendmail mqueue format) is in: http://www.math.missouri.edu/~rich/dovecot/bugmail.tgz Thanks for any help! Rich
Re: [Dovecot] thunderbird and email duplication
For what it's worth I had a similar problem with deliver (thunderbird was not involved) for userids whose email aliases were mixed-case versions of the userid (Rich vs rich). It went away when I lowercased the alias. Dovecot 1.0.3. Rich
[Dovecot] deliver net_connect auth-master failed: Permission denied
Ok, I've ALMOST got this working ... I can run deliver as a user, but when I try using it as the default delivery agent from sendmail, I get deliver(userid): net_connect(/var/run/dovecot/auth-master) failed: Permission denied Does deliver run as root, as the recipient's ID, sendmail's ID or sendmail's GID? (I'm running freebsd) Or am I totally clueless ?? Here is dovecot -n: # 1.0.3: /usr/local/etc/dovecot.conf base_dir: /var/run/dovecot/ listen: localhost:996 ssl_disable: yes login_dir: /var/run/dovecot/login login_executable: /usr/local/libexec/dovecot/imap-login login_greeting_capability: yes first_valid_uid: 100 mail_extra_groups: mail mail_location: mbox:~/mail:INBOX=/var/mail/%u:INDEX=/var/spool/dovecot_indexes/%u lock_method: flock mbox_read_locks: flock mbox_write_locks: flock auth default: passdb: driver: pam userdb: driver: passwd socket: type: listen client: path: /var/run/dovecot/auth-client mode: 432 master: path: /var/run/dovecot/auth-master mode: 432 Thanks! Rich
[Dovecot] Strange error message
I apologise if this is a faq but I couldn't find it in the archives. FreeBSD math 4.11-RELEASE-p26 FreeBSD 4.11-RELEASE-p26 dovecot version 1.0.3 x86 cpu local disk (ufs) Trying to run deliver from user's .forward file. sendmail configured with smrsh, forward file says: | deliver Imap seems to work fine, but deliver says: deliver(rw): mbox read/write lock list settings are invalid. Lock ordering must be the same with both, and write locks must contain all read locks (and possibly more) #dovecot -n # 1.0.3: /usr/local/etc/dovecot.conf base_dir: /var/run/dovecot/ listen: localhost:996 ssl_disable: yes login_dir: /var/run/dovecot/login login_executable: /usr/local/libexec/dovecot/imap-login login_greeting_capability: yes first_valid_uid: 100 mail_extra_groups: mail mail_location: mbox:~/mail:INBOX=/var/mail/%u:INDEX=/var/spool/dovecot_indexes/%u lock_method: flock mbox_write_locks: flock auth default: passdb: driver: pam userdb: driver: passwd Any help would be much appreciated!! Rich
Re: [Dovecot] Bug? Expunging Symlinked Maildir w/ Lazy_expunge Enabled
Timo Sirainen wrote: On Wed, 2007-08-29 at 09:04 -0700, Rich at Whidbey Telecom wrote: Hi all, Using Dovecot 1.0.3 on RedHat Enterprise 5 (kernel 2.6.18-8.1.6.el5PAE), and NFS storage, we symlinked a Maildir folder: /mailstore/user/Maildir/.Junk - /junkstore/user/Junkmaildir Everything works fine, until we try to expunge, which produces: You really mean EXPUNGE, not DELETE command? A04 NO BUG: Unknown internal error I couldn't reproduce this myself. I can't also think of why it would work any differently with symlinks. Does it happen if you don't use acl or quota plugins? OK, we can still reproduce this error even without quota's or ACL's, but we were able to narrow it down. EXPUNGE fails only with lazy_expunge enabled, and you have symlinked a folder to a different file system: ln -s /mailstore/user/Maildir/.Junk - /junkstore/user/JunkMail When we symlink to the same filesystem, it works: ln -s /mailstore/user/Maildir/.Junk - /mailstore/user/JunkMail The /mailstore and /junkstore are separate NFS-mounted filesystems. Here is the transaction log when it fails, using Dovecot 1.0.3: == * OK System ready. a a BAD Error in IMAP command received by server. a001 LOGIN testuser testpw a001 OK Logged in. a002 SELECT Junk * FLAGS (\Answered \Flagged \Deleted \Seen \Draft $NotJunk $Junk) * OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft $NotJunk $Junk \*)] Flags permitted. * 5 EXISTS * 1 RECENT * OK [UNSEEN 1] First unseen. * OK [UIDVALIDITY 1186687991] UIDs valid * OK [UIDNEXT 3777] Predicted next UID a002 OK [READ-WRITE] Select completed. a003 FETCH 1:* (UID) * 1 FETCH (UID 3772) * 2 FETCH (UID 3773) * 3 FETCH (UID 3774) * 4 FETCH (UID 3775) * 5 FETCH (UID 3776) a003 OK Fetch completed. a004 STORE 1 +flags \Deleted * 1 FETCH (FLAGS (\Deleted $NotJunk)) a004 OK Store completed. a005 EXPUNGE a005 NO BUG: Unknown internal error a006 LOGOUT * BYE Logging out a006 OK Logout completed. == We appreciate your help! :) Rich
[Dovecot] Bug? Expunging Symlinked Maildir w/ Lazy_expunge Enabled
Hi all, Using Dovecot 1.0.3 on RedHat Enterprise 5 (kernel 2.6.18-8.1.6.el5PAE), and NFS storage, we symlinked a Maildir folder: /mailstore/user/Maildir/.Junk - /junkstore/user/Junkmaildir Everything works fine, until we try to expunge, which produces: A04 NO BUG: Unknown internal error This only happens if lazy_expunge is enabled: mail_plugins = quota imap_quota acl lazy_expunge lazy_expunge = .EXPUNGED/ .EXPUNGED/ .EXPUNGED/ Lazy_expunge works great on non-symlinked folders. We tried version 1.1 alpha2, which actually crashes in this scenario. The only fix we've found is to disable lazy_expunge. Attached is our dovecot -n config. Anyone have an idea what might be causing this or a workaround? Thanks! Rich [EMAIL PROTECTED] # 1.0.3: /shared/dovecot.conf base_dir: /var/dovecot-mail/ log_path: /var/dovecot-mail/dovecot.log protocols: imap imaps pop3 pop3s ssl_ca_file: /adminstore/exim/ssl/instantsslroot.crt ssl_cert_file: /adminstore/exim/ssl/public-mail.crt ssl_key_file: /adminstore/exim/ssl/private-mail.key disable_plaintext_auth: no shutdown_clients: no login_dir: /var/dovecot-mail//login login_executable(default): /usr/local/libexec/dovecot/imap-login login_executable(imap): /usr/local/libexec/dovecot/imap-login login_executable(pop3): /usr/local/libexec/dovecot/pop3-login login_user: exim login_greeting: System ready. login_processes_count: 32 login_max_processes_count: 400 verbose_proctitle: yes mail_location: maildir:/mailstore/%Lu/Maildir:INDEX=MEMORY mail_cache_fields: mail_cache_min_mail_count: 65536 mailbox_idle_check_interval: 10 mmap_disable: yes lock_method: dotlock maildir_stat_dirs: yes maildir_copy_with_hardlinks: yes maildir_copy_preserve_filename: yes mail_executable(default): /usr/local/libexec/dovecot/rawlog /usr/local/libexec/dovecot/imap mail_executable(imap): /usr/local/libexec/dovecot/rawlog /usr/local/libexec/dovecot/imap mail_executable(pop3): /usr/local/libexec/dovecot/pop3 mail_plugins(default): quota imap_quota acl lazy_expunge mail_plugins(imap): quota imap_quota acl lazy_expunge mail_plugins(pop3): quota mail_plugin_dir(default): /usr/local/lib/dovecot/imap mail_plugin_dir(imap): /usr/local/lib/dovecot/imap mail_plugin_dir(pop3): /usr/local/lib/dovecot/pop3 imap_client_workarounds(default): delay-newmail outlook-idle imap_client_workarounds(imap): delay-newmail outlook-idle imap_client_workarounds(pop3): outlook-idle pop3_uidl_format(default): pop3_uidl_format(imap): pop3_uidl_format(pop3): %Mf pop3_client_workarounds(default): pop3_client_workarounds(imap): pop3_client_workarounds(pop3): outlook-no-nuls oe-ns-eoh namespace: type: private separator: . inbox: yes namespace: type: private separator: . prefix: .EXPUNGED/ location: maildir:/mailstore/%u/Expunged:INDEX=MEMORY hidden: yes auth default: mechanisms: plain login passdb: driver: pam args: exim userdb: driver: ldap args: /adminstore/configs/dovecot-ldap.conf plugin: quota: maildir:storage=25:ignore=Junk acl: vfile:/adminstore/configs/dovecot-acls
Re: [Dovecot] v1.0.0 released
On Apr 13, 2007, at 5:04 AM, Timo Sirainen wrote: http://dovecot.org/releases/dovecot-1.0.0.tar.gz http://dovecot.org/releases/dovecot-1.0.0.tar.gz.sig It took almost 5 years, but it's finally ready. I'm not expecting to release v1.0.1 anytime soon, unless someone's been sitting on a major bug just waiting for v1.0 to be released. :) People wanting new features should start testing the upcoming v1.1. http://dovecot.org/nightly/ contains now snapshots from CVS HEAD. It already has tons of new features. I've been using it myself for half a year, so it should be mostly stable too. I'll write a separate mail about this later. It's fantastic!!! smime.p7s Description: S/MIME cryptographic signature
[Dovecot] Adding , S=size to new message files when using dirsize
When APPENDing new message files to an IMAP Maildir, Dovecot 1.0 rc27 can be configured to add ,S=size to the filename. That allows it to be calculated with the dirsize quota plugin (and MTA's such as Exim). However, Dovecot only seems to do that when the maildir quota plugin is specified (from quota-maildir.c): /* For newly generated filenames add ,S=size. */ storage-save_size_in_filename = TRUE; Shouldn't save_size_in_filename be included in quota-dirsize.c, since dirsize is the one that actually needs S=? Maybe I'm missing something? Here're some relevant parts of our test config: -- mail_location = maildir:/var/mail/%u/Maildir:INDEX=MEMORY maildir_copy_with_hardlinks = yes maildir_copy_preserve_filename = yes protocol imap { mail_executable = /usr/local/libexec/dovecot/rawlog /usr/local/ libexec/dovecot/imap mail_plugins = quota imap_quota imap_client_workarounds = delay-newmail outlook-idle } plugin { quota = dirsize:storage=10240 } -- Thanks! Rich smime.p7s Description: S/MIME cryptographic signature