Microsoft provides a component called Collaboration Data Objects for Microsoft Windows NT Server (CDONTS) that
allows programs to send email through Exchange Server, either through IIS or third-party applications. Sometimes, CDONTS doesn't seem to work correctly with Exchange. If Exchange is able to send other email normally, the problem almost certainly lies with how you're accessing Exchange Server through CDONTS.
- Make sure permissions on the pickup directory are correct. IIS (or whatever program is being used) needs proper permissions to write to the pickup directory. The account usually set for this is the anonymous IIS user account (IUSR_<machine_name> or IWAM_<machine_name>). The IUSR_ account is used for anonymous-user access through IIS, while IWAM_ is used for out-of-process applications. If you're having trouble with one, try enabling the other. If you're not using IIS, make sure the program or script you're running has proper authorization; it may need to be run in the context of another user account to work correctly.
- Make sure you're dropping the message in the right pickup directory. The proper directory for Exchange is EXCHSRVR\IMCDATA\PICKUP -- not any other directory named "pickup" (such as the INETPUB\MAILROOT\PICKUP directory). The pickup directory used by IIS when accessing CDONTS is specified in the IIS metabase.
- 3. If you're constructing e-mail messages "by hand" and placing them in the drop directory, make sure they're in the correct format. Programs that don't actually use CDONTS to create the mail message will run into this problem if the e-mail being created is malformed. Double-check to make sure the e-mail in question follows RFC 822, including the blank line between the headers and the body (you'd be surprised how easy it is to omit this!).
- 4. Make sure the CDONTS objects are registered. If all calls to CDONTS are failing, re-register the CDONTS component from the command line with regsvr32 cdonts.dll. (If you receive errors along the lines of "can't create object" or "library not registered," this is your culprit.)
About the author: Serdar Yegulalp is editor of the Windows Insight and a regular contributor to SearchExchange.com.
Do you have comments on this tip? Let us know.
Please let others know how useful this tip was via the rating scale below. Do you know a helpful Exchange Server, Microsoft Outlook or SharePoint tip, timesaver or workaround? Email the editors to talk about writing for SearchExchange.com.