[Dovecot] last login timestamp

Robert Schetterer rs at sys4.de
Mon Apr 29 19:01:33 EEST 2013


Am 29.04.2013 17:03, schrieb Peer Heinlein:
> Am 29.04.2013 16:50, schrieb Oscar A. Jara:>
>>
>> Hello, I am settiing up a dovecot (imap, pop, sieve, lda) + openldap
>> infrastructure. I need to store the timestamp of the last login of each
>> user in an attribute of its corresponding ldap object. I could not find
>> a way of doing this through configuration options so I am thinking of
>> coding this task into the dovecot-auth source code, maybe in the
>> passdb-ldap.c file. What do you recomend about this? Thanks.
> 
> It's very easy to use post-login-scripting as described on
> 
> http://wiki2.dovecot.org/PostLoginScripting
> 
> You just have to code the LDAP-updates in bash.
> 
> But: We have done this in the past, but we realized, that those many
> user-logins (~15.000 to ~20.000 active users simultaneously) had been a
> measureable impact on our LDAP. Okay, not very suprising...
> 
> We decided to use the simple way of touching ~/.lastlogin.
> 
> It should be easy to set up a second script that updates the
> LDAP-records once per night. Normally there shouldn't been a reason to
> have lastlogin updated "realtime" in LDAP many time per hour.
> 
> Peer
> 
> 
> 

doing touch method may slow down your i.e cluster filesystem, database
etc specially with high frequent logins, related how/what you need such
timestamps
you can get them from logs too, to get an idea

look

http://sys4.de/de/blog/2013/02/02/monitoring-dovecot-last-login-rsyslog/

to get an idea ,what i mean

Best Regards
MfG Robert Schetterer

-- 
[*] sys4 AG

http://sys4.de, +49 (89) 30 90 46 64
Franziskanerstraße 15, 81669 München

Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Axel von der Ohe, Marc Schiffbauer
Aufsichtsratsvorsitzender: Florian Kirstein


More information about the dovecot mailing list