Path: utzoo!attcan!uunet!snorkelwacker!bloom-beacon!primerd!WL1!WL9!MSHAW From: MSHAW@WL9.Prime.COM Newsgroups: comp.unix.wizards Subject: Re: sendmail config file question Message-ID: <16300003@WL9.Prime.COM> Date: 15 Aug 90 14:49:00 GMT References: <32559@sparkyfs.istc.sri.com> Lines: 71 Nf-ID: #R:sparkyfs.istc.sri.com:-3255900:WL9:16300003:000:2301 Nf-From: WL9.Prime.COM!MSHAW Aug 15 14:49:00 1990 I'm not a sendmail guru yet but here's my help anyway. To recap you put..... | We're getting ready to change our domain name, and I want to make sendmail | clever enough to handle mapping the old domain to the new one. Problem is, | we're already doing that from the domain name of about a year ago. | | Basically, right now I have: | | DDitstd.sri.com current domain name | DEistc.sri.com old domain name | | S1 | R$*<@$-.$E>$* $1<@$2.$D>$3 change domain name | R$*<@$E>$* $1<@$D>$2 change domain name | | and likewise for S2. Now, to handle both old domain names, I figured I | could use a class: | | DDerg.sri.com new domain name | CDistc.sri.com itstd.sri.com old domain names | | S1 | R$*<@$-.$=D>$* $1<@$2.$D>$3 change domain name | R$*<@$=D>$* $1<@$D>$2 change domain name | | and likewise for S2. | | But this doesn't work; the matches against the class fail. Reading the | sendmail manual, it mentions something about "token" being the unit of | a class. I'm assuming the match is failing because "istc.sri.com" and | "itstd.sri.com" are three tokens each rather than one. | | Is this right? If so, is there a way to do what I want with classes? | Unless you've done a typo' then you've defined a macro (with the D) and a class (with the C) both the macro and the class have the same name (D). I'd write something like the below instead. # # Define Macro N (New-domain-name) # and Class O (Old-domain-names) # DNerg.sri.com new domain name COistc.sri.com itstd.sri.com old domain names S1 R$*<@$-.$=O>$* $1<@$2.$O>$3 change domain name R$*<@$=O>$* $1<@$O>$2 change domain name Of course I'd also have the old domains defined in a file and then use the F command instead of C thus: FO/usr/lib/domains.old old domain names domains.old would contain.. istc.sri.com itstd.sri.com Then I'd be able to update the list of old domains without having to restart and reconfigure sendmail (just in case I moved yet again). Mike Shaw. /* The opinions expressed in this notice are my own and not those of Prime Computer Inc. */