fuller@kadsma.kodak.COM (Bill Fuller) (09/20/90)
OK you sendmail wizards, Here is the situation. I have a normal client server set up for my mail environment now. I have one 4/280 set up as the mail server, and all of the other Suns send their mail to it to be resolved. Now here is my problem: I have to hook up a DEC gateway through one of the clients, in other words any mail that comes to the main router as host::user must be sent to this other machine which is currently a client of the main mail server. So the question is: How do I set up my sendmail.cf file to handle this. I currently can send mail via DEC on the client itself, just not from anywhere else. Thanks. William H. Fuller Dial: (716)-726-2311 Senior Systems Consultant UUCP: ...!rochester!kodak!kadsma!fuller Rochester, N.Y. ARPA: fuller@kadsma.kodak.com
moore@betelgeuse.cs.utk.edu (Keith Moore) (09/20/90)
In article <1990Sep19.213407.18879@usenet@kadsma> fuller@kadsma.kodak.COM (Bill Fuller) writes: >OK you sendmail wizards, > > Here is the situation. I have a normal client server set up for my >mail environment now. I have one 4/280 set up as the mail server, and all of >the other Suns send their mail to it to be resolved. Now here is my problem: > > I have to hook up a DEC gateway through one of the clients, in other >words any mail that comes to the main router as host::user must be sent to >this other machine which is currently a client of the main mail server. > > So the question is: > > How do I set up my sendmail.cf file to handle this. I currently >can send mail via DEC on the client itself, just not from anywhere else. There are two ways to do this: the right way and the usual way. 1. The usual way to do this is to put a line in ruleset zero of every machine's sendmail.cf file that matches something like ``user@node.decnet'' and rewrites it to something like ``user%node.decnet@decnet.gateway.machine''. The gateway machine has to be able to strip off the ``@decnet.gateway.machine'' part, change the last ``%'' to an ``@'', and then deliver the mail. Or you can just have the line matching user@node.decnet call the smtp mailer right there (sometimes called ``tcp'' or ``ether'') with a line like R$*<@$+.decnet> $# tcp $@ decnet.gateway.machine $: $1@$2.decnet You do have to make sure the tcp mailer's rewrite rules don't mess you up. If they do, define a decnet-via-tcp mailer that uses its own set of (minimal) rewrite rules. 2. The right way to do this is to put all of the information in the domain name server. (You DO use the name server, don't you?) In this case, you probably want to set up a domain for all of your decnet machines with a wildcard MX record that looks something like: *.dnet.xxx.yyy. IN MX 10 decnet.gateway.machine. ...then make sure the sendmail.cf file on decnet.gateway.machine recognizes addresses of the form user@node.dnet.xxx.yyy and sends these to the decnet gateway mailer instead of the normal ether or tcp or whatever mailer. You could also define separate MX records for each of the nodes on your DECnet, especially if you don't want to define a domain just for your DECnet machines. Ideally, domains should be administrative entities that don't necessarily reflect network topology. On the other hand you may not want to have to edit the name server tables every time you add a new DECnet node. A couple of caveats: avoid using addresses like node::user or node::user@gateway.domain in Internet mail. The first form isn't even valid and the second one will break lots of mailers out there. (I've seen a few user agents core dump when given such trash). Also, do the address conversion at the gateway machine, preferably before sendmail ever sees it. If you try to make sendmail handle several different address syntaxes, it gets harder and harder to construct rewrite rules that make any sense and that work well for all of the cases that crop up. If you're using my decnet gateway, I'll be happy to send you copies of my config files, along with a description of how we set up the name server tables for our environment. (You're welcome to them even if you are using another gateway, but they won't just plug in and run in that case.) Keith Moore Internet: moore@cs.utk.edu University of Tenn. CS Dept. BITNET: moore@utkvx 107 Ayres Hall, UT Campus Telephone: +1 615 974 0822 Knoxville Tennessee 37996-1301 ``Friends don't let friends use YP (or NIS)''