The .mc file part that adds the smart host looks like:
dnl Dialup users should uncomment and define this appropriately
dnl define(`SMART_HOST', `your.isp.mail.server')
define(`SMART_HOST', `mailserver.okstate.edu')
After that, I did a make in that directory and things
seemed to go well. After restarting sendmail, it still wanted to
resolve normally and not use the gateway.
The only way we could get it to behave as desired was to
do what one is not supposed to do and edit sendmail.cf and add
the mailserver.okstate.edu name right against the line beginning
with DS
After another restart, everything worked. What am I
failing to do as this is not the proper way to reconfigure
sendmail?
The DS line in the master file looks like
Many thanks and the handbook is very helpful but I
haven't seemed to run across anything that directly addresses
this situation.
_______________________________________________
freebsd-...@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questi...@freebsd.org"
I usually do
make
make install
make stop
make start
after the first make, you should be able to diff the created .cf file
and the actuall sendmail.cf file. It doesnt actually install it, it just
creates a temp copy.
0(cage)# make
/usr/bin/m4 -D_CF_DIR_=/usr/share/sendmail/cf/
/usr/share/sendmail/cf/m4/cf.m4 cage.simianscience.com.mc >
cage.simianscience.com.cf
0(cage)# diff -u sendmail.cf cage.simianscience.com.cf
--- sendmail.cf 2011-04-20 15:32:46.000000000 -0400
+++ cage.simianscience.com.cf 2011-04-20 15:32:52.000000000 -0400
@@ -76,6 +76,7 @@
+
##### $Id: proto.m4,v 8.741 2009/12/11 00:04:53 ca Exp $ #####
# level 10 config file format
@@ -110,7 +111,7 @@
CP.
# "Smart" relay host (may be null)
-DS
+DSsmarthost2.sentex.ca
# operators that cannot be in local usernames (i.e., network indicators)
1(cage)#
Then a full stop and start after the install should get you what you want.
---Mike
--
-------------------
Mike Tancsa, tel +1 519 651 3400
Sentex Communications, mi...@sentex.net
Providing Internet services since 1994 www.sentex.net
Cambridge, Ontario Canada http://www.tancsa.com/
On 4/20/11 2:47 PM, Martin McCormick wrote:
> The /etc/mail/sendmail.cf file very clearly tells one
> not to edit it directly so I edited the
> /etc/mail/my.name.domain.mc file as stated in documentation to
> cause this system to send all out-bound mail through a "smart host."
>
> The .mc file part that adds the smart host looks like:
>
> dnl Dialup users should uncomment and define this appropriately
> dnl define(`SMART_HOST', `your.isp.mail.server')
> define(`SMART_HOST', `mailserver.okstate.edu')
>
> After that, I did a make in that directory and things
> seemed to go well. After restarting sendmail, it still wanted to
> resolve normally and not use the gateway.
>
> The only way we could get it to behave as desired was to
> do what one is not supposed to do and edit sendmail.cf and add
> the mailserver.okstate.edu name right against the line beginning
> with DS
>
> After another restart, everything worked. What am I
> failing to do as this is not the proper way to reconfigure
> sendmail?
>
> The DS line in the master file looks like
>
> DSmailserver.okstate.edu
>
> Many thanks and the handbook is very helpful but I
> haven't seemed to run across anything that directly addresses
> this situation.
Hi Martin,
Try these commands, and the sendmail.cf will be updated from the .mc file:
<edit .mc file>
make install
make restart
Hope that helps,
Greg
- --
Greg Larkin
http://www.FreeBSD.org/ - The Power To Serve
http://www.sourcehosting.net/ - Ready. Set. Code.
http://twitter.com/sourcehosting/ - Follow me, follow you
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAk2vNisACgkQ0sRouByUApDFLQCfcnoA8rbGxi5NunLjKlnfaxSS
E7sAmweUPxSIHqkU6crW8Qjxmp8+Nmf8
=bO3y
-----END PGP SIGNATURE-----
This is a great list and everybody is very nice even to those of
us who have been running FreeBSD for many years but are trying
new things.
Greg Larkin writes:
> Try these commands, and the sendmail.cf will be updated from the .mc file:
Hey Martin, this might not be the exact answer you're looking for but
I despise sendmail but *love* FreeBSD so here are my $0.02:
1) edit your /etc/rc.conf
sendmail_enable="NO"
sendmail_submit_enable="NO"
sendmail_outbound_enable="NO"
sendmail_msp_queue_enable="NO"
postfix_enable="YES"
2) cd /usr/ports/mail/postfix
make install clean
Play close attention to all messages, remember to regenerate the
aliases with newalias and let the script modify your mailer.conf to
enable postfix and say yes.
In case you forget here is my /etc/mail/mailer.conf
# Execute the Postfix sendmail program, named /usr/local/sbin/sendmail
#
sendmail /usr/local/sbin/sendmail
send-mail /usr/local/sbin/sendmail
mailq /usr/local/sbin/sendmail
newaliases /usr/local/sbin/sendmail
then /usr/local/etc/rc.d/postfix start
Enjoy! http://www.postfix.org
There have been many requests to let us choose our favorite MTA for
the base system. It seems things are moving in that direction since
you will notice an option in the make config of the newer postfix
versions it says to install postfix in the base. Right now I would
avoid this, (other maybe other can comment more on this option) but
hopefully in the future those of use that don't like sendmail can
avoid it's use.
best,
Alejandro Imass
> There have been many requests to let us choose our favorite MTA for
> the base system. It seems things are moving in that direction since
> you will notice an option in the make config of the newer postfix
> versions it says to install postfix in the base. Right now I would
> avoid this, (other maybe other can comment more on this option) but
> hopefully in the future those of use that don't like sendmail can
> avoid it's use.
--As for the rest, it is mine.
I picked the option to install postfix in the base. It works the same as
postfix out of the base. Only one real difference that I've noted: Instead
of being in '/usr/local/sbin/' it's in '/usr/sbin/'. There are quite a few
other ports I've noticed that see postfix and assume it's in /usr/local/*,
so this can be annoying as you are installing other things. On the other
hand, every time I've run into it, it's just been a config option or so
that needed changing. You just have to be on the lookout for it: lots of
things send the occasional email, or can.
Daniel T. Staal
---------------------------------------------------------------
This email copyright the author. Unless otherwise noted, you
are expressly allowed to retransmit, quote, or otherwise use
the contents for non-commercial purposes. This copyright will
expire 5 years after the author's death, or in 30 years,
whichever is longer, unless such a period is in excess of
local copyright law.
---------------------------------------------------------------
For crying out loud, he's asking a question about sendmail configuration.
If someone asks you directions to the airport, and you hate flying, do
you point them to the railway station?
Ruben
Did you run?:
# make all install restart
That's the usual idiom after editing the .mc file. You can tell that
this has worked, because you will find the name of your smart host in
/etc/mail/sendmail.cf.
Cheers,
Matthew
--
Dr Matthew J Seaman MA, D.Phil. 7 Priory Courtyard
Flat 3
PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate
JID: mat...@infracaninophile.co.uk Kent, CT11 9PW
> On Wed, Apr 20, 2011 at 03:50:16PM -0400, Alejandro Imass typed:
> > On Wed, Apr 20, 2011 at 2:47 PM, Martin McCormick
> > <mar...@dc.cis.okstate.edu> wrote:
> > > ? ? ? ?The /etc/mail/sendmail.cf file very clearly tells one
> > > not to edit it directly so I edited the
> >
> >
> > Hey Martin, this might not be the exact answer you're looking for
> > but I despise sendmail but *love* FreeBSD so here are my $0.02:
> >
> >
> > 1) edit your /etc/rc.conf
> >
> > sendmail_enable="NO"
> > sendmail_submit_enable="NO"
> > sendmail_outbound_enable="NO"
> > sendmail_msp_queue_enable="NO"
> > postfix_enable="YES"
> >
> > 2) cd /usr/ports/mail/postfix
> > make install clean
>
> For crying out loud, he's asking a question about sendmail
> configuration. If someone asks you directions to the airport, and you
> hate flying, do you point them to the railway station?
For Christ's sake, considering how far off the beaten path so many of
these postings get, I consider that replay appropriate. In any case,
the poster did reply to the OPs question regarding Sendmail -- he told
him how to remove it from his system and install Postfix. A solution
that would permanently eliminate the Sendmail configuration problem.
--
Jerry ✌
FreeBS...@seibercom.net
Disclaimer: off-list followups get on-list replies or get ignored.
Please do not ignore the Reply-To header.
__________________________________________________________________