In the authldap I added LDAP_FILTER (&(objectclass=qmailuser)) This didn't seem to change my results at all. Is this the proper way of specifying the search?
Should my home dir be set to /home/vmail/davep ??? This is where the qmail dirmaker setup the Maildir for the users.
I did modify the success.c to as mentioned below. I believe that It should be logging the directory that it is trying to chdir to.
Thanks for your help. BTW I have attached the original thread at the bottom of this email.
ttyl
Keith Matthews wrote:
On Fri, 28 Feb 2003 20:11:27 -0600 (CST) Jon Nelson <[EMAIL PROTECTED]> wrote:
On Thu, 27 Feb 2003, Dave Peters wrote:
Jon,
Thanks for taking the time to look at my problem.
I recompiled and reinstalled courier-imap with the code that you suggested, however It did not give me any more information.
=-=-= Feb 27 12:25:28 hostname imapd: Connection, ip=[::ffff:68.144.21.215] Feb 27 12:25:28 hostname imapd: chdir "": No such file or directory=-=-=
I have tried with the following setup in the authldap file:
LDAP_MAILDIR mailMessageStore LDAP_HOMEDIR mailMessageStore
and in my LDAP my mailMessageStore has the value of /home/vmail/davep
Actually, it's told you quite a bit more. It's told you the variable homedir has an empty value. That's more than you knew before.
Are you using the LDAP_MAILROOT environment variable?
Having missed the earlier part of the thread I'll just deal with what I know.
I've just had the experience of setting up Courier-IMAp with LDAP and found out a few things. I was preparing a diff, but it's on a client's machine and the machine (or the link to it) went down overnight and I probably won't be able to get at it until Monday now.
I was using 1.7.0 with the version of authldap.schema supplied and OpenLDAP 2.0.27.
Issue 1. authldaprc implies that the default attribute for LDAP_HOMEDIR is 'homeDirectory'. Unfortunately if the parameter is not specified the code tries to use 'homeDir' which does not exist in the authldap schema. This is in authldaplib.c
Issue 2. If no value is specified for LDAP_MAILDIR then the code does not look anywhere in LDAP. I too had a failure trying to chdir to a null directory at this point.
Neither of these issues will apply in the case here since attributes have been specified for both parameters.
Issue 3. Contrary to the comments in authldaprc the additional filter generated if LDAP_FILTER is not specified is not (&(objectclass=CourierMailAccount)), it is '<account attribute>=<user from login>@<LDAP_BASE_DN>', assuming LDAP_BASE_DN is specified. This was a pig to discover as the additional filter does not show in even the most verbose LDAP logs and I had to add extra syslog calls to Courier to find out what was happening. Again the relevant code is in authldaplib.c.
Since the filter will probably result in no records being returned this could be the cause of the null directory name.
If the result is what was intended then the comments should be clarified.
On an unrelated issue, I was trying the 'Outbox' facility. The related comments in imapd can be taken to mean that the INBOX.Outbox directory is automatically created if the parameter is specified. This is not the case, the user must explicitly create it using the full INBOX.Outbox name.
------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ courier-users mailing list [EMAIL PROTECTED] Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users
=-=-=-=-==-=-=-=- Original Thred
Hi there,
I have read somewhere that the source could be modified to give a more
detailed error message in the syslog.
Rather then:
=-=- syslog Feb 22 12:51:15 hostname imaplogin: Connection, ip=[::ffff:68.144.21.215] Feb 22 12:51:16 hostname imaplogin: chdir: No such file or directory
It should say something like:
imaplogin: chdir TO /PATH/SOMEWHERE no such file or directory
I am not a programmer, so I don't know how to modify the source to display this information. Would anybody have any idea on how I could do this?
What section of code I could modify . . . and what that modification should look like?
This seems like it would be a great enhancement to the code, as I have read that quite a few other people have had the same problem.
Thanks
On Mon, 24 Feb 2003, Dave Peters wrote:
Hi there,
Look like im not the first person to have this problem, but I have tried everything that I can think of and I still cant solve this one.
I am working on setting up my mail server. I am using Qmail-ldap and
courier-imap.
I followed the doc at http://www.linuxwithin.com/email-howto.html
This instructed me to create a directory /home/vmail where the Maildirs
will be stored. /home
vmail
davep
Maildir
cur
new
tmp
The whole directory structure is owned by the vmail user and chmod is 700.
Qmail is working fine. All users are stored in LDAP. The mailmessagestore attribute is set to /home/vmail/davep and I do not have an attribute set for homeDirectory. POP3 is also working fine. I can send and recieve messages through this server, I cannot use an IMAP client. I just get errors at imaplogin. (see syslog)
I have tried various things:
- I have changed the LDAP_HOMEDIR to use homeDirectory, and in LDAP added homeDirectory to /home/vmail/davep same results
- I set (in LDAP) homeDirectory to /home/davep and set a symlink to Maildir -> /home/vmail/davep/Maildir Also tried chmod 777 the Maildir same results
- I tried setting LDAP_MAILDIR to an attribute that had full path
to Maildir, I also tried ./Maildir/ same results
If anyone has any insight as to what I need to do it would be GREATLY appreciated at this point.
Also, do I need to restart courier-authdeamon after everytime I change the authldaprc file? I have been just to be sure, but is it needed?
thanks
=-=- syslog Feb 22 12:51:15 hostname imaplogin: Connection, ip=[::ffff:68.144.21.215] Feb 22 12:51:16 hostname imaplogin: chdir: No such file or directory
=-=-=-
=-=- authldaprc
LDAP_SERVER localhost
LDAP_PORT 389
LDAP_BASEDN ou=people,dc=davesbox,dc=kicks-ass,dc=net
LDAP_BINDDN cn=admin,dc=davesbox,dc=kicks-ass,dc=net
LDAP_BINDPW secret LDAP_TIMEOUT 5
LDAP_MAIL uid
LDAP_GLOB_UID vmail
LDAP_GLOB_GID vmail
LDAP_HOMEDIR mailmessagestore LDAP_FULLNAME cn
LDAP_CLEARPW userPassword
LDAP_DEREF never
LDAP_TLS 0
=-=-=-
=-=- LDAP
hostname:/home/davep# /var/qmail/bin/qmail-ldaplookup -u davep -p secret
init_ldap: passwords are not compared via rebind
localdelivery: on
clustering: off
ldapobjectclass: homedirmaker: /var/qmail/bin/dirmaker
defaultDotMode: ldaponly
defaultQuota: QuotaWarning:
------
undefined
------
qldap_lookup: searching with (uid=davep)
qldap_lookup: succeeded, found:
uid: davep
qmailUID: 1010
qmailGID: 1005
accountStatus: undefined
mailMessageStore: /home/vmail/davep/
homeDirectory: (null pointer)
mailHost: (null pointer)
mail: [EMAIL PROTECTED]
mailAlternateAddress: [EMAIL PROTECTED]
[EMAIL PROTECTED]
mailQuota: no entry in the database
mailForwardingAddress: no entry in the database
deliveryProgramPath: no entry in the database
qmailDotMode: no entry in the database
deliveryMode: no entry in the database
mailReplyText: no entry in the database
userPassword: secret
qldap_lookup: password compare was successful
=-=-=-
------------------------------------------------------- This SF.net email is sponsored by: Scholarships for Techies! Can't afford IT training? All 2003 ictp students receive scholarships. Get hands-on training in Microsoft, Cisco, Sun, Linux/UNIX, and more. www.ictp.com/training/sourceforge.asp _______________________________________________ courier-users mailing list [EMAIL PROTECTED] Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users
------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ courier-users mailing list [EMAIL PROTECTED] Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users
