Operating System - HP-UX
1752370 Members
5784 Online
108787 Solutions
New Discussion юеВ

IMAP working with sendmail, ultimately with exchange

 
SOLVED
Go to solution
Kevin_31
Regular Advisor

IMAP working with sendmail, ultimately with exchange

Hello, we have Exchange as our email system here, and my Hpux boxes use sendmail with default configuration except the "DS" field is set to one of our main exchange severs. Works fine.

Now I need IMAP running on a Hpux server for an Oracle product and have installed cyrus with IExpress.

Reading the documentation that comes with it, for my version of sendmail, all I should need to do is add:

For Sendmail 8.9.x and earlier, use the cyrus mailer definition in the Sendmail distribution:
define(`confLOCAL_MAILER', `cyrus')
MAILER(`cyrus')

to get IMAP playing nicely with sendmail

root@hpuxbox:/opt> what /usr/sbin/sendmail
/usr/sbin/sendmail:
version.c 8.9.3.1 (Berkeley) 05/05/2003 (PHNE_28810)

but then I just get this error when I try starting sendmail:

root@hpuxbox:/> /sbin/init.d/sendmail start
/etc/mail/sendmail.cf: line 721: unknown configuration line "define(`confLOCAL_M
AILER', `cyrus')"
/etc/mail/sendmail.cf: line 722: MAILER(`cyrus'): A= argument required
554 /etc/mail/sendmail.cf: line 721: unknown configuration line "define(`confLOC
AL_MAILER', `cyrus')"
554 /etc/mail/sendmail.cf: line 722: MAILER(`cyrus'): A= argument required

Am I putting the cyrus entry in the wrong section of the sendmail.cf file?

To be honest, I'm kinda intimidated by this configuration file, so any help would be greatly appreciated and recognized with points.

thanks,
Kevin
10 REPLIES 10
Keith Bryson
Honored Contributor

Re: IMAP working with sendmail, ultimately with exchange

Hiya Kevin

This option you are being asked to add looks like a typical sendmail.mc (macro) entry. This macro file helps you build a new sendmail.cf file and is easier than editing the sendmail.cf file directly.

See the README file in /usr/contrib/sendmail/usr/newconfig/etc/mail/cf. There are probably other good posts on the site for using sendmail macro files.

Good luck - with sendmail, you need it!

KB
Arse-cover at all costs
Bejoy C Alias
Respected Contributor

Re: IMAP working with sendmail, ultimately with exchange

Dear Kevin,
The keyword define is not a valid entry in sendmail.cf . It is a macro defenition keyword which is used in sendmail.mc file .
You may already have a sendmail.mc file with ur sendmail distribution in the directory /etc/mail normally. Edit this file and add the two entries specified there. Afterwards u need to create the sendmail.cf file from this macro file using 'm4' macro processor. copy ur current sendmail.cf file and create the new sendmail.cf file using the command 'm4 sendmail.mc > sendmail.cf' . Then try starting sendmail .
Be Always Joy ......
Keith Bryson
Honored Contributor

Re: IMAP working with sendmail, ultimately with exchange

Kevin - beware when using the m4 sendmail.mc macro to generate the sendmail.cf file. If you manually edited the sendmail.cf file in the past and haven't reflected this configuration in the mc file, they won't be included in an m4 regenerated sendmail.cf.

I suspect you have minimal configuration alterations in sendmail.cf anyway. Try comparing (using diff) with the vanilla HP sendmail.cf in /usr/newconfig/etc/mail.

Keith
Arse-cover at all costs
Kevin_31
Regular Advisor

Re: IMAP working with sendmail, ultimately with exchange

Cheers gentlemen.

I've checked my server & there's no directory called /usr/contrib/sendmail

I also searched all the disks for a sendmail.mc and nogo on that one too.

so I made a copy of my sendmail.cf and then ran the command you gave to create a new one with this cyrus macro and then:

m4 sendmail.mc > sendmail.cf.new

#cat sendmail.cf.new

MAILER(cyrus)

that's hugely different from my sendmail.cf file:

root@mybox:/etc/mail> wc -l sendmail.cf*
2183 sendmail.cf
3 sendmail.cf.new

Hmm. I think my instincts about sendmail might have been right! cheers again Keith & Bejoy.

Bejoy C Alias
Respected Contributor

Re: IMAP working with sendmail, ultimately with exchange

Dear Kevin ,
u should make a sendmail.cf file from a fully defined sendmail.mc , u cant make it from a file which only contains the MAILER(cyrus) entry . It should be a macro defenition file ( sendmail.mc ) which holds all the defenitions of ur setup . If possible get one sendmail.mc file of some other servers which is having the same sendmail version.
Be Always Joy ......
Ermin Borovac
Honored Contributor

Re: IMAP working with sendmail, ultimately with exchange

May I suggest an alternative? Internet express also includes another IMAP server (UW-IMAP), University of Washington IMAP server. You shouldn't need to make any mods to sendmail, just put entries in /etc/inetd.conf, /etc/services, run inetd -c and it should work.

/etc/inetd.conf
imap stream tcp nowait root /usr/sbin/imapd imapd

/etc/services
imap 143/tcp
Kevin_31
Regular Advisor

Re: IMAP working with sendmail, ultimately with exchange

cheers Ermin, anything to avoid sendmail macro work sounds great to me!

I've installed the UW-IMAP as you suggested. changed the inetd.conf and services, and restarted inetd (double-checked it is running) but I still am seeing signs that the IMAP server isn't okay:

$ telnet myimapserver 143
Connecting To myimapserver...
Could not open connection to the host,
on port 143: Connect failed

anyone know of anywhere you could point me to get help with this? logfiles? resource on the web?

cheers,
Kevin
Ermin Borovac
Honored Contributor
Solution

Re: IMAP working with sendmail, ultimately with exchange

Did you also modify /etc/services?

imap 143/tcp

Make sure you run 'inetd -c' again.

Any errors in /var/adm/syslog/syslog.log?
Bejoy C Alias
Respected Contributor

Re: IMAP working with sendmail, ultimately with exchange

Check whether the imap server is actually listening on port 143 using 'lsof -i tcp:143'
, check also it is listening on 127.0.0.1 only or on all of ur ips, do a 'telnet localhost 143' also.
Be Always Joy ......