Date: Sat, 15 Feb 2003 02:45:44 +0200 From: Giorgos Keramidas <keramida@ceid.upatras.gr> To: "Jack L. Stone" <jackstone@sage-one.net> Cc: questions@FreeBSD.ORG Subject: Re: need some sendmail help Message-ID: <20030215004544.GB2443@gothmog.gr> In-Reply-To: <3.0.5.32.20030214171105.012a3158@sage-one.net> References: <20030214170820.GM81356@freepuppy.bellavista.cz> <20030213202116.GA17725@AndrewNg.com> <20030213204847.GA4654@gothmog.gr> <20030214013811.GA25303@AndrewNg.com> <20030214015122.GA3806@gothmog.gr> <20030214170820.GM81356@freepuppy.bellavista.cz> <3.0.5.32.20030214171105.012a3158@sage-one.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On 2003-02-14 17:11, "Jack L. Stone" <jackstone@sage-one.net> wrote: > Giorgos: As a refresher, below are the /etc/defaults/rc.conf > Unless, the /etc/rc.conf overrides, these turn on as stated. Based on the > below, what is not turned on....??? > [...] > sendmail_enable="YES" # Run the sendmail inbound daemon (YES/NO/NONE). > sendmail_submit_enable="YES" # Start a localhost-only MTA for mail submission > sendmail_outbound_enable="YES" # Dequeue stuck mail (YES/NO). > sendmail_msp_queue_enable="YES" # Dequeue stuck clientmqueue mail (YES/NO). The defaults are a bit different in STABLE vs. CURRENT (note sendmail_enable=NO). In my CURRENT installation, the defaults are: sendmail_enable="NO" # Run the sendmail inbound daemon (YES/NO). sendmail_submit_enable="YES" # Start a localhost-only MTA for mail submission sendmail_outbound_enable="YES" # Dequeue stuck mail (YES/NO). sendmail_msp_queue_enable="YES" # Dequeue stuck clientmqueue mail (YES/NO). Well, anyway... The rc.sendmail script supports the following setups: Setup 1. Sendmail accepts mail both on localhost:25 and over the network at address:25 ports. When you set sendmail_enable=YES, it overrides two rc.conf variables, sendmail_submit_enable and sendmail_outbound_enable. A sendmail process is started with /var/spool/mqueue as the queue directory, and mail accepted over a connection to port 25 is delivered as usual through the /var/spool/mqueue queue. You have to also sendmail_msp_queue_enable=YES too in this case, to allow local users to deliver mail to Sendmail over an SMTP connection to localhost:25, or use a cron job. The MSP queue runner does *NOT* listen on any port, but runs periodically dequeueing mail from /var/spool/clientmqueue and passing it to the localhost:25 daemon (or any other host that you have configured in your submit.mc config file). Alternatively, you can keep sendmail_msp_queue_enable set to NO, and use a crontab entry to dequeue mail from clientmqueue by running: sendmail -q -Ac Note that you still have to create a valid submit.cf file, even if you use cron to dequeue mail from clientmqueue. Suggested rc.conf entries: ------------------------------------------------------------- sendmail_enable=YES sendmail_msp_queue_enable=YES ------------------------------------------------------------- 2. Sendmail accepts mail only over a connection to port 25 of the localhost interface. To make this work as expected, sendmail_enable should be NO and at the same time sendmail_submit_enable should be yes. Sendmail will start, but listen only on localhost:25 and use /var/spool/mqueue for mail that is received over an smtp connection to the localhost:25 port. This is a very nice setup for dialup users who don't want their Sendmail daemon to listen on any other interface; just loopback. Delivery of outgoing mail still works like a charm, since the daemon started by sendmail_submit_enable will periodically flush /var/spool/mqueue and send mail out. An MSP queue runner or cron job is needed in this sort of setup too. See above. Suggested rc.conf entries: ------------------------------------------------------------- sendmail_enable=NO sendmail_submit_enable=YES sendmail_msp_queue_enable=YES ------------------------------------------------------------- 3. Sendmail doesn't accept any sort of mail over smtp. It only runs the queue /var/spool/mqueue periodically. This is what sendmail_outbound_enable=YES is most useful for. There are two ways to do this. One of them is with a setuid sendmail process, and one without. 3.a. Setuid-root sendmail process Follow the instructions in /etc/mail/README for changing back to a setuid-root Sendmail setup: chown root /usr/libexec/sendmail/sendmail chmod 4755 /usr/libexec/sendmail/sendmail rm /etc/mail/submit.cf 3.b. Non-setuid root Sendmail process A bit tricky; you have to manually copy sendmail.cf to submit.cf and set DeliveryMode=queue in submit.cf. This is a setup that I haven't tested a lot, but I'll have some time this weekend. Note: You can not use a clientmqueue runner with this sort of setup, because there is no daemon on localhost:25 to receive the connections from the clientmqueue runner. Suggested rc.conf entries: ------------------------------------------------------------- sendmail_enable=NO sendmail_submit_enable=NO sendmail_outbound_enable=YES sendmail_msp_queue_enable=NO ------------------------------------------------------------- Setup 4. No Sendmail daemon process at all. I haven't tested this yet, but I expect local delivery to be broken too. Suggested rc.conf entries: ------------------------------------------------------------- sendmail_enable=NO sendmail_submit_enable=NO sendmail_outbound_enable=NO sendmail_msp_queue_enable=NO ------------------------------------------------------------- - Giorgos PS: If you're about to ask ``Why isn't all this in the Handbook already?'' suffice it to say that I've been experimenting and reading about Sendmail a lot the past few weeks. I'm trying now to collect all the notes from the mess I have in my bedroom and sit my lazy *ss down to write a new Sendmail chapter for the Handbook. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030215004544.GB2443>