On May 14, 2008, at 11:52 PM, Roy McMorran wrote:
There must be some sort of race condition happening here with
automount. I modified the code in mail-process.c to repeat the
chdir (until CHDIR_TIMEOUT) until it succeeds, and it usually
succeeds on the 2nd try.
But it never succeeds on first try?
Eg (I've added some additional logging for debug):
May 14 16:21:04 testbed dovecot: [ID 667285 mail.info] try 0 of
chdir(/home/adent) May 14 16:21:04 testbed dovecot: [ID 107833 mail.info] imap-login:
Login: user=<adent>, method=PLAIN, rip=xxx.xxx.xxx.242,
lip=xxx.xxx.xxx.242, secured May 14 16:21:04 testbed dovecot: [ID 791996 mail.info] chdir
returned -1 with errno 2 May 14 16:21:05 testbed dovecot: [ID 667285 mail.info] try 1 of
chdir(/home/adent) May 14 16:21:05 testbed dovecot: [ID 791996 mail.info] chdir
returned 0 May 14 16:21:05 testbed dovecot: [ID 107833 mail.info] IMAP(adent):
Disconnected: Logged out bytes=23/104I still have no idea why this is happening. A simple standalone C
program with the alarm/setegid/seteuid/chdir bits (excerpted from
the original mail-process.c ) works just fine.
If you enable more verbosity on automountd (-v -T?) does it correctly
log all the chdir attempts?
Anyway I've really no idea why it wouldn't work. Maybe try asking in
some Solaris forums/lists if they can think of some reason.