Re: [Dovecot] Dovecot load balancing

2008-08-01 Thread Chris Laif
On Thu, Jul 31, 2008 at 3:26 PM, Thomas Hummel <[EMAIL PROTECTED]> wrote:
> On Thu, Jul 31, 2008 at 03:07:28PM +0200, Chris Laif wrote:
>
>> Do you use dovecot's delivery agent (LDA)?
>
> As I stated, no. I need the procmail filtering features.
>

As stated in the other mails, you can use procmail *and* dovecot's
LDA. then, your cache files are updated on *every* operation on a
mailbox (storing and fetching mails)

>> If you use multiple servers you can use dovecot's proxy-feature to
>> redirect the user to the correct server. You just need a database to
>> tell dovecot (and the MTA) on how to find the correct location for
>> that specific user.
>
> I see, something like adding a hostName LDAP attribute to all my users in LDAP
> dans putting this in dovecot-ldap.conf :
>

I've no experience with LDAP. If you use a SQL-db the setup is
non-trivial but doable :) For example, you've got 3 servers: If the
user hits the right server, he accesses the local mailbox. If he hits
the "wrong" server, the SQL-db finds out where his mails are stored
and proxies him to the right server.

If you add SQL-replication, you've got an nice setup without a single
point of failure (SPOF). If one server crashes, some (!) mailboxes are
unavailble but you can restore a backup to one of the live servers and
update the mail storage location in the SQL-db accordingly.

I do not like NFS that much (various NFS-problems, SPOF), therefore I
recommend the above solution.

Chris


Re: [Dovecot] Dovecot 1.1.1 killed with SIGABRT

2008-08-01 Thread Diego Liziero
On Mon, Jul 21, 2008 at 8:13 PM, Timo Sirainen <[EMAIL PROTECTED]> wrote:
> On Mon, 2008-07-21 at 18:08 +0200, Andreas M. Kirchwitz wrote:
>>  >> Jul 12 01:04:45 linux dovecot: Panic: IMAP(user2): file index-sync.c: 
>> line 39 (index_mailbox_set_recent_uid): assertion failed: 
>> (seq_range_exists(&ibox->recent_flags, uid))
>
> I think I finally managed to fix this:
> http://hg.dovecot.org/dovecot-1.1/rev/48bbaf0c3e4d

Unfortunately just got it again with dovecot 1.1.2
seq_range_exists(&ibox->recent_flags, uid) ibox->recent_flags=164556344 uid=8


Re: [Dovecot] POP3 locking

2008-08-01 Thread Charles Marcus

On 8/1/2008, Adrian Overbury ([EMAIL PROTECTED]) wrote:

Has anyone built packages for Ubuntu Dapper Drake from the latest
sources, then?  I'd appreciate being able to get my hands on thoses.


It isn't in backports? I couldn't find a web searchable version of 
ubuntu backports to search...


--

Best regards,

Charles


[Dovecot] namespaces at v1.0.15

2008-08-01 Thread Evaggelos Balaskas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hi,
i need to create a public maildir folder for virtual users so i did this:

dovecot-1.0.15:

namespace public {
prefix = public/
separator = /
location =
maildir:/var/mail/shared:INDEX=/var/mail/shared/%u/index/:CONTROL=/var/mail/shared/%u/control/
}
namespace private {
separator = /
prefix =
inbox = yes
}
umask = 007

and everything works fine,

but ... when one user reads an email from the public folder
then the status (flag read) changes to all users.

How i can fix this?
How every virtual user (same uid.gid) can have its own index (perhaps?)

Evaggelos Balaskas - Unix System Engineer
Informatics Engineer Technological Education
http://ebalaskas.gr/wk/
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIku4ZWIK+Pe9twhoRAokDAJ9u2/SjCqgabHvJFlTXlDART6+sngCghNA/
Ufl8U5GQ0mS3tVUU8idtNwY=
=BUGu
-END PGP SIGNATURE-


Re: [Dovecot] namespaces at v1.0.15

2008-08-01 Thread Charles Marcus

On 8/1/2008 7:06 AM, Evaggelos Balaskas wrote:

but ... when one user reads an email from the public folder
then the status (flag read) changes to all users.


http://wiki.dovecot.org/SharedMailboxes

Scroll down to 'Flag Sharing' and you find:

"Flag sharing

With Maildir dovecot-shared file controls if the \Seen flags are shared 
or private. If you don't have the file, they're shared. If you do have 
the file, the \Seen flag state is stored only in the user's index files. 
By making each user have their own private index files, you can make the 
\Seen flag private for the users. For example:


namespace public {
  prefix = shared.
  location = maildir:/var/mail/shared:INDEX=~/Maildir/shared
}

If you want other flags shared or you don't want \Seen flag shared, 
you'll have to modify the sources. 
src/lib-storage/index/maildir/maildir-storage.c maildir_open() has 
{mbox->ibox.box.private_flags_mask = MAIL_SEEN; Change the MAIL_SEEN to 
any flag combination you want (or zero). See src/lib-mail/mail-types.h 
for list of valid flags."


--

Best regards,

Charles


Re: [Dovecot] namespaces at v1.0.15

2008-08-01 Thread Evaggelos Balaskas
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Am i asking this because i've already read this page:

Unless you're using a single UID for all the users, you'll need to have
a dovecot-shared file in each shared maildir

so in my previous email i wrote : (same uid.gid)

and that in the public location i use something like :

maildir:/var/mail/shared:INDEX=/var/mail/shared/%u/index/:CONTROL=/var/mail/shared/%u/control/

i've used the %u variable but didnt work.

PS: Thanks although for the answer.

Charles Marcus wrote:
> On 8/1/2008 7:06 AM, Evaggelos Balaskas wrote:
>> but ... when one user reads an email from the public folder
>> then the status (flag read) changes to all users.
> 
> http://wiki.dovecot.org/SharedMailboxes
> 
> Scroll down to 'Flag Sharing' and you find:
> 
> "Flag sharing
> 
> With Maildir dovecot-shared file controls if the \Seen flags are shared
> or private. If you don't have the file, they're shared. If you do have
> the file, the \Seen flag state is stored only in the user's index files.
> By making each user have their own private index files, you can make the
> \Seen flag private for the users. For example:
> 
> namespace public {
>   prefix = shared.
>   location = maildir:/var/mail/shared:INDEX=~/Maildir/shared
> }


Evaggelos Balaskas - Unix System Engineer
Informatics Engineer Technological Education
http://ebalaskas.gr/wk/
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIkv7FWIK+Pe9twhoRAg40AJ9I5WdbEHtDgYkm9AWgCabdQBf4rQCg1LaA
vqK4Od4s1tFrC53LwKPS7NE=
=0gxP
-END PGP SIGNATURE-


[Dovecot] 1.1.2: imap crash with SIGSEGV

2008-08-01 Thread Ralf Hildebrandt
GNU gdb 6.8-debian
Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later 
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i486-linux-gnu"...
Reading symbols from /lib/i686/cmov/libdl.so.2...Reading symbols from 
/usr/lib/debug/lib/i686/cmov/libdl-2.7.so...done.
done.
Loaded symbols for /lib/i686/cmov/libdl.so.2
Reading symbols from /lib/i686/cmov/libc.so.6...Reading symbols from 
/usr/lib/debug/lib/i686/cmov/libc-2.7.so...done.
done.
Loaded symbols for /lib/i686/cmov/libc.so.6
Reading symbols from /lib/ld-linux.so.2...Reading symbols from 
/usr/lib/debug/lib/ld-2.7.so...done.
done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /usr/local/lib/dovecot/imap/lib10_quota_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib10_quota_plugin.so
Reading symbols from 
/usr/local/lib/dovecot/imap/lib11_imap_quota_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib11_imap_quota_plugin.so
Reading symbols from /usr/local/lib/dovecot/imap/lib11_trash_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib11_trash_plugin.so
Reading symbols from /usr/local/lib/dovecot/imap/lib20_fts_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib20_fts_plugin.so
Reading symbols from 
/usr/local/lib/dovecot/imap/lib20_mail_log_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib20_mail_log_plugin.so
Reading symbols from 
/usr/local/lib/dovecot/imap/lib21_fts_squat_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib21_fts_squat_plugin.so
Core was generated by `/usr/local/libexec/dovecot/imap'.
Program terminated with signal 11, Segmentation fault.
[New process 23474]
#0  mail_transaction_log_file_lock (file=0x0)
at mail-transaction-log-file.c:257
257 if (file->locked)
#0  mail_transaction_log_file_lock (file=0x0)
at mail-transaction-log-file.c:257
#1  0x080ba2fd in mail_transaction_log_lock_head (log=0x91cfd68)
at mail-transaction-log.c:419
#2  0x080ba36d in mail_transaction_log_sync_lock (log=0x91cfd68, 
file_seq_r=0xbff348a4, file_offset_r=0xbff34880)
at mail-transaction-log.c:451
#3  0x080c44bb in mail_index_fsck (index=0x91cf828) at mail-index-fsck.c:424
#4  0x080b0296 in mail_index_map (index=0x91cf828, 
type=MAIL_INDEX_SYNC_HANDLER_HEAD) at mail-index-map.c:888
#5  0x080acde3 in mail_index_try_open (index=0x91cf828) at mail-index.c:290
#6  0x080ad0a7 in mail_index_open (index=0x91cf828, flags=49, 
lock_method=FILE_LOCK_METHOD_FCNTL) at mail-index.c:338
#7  0x080a1112 in index_storage_mailbox_open (ibox=0x91d02b0)
at index-storage.c:383
#8  0x0807094b in maildir_open (storage=0x91bacc0, name=0x91bf6ee "Drafts", 
flags=0) at maildir-storage.c:448
#9  0x08070ab4 in maildir_mailbox_open (_storage=0x91bacc0, 
name=0x91bf6ee "Drafts", input=0x0, flags=0) at maildir-storage.c:512
#10 0xb7ea61ca in mail_log_mailbox_open (storage=0x91bacc0, 
name=0x91bf6ee "Drafts", input=0x0, flags=0) at mail-log-plugin.c:450
#11 0xb7eb761a in quota_mailbox_open (storage=0x91bacc0, 
name=0x91bf6ee "Drafts", input=0x0, flags=0) at quota-storage.c:366
#12 0x080a51d9 in mailbox_open (storage=0x91bacc0, name=0x91bf6ee "Drafts", 
input=0x0, flags=0) at mail-storage.c:459
#13 0x08060c89 in cmd_select_full (cmd=0x91bb5f0, readonly=false)
at cmd-select.c:32
#14 0x08060e69 in cmd_select (cmd=0x91bb5f0) at cmd-select.c:87
#15 0x0806271c in client_command_input (cmd=0x91bb5f0) at client.c:580
#16 0x080627b3 in client_command_input (cmd=0x91bb5f0) at client.c:629
#17 0x08062d6d in client_handle_input (client=)
at client.c:670
#18 0x080631ee in client_input (client=0x91bb3a8) at client.c:725
#19 0x080dd730 in io_loop_handler_run (ioloop=0x91b79b0) at ioloop-epoll.c:201
#20 0x080dcc10 in io_loop_run (ioloop=0x91b79b0) at ioloop.c:308
#21 0x0806b35a in main (argc=152894696, argv=0xbff34f34, envp=0xbff34f3c)
at main.c:293

-- 
Ralf Hildebrandt ([EMAIL PROTECTED])  [EMAIL PROTECTED]
Postfix - Einrichtung, Betrieb und Wartung   Tel. +49 (0)30-450 570-155
http://www.arschkrebs.de
"FOOT-AND-MOUTH BELIEVED TO BE FIRST VIRUS UNABLE TO SPREAD THROUGH
MICROSOFT OUTLOOK Researchers Shocked to Finally Find Virus That Email
App Doesn't Like".


Re: [Dovecot] POP3 locking

2008-08-01 Thread Ken A

Timo Sirainen wrote:

On Jul 31, 2008, at 8:10 PM, Mark Sapiro wrote:


On Wed, Jul 30, 2008 at 06:05:27PM +0200, Kai Schaetzl wrote:


but it seems to be off by default. From my dovecot.conf (1.07):

#pop3_lock_session = no

I think it should be on by default.



The problem is if you have an MUA/MDA retrieving lots of messages
over a potentially slow connection, the mailbox can remain locked
for a very long time for a read-only operation.


Or before when dialups were more common, if the modem disconnected you'd 
have to wait several minutes until the previous connection timed out.


Still very common in rural USA. We see occasional pop3 locks that last 
hours while someone on a 26.4Kbps connect downloads mail. rfc1939 says 
it should be locked. I do understand why it's not default in dovecot 
though, since Dovecot is primarily an IMAP server, and the idea of 
locking a mailbox for hours is probably a bit repulsive to the 
developer. :-)


Ken




The problem that requires doing it is basically a client problem.
Namely, some clients may get confused if in the middle of a series
of RETR commands, they get a mailbox locked reply.


This should never happen with Dovecot. But what could happen is that the 
message got expunged and the RETR would fail because of that.





--
Ken Anderson
Pacific.Net




Re: [Dovecot] Permission denied creating inbox file in /var/mail

2008-08-01 Thread Steve Ochani
Date sent:  Fri, 01 Aug 2008 00:51:28 +0300
From:   Timo Sirainen <[EMAIL PROTECTED]>
Subject:Re: [Dovecot] Permission denied creating inbox file in /var/mail
To: Steve Ochani <[EMAIL PROTECTED]>
Copies to:  Dovecot Mailing List 
Send reply to:  Dovecot Mailing List 

> On Aug 1, 2008, at 12:42 AM, Steve Ochani wrote:
> 
> > I think dovecot should use the mail_privileged_group group to also 
> > be able to create files, this was mentioned a couple of times before
> > in other posts.
> 
> v1.1 does this.


Excellent! I'll try out 1.1 on my testserver.

Thanks


-Steve O.





Re: [Dovecot] Dovecot 1.1.2? plus addressing bug in d ovecot 1.1.x?

2008-08-01 Thread amr
On Fri, 25 Jul 2008 16:01:34 -0600, Jon Fullmer <[EMAIL PROTECTED]> wrote:
> I saw the release notes to Dovecot-1.1.2. Some of the fixes imply that
> this plus addressing anomaly that I experienced with 1.1.0 (and 1.1.1)
> might have been resolved with 1.1.2. Has it been?

Plus addressing and sieve delivery to namespaces with subscriptions=no are
working perfectly for me now (thanks Timo).




[Dovecot] 1.1.2 segfaults when using passdb passwd and md5 mechanism

2008-08-01 Thread Miguel Filho
Setting passdb to passwd and enabling cram-md5 or digest-md5 makes
dovecot crash.

The documentation says that I can use md5 with passwd. I had to use
strace to figure it, because dovecot segfaults and doesn't log the
error.

Using CenOS 5.2 x86_64

Regards,

Miguel

# dovecot -n
# 1.1.2: /etc/dovecot.conf
listen: 127.0.0.1
login_dir: /var/run/dovecot/login
login_executable(default): /usr/libexec/dovecot/imap-login
login_executable(imap): /usr/libexec/dovecot/imap-login
login_executable(pop3): /usr/libexec/dovecot/pop3-login
login_greeting_capability(default): yes
login_greeting_capability(imap): yes
login_greeting_capability(pop3): no
mail_max_userip_connections(default): 5
mail_max_userip_connections(imap): 5
mail_max_userip_connections(pop3): 10
verbose_proctitle: yes
first_valid_uid: 100
mail_debug: yes
mail_executable: /mail/bin/resolv_mailbox.sh
mail_plugins(default): quota imap_quota
mail_plugins(imap): quota imap_quota
mail_plugins(pop3):
mail_plugin_dir(default): /usr/lib64/dovecot/imap
mail_plugin_dir(imap): /usr/lib64/dovecot/imap
mail_plugin_dir(pop3): /usr/lib64/dovecot/pop3
auth default:
  mechanisms: plain login gssapi digest-md5
  passdb:
driver: passwd
args: blocking=yes
  userdb:
driver: passwd
args: blocking=yes

Backtrace:

#0  0x00410337 in hash_lookup (table=0x0, key=0xa85) at hash.c:159
node = 
#1  0x00405dae in log_it (log_io=0x1736ee00,
line=0x1736f922 "DIGEST-MD5 mechanism can't be supported with
given passdbs", continues=false) at log.c:128
process = 
log_type = LOG_TYPE_FATAL
#2  0x00405e48 in log_write_pending (log_io=0x1736ee00) at log.c:51
_data_stack_cur_id = 3
line = 0x1736f920 "\001FDIGEST-MD5 mechanism can't be
supported with given passdbs"
#3  0x004060e8 in log_read (log_io=0x1736ee00) at log.c:176
data = 
line = 
size = 0
ret = 
#4  0x00406188 in log_deinit () at log.c:316
next = (struct log_io *) 0xa85
#5  0x0040335d in auth_process_destroy (p=0x1736ee60) at
auth-process.c:345
iter = 
key = (void *) 0x6
value = 
pos = 
#6  0x004034f9 in auth_process_input (process=0x1736ee60) at
auth-process.c:266
line = 
#7  0x00412df8 in io_loop_handler_run (ioloop=) at ioloop-epoll.c:201
ctx = 
event = (const struct epoll_event *) 0x1736ef0c
list = (struct io_list *) 0x17370aa0
io = (struct io_file *) 0x17370a60
tv = {tv_sec = 0, tv_usec = 970535}
events_count = 
t_id = 2
msecs = 
ret = 3
i = 1
call = 
#8  0x00411fad in io_loop_run (ioloop=0x1736eab0) at ioloop.c:308
No locals.
#9  0x00409f4f in main (argc=,
argv=) at main.c:558
_data_stack_cur_id = 0
---Type  to continue, or q  to quit---
exec_protocol = 0x0
exec_args = (const char **) 0x0
foreground = 
ask_key_pass = false
log_error = false
dump_config = false
dump_config_nondefaults = false
i = 
#10 0x2b11b72cc8b4 in __libc_start_main () from /lib64/libc.so.6
No symbol table info available.
#11 0x00402eb9 in _start ()
No symbol table info available.




-- 
http://osysadmin.blogspot.com


Re: [Dovecot] FTS/squat search indexes built when?

2008-08-01 Thread Jack Stewart



Patrick Nagel wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hi,

Timo Sirainen wrote:
| printf "1 select $mailbox\n2 search  text x93hgdgd\n3 logout\n" |
| dovecot --exec-mail imap
|
| For getting the list of mailboxes:
|
| mailboxes=`printf "1 list "" *\n" | dovecot --exec-mail imap | perl 
magic`


Ok, looks easy. But I can't find information anywhere on how to specify the
user. I tried with 'USER=username' in front of the dovecot call, and 
dovecot
then said 'Logged in as username' instead of 'Logged in as root', but a 
list
command doesn't show the mailboxes, so I think it's not accessing the 
maildir

of that user.
I guess it's because the users are not system users, and dovecot needs to
retrieve info from the LDAP directory first. But how do I tell it to do 
that?


Logging in via netcat / telnet works, but then I don't know how to 
proceed...


Thanks for your help!
Patrick.



exporting the $USER variable seems to work - i.e. 'export USER=joetest'. 
The index is updated and you get all the lovely information for reporting.


This is great. Unfortunately when I run it, existing messages for mutt 
are marked as O (or old). Thunderbird works just fine. I'm betting to 
believe these clients hate me. Please let me know of a way to get around 
this. Thanks.


---Jack





Re: [Dovecot] POP3 locking

2008-08-01 Thread Scott Silva

on 7-31-2008 11:46 PM Ed W spake the following:

Adrian Overbury wrote:
Okay, then. Has anyone built packages for Ubuntu Dapper Drake from the 
latest sources, then?  I'd appreciate being able to get my hands on 
thoses.



What's wrong with the Ubunutu  ones?  Two seconds on google gets me:
http://packages.ubuntu.com/hardy/dovecot-imapd

(I might be missing the point because I'm a gentoo user)

Ed W


Poster did ask about latest, not a few versions back.
I guess 2 seconds doesn't buy as much as it used to! ;-D


--
MailScanner is like deodorant...
You hope everybody uses it, and
you notice quickly if they don't



signature.asc
Description: OpenPGP digital signature


[Dovecot] related, but off-topic: how to allow users to change password?

2008-08-01 Thread Sahil Tandon
My dovecot is currently configured to authenticate vs. a userdb/passdb 
passwd-file that contains, for each user:

username:passhash:5000:5000::/path/to/home::userdb_mail=/path/to/maildir
   
Is it possible to let users authenticate and change their passwords?  There 
are some webmail client add-ons that allow such things if users are system 
accounts or in a MySQL/LDAP db.  Does anyone else use passdb/userdb 
passwd-files like above and have a method for allowing users to change their 
passwords from the web?

Sorry for the slightly off-topic question, but hoping another Dovecot admin 
has solved this problem.  Preference is to not to be tied to any particular 
webmail client just for this change password feature.