I have recently switched from the UW imap server to dovecot and things seem to be working nicely. One thing that I can't seem to figure out however, is how to get dovecot to show folders that are a softlink. We run SpamAssassin. Users can use both their own personal spam folder as well as a shared spam folder. For messages that everyone would consider spam, the user can simply drag the message to the shared spam folder (messages that are only "spam to them" would go into their own spam folder). sa-learn is then run nightly for each user against both the shared spam folder and their personal spam folder. The shared spam folder is simply a file that everyone has rwx access to and is softlinked to ~/mail/SharedSpam. This used to work fine with UW imap because it didn't seem to care that this was a softlink. However, apparently Dovecot DOES care because when the user resets their folder list and the user selects the folder and chooses "show", they get the error message: Could not show "SharedSpam". The server refused to show it. The folder might already be shown. I have tried editing the .subscriptions file by hand and it does cause the folder to show up, but when the user trys to use it, they get the same error. Is there a setting somewhere I'm missing? -- + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Chris Barnes AOL IM: CNBarnes chris-barnes at tamu.edu Yahoo IM: chrisnbarnes Computer Systems Manager ph: 979-845-7801 Department of Physics fax: 979-845-2590 Texas A&M University
I would suggest that mail folders *should not* follow symlinks, for a host of security reasons and performance reasons such as the ability to crash IMAP clients that WU-imapd had when following those symlinks recursively and storing the incredibly deep directory tree locally.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Am Dienstag, 8. Juni 2004 18:23 schrieb Chris Barnes:> The shared spam folder is simply a file that everyone has rwx access to > and is softlinked to ~/mail/SharedSpam. This used to work fine with UWHow about simply making a normal link instead? Untested by me, but I think it'd be worth a shot. Greetings, Gunter - -- +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ + http://aachen.uni-dsl.de/ - Der direkte Draht in's Hochschulnetz! + +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Over the centuries, mankind has tried many ways of combating the forces of evil... prayer, fasting, good works and so on. Up until Doom, no one seemed to have thought about the double-barrel shotgun. Eat leaden death, demon... -- (Terry Pratchett, alt.fan.pratchett) +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ + PGP-verschl?sselte Mails bevorzugt! + +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) iD8DBQFAxsZm0ORHvREo8l8RAtaOAJ9lCHSArmLwuFrbEq3Ey5VAcBB0bACgjdXw T1LfXDSXMEyJKpBP60aY3sg=A9ub -----END PGP SIGNATURE-----
On Tue, 2004-06-08 at 19:23, Chris Barnes wrote:> I have recently switched from the UW imap server to dovecot and things > seem to be working nicely. One thing that I can't seem to figure out > however, is how to get dovecot to show folders that are a softlink.Dovecot currently follows symlinks, so I think your problem isn't symlinks themselves but something else.> Could not show "SharedSpam". The server refused to show it. The > folder might already be shown.What do log files say? Actually I think I know. Dovecot tries to use shared index files but the first user who created them owns them. If it even had the permission to create the .imap directory. Shared access to indexes isn't really recommended with 0.99.10, so you'd probably want something like: default_mail_env = mbox:~/mail:INBOX=/var/mail/%u:INDEX=/home/%u/mail/.indexes/ (~ doesn't work after INDEX= I think) -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part URL: <http://dovecot.org/pipermail/dovecot/attachments/20040610/86a7d0b0/attachment-0001.bin>
Chris Barnes <chris-barnes at tamu.edu> wrote:> The shared spam folder is simply a file that everyone has rwx access > to and is softlinked to ~/mail/SharedSpam.The error was between the chair and the keyboard... I forgot to reset the permissions on the soft linked folder. Once done, everything worked perfectly. --? + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Chris Barnes AOL IM: CNBarnes chris-barnes at tamu.edu Yahoo IM: chrisnbarnes Computer Systems Manager ph: 979-845-7801 Department of Physics fax: 979-845-2590 Texas A&M University
-- Start of PGP signed section. ] On Tue, 2004-06-08 at 19:23, Chris Barnes wrote: ] > I have recently switched from the UW imap server to dovecot and things ] > seem to be working nicely. One thing that I can't seem to figure out ] > however, is how to get dovecot to show folders that are a softlink. ] ] Dovecot currently follows symlinks, Does dovecot still follow symlinks to work out whether something is a mail folder, if the maildir-stat-dirs.patch is installed? Should + else if (d->d_type != DT_UNKNOWN) be something like + else if (d->d_type != DT_UNKNOWN && d->d_type != DT_LNK) ___________________________________________________________________________ David Keegel <djk at cybersource.com.au> http://www.cyber.com.au/users/djk/ Cybersource P/L: Linux/Unix Systems Administration Consulting/Contracting