Re: Multiple transport maps in master.cf?
- Original Message > From: Ralf Hildebrandt > To: postfix-users@postfix.org > Sent: Mon, April 4, 2011 2:12:02 PM > Subject: Re: Multiple transport maps in master.cf? > > * email builder : > > Hello, > > > > I've found that in main.cf, this works fine: > > > > transport_maps = hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 > > > > But not in master.cf (under a smtpd process definition): > > > > -o transport_maps=hash:/etc/postfix/transport1 >hash:/etc/postfix/transport2 > > smtpd doesn't use transport_maps > > > I tried with comma-delimted instead of spaces, but no dice. Is this a >syntax > > > limitation in master.cf or a syntax misunderstanding on my part? Or? > > You probably need multiple instances. Right, that's what I ended up with. Just for the sake of the mailing list archives, this thread is more or less continued in one I started with the subject "header_checks in master.cf?" on the same date. Thanks to all.
Re: Multiple transport maps in master.cf?
email builder: > > > > > Can I override default_transport? > > > > > > > > > As documented: > > > > > > > > http://www.postfix.org/postconf.5.html#default_transport > > > > > > Right, but from what I can tell (testing it), it's like transport_maps, > > > in that I can't change it willy-nilly in my smtpd process with a > > > -o line, right? Works fine if specified in main.cf, but ignored > > > if I set it in master.cf. > > > > The parameter is not documented in the smtpd(8) manpage, therefore > > you are wasting your time by setting it on the master.cf command > > line. > > > > I spend a huge amount of time keeping the documentation complete, > > and I would appreciate it if you paid attention to the result of > > this effort. > > > > If you need per-sender features, you must use a Postfix release > > that supports them. > > Understood. I hope you didn't infer that I was not thankful for > the tremendous investment you must put into creating and maintaining > such a wonderful tool. I might be a little slow to understand it > in detail (I am indeed reading documentation to the best of my > ability), but don't mistake that for lack of gratitude on my part. No offense taken. I was too harsh in my response. Wietse
Re: Multiple transport maps in master.cf?
> > > > Can I override default_transport? > > > > > > As documented: > > > > > > http://www.postfix.org/postconf.5.html#default_transport > > > > Right, but from what I can tell (testing it), it's like transport_maps, > > in that I can't change it willy-nilly in my smtpd process with a > > -o line, right? Works fine if specified in main.cf, but ignored > > if I set it in master.cf. > > The parameter is not documented in the smtpd(8) manpage, therefore > you are wasting your time by setting it on the master.cf command > line. > > I spend a huge amount of time keeping the documentation complete, > and I would appreciate it if you paid attention to the result of > this effort. > > If you need per-sender features, you must use a Postfix release > that supports them. Understood. I hope you didn't infer that I was not thankful for the tremendous investment you must put into creating and maintaining such a wonderful tool. I might be a little slow to understand it in detail (I am indeed reading documentation to the best of my ability), but don't mistake that for lack of gratitude on my part.
Re: Multiple transport maps in master.cf?
On 04/05/2011 12:09 AM, Victor Duchovni wrote: On Mon, Apr 04, 2011 at 11:51:40PM +0200, Jeroen Geilman wrote: The only Postfix service that consults the transport table is trivial-rewrite(8), which in turn is consulted by smtpd(8), cleanup(8), qmgr(8), ... with the main routing decision made in qmgr(8). Postfix parameter settings don't get recorded in the queue file as the message moves through the various stages of processing. Each service (smtpd(8), cleanup(8), qmgr(8), smtp(8), ...) has its own view of the configuration settings. I thought some services could add extra info to queue messages, such as a content_filter or smtpd proxy ? These are not main.cf parameter overrides. The access(5) FILTER action does not override the transport_maps setting in any other service. It does record transport:nexthop *value* in the queue_file that pre-empts normal transport lookups, but this is very different from changing some other service's setting the variable that defines the list of tables to consult. Oh I missed that he wanted a completely different set of tables... sounds like multi-instance time, then. The queue file containts the message envelope and body, plus a small amount of metadata that includes DSN attributes, content encoding domain, ... and sometimes a content_filter setting. There are NO main.cf parameter settings in the queue file. Didn't mean to imply that there were, thanks for the clarification. -- J.
Re: Multiple transport maps in master.cf?
On Mon, Apr 04, 2011 at 11:51:40PM +0200, Jeroen Geilman wrote: >> The only Postfix service that consults the transport table is >> trivial-rewrite(8), which in turn is consulted by smtpd(8), cleanup(8), >> qmgr(8), ... with the main routing decision made in qmgr(8). >> >> Postfix parameter settings don't get recorded in the queue file as >> the message moves through the various stages of processing. Each >> service (smtpd(8), cleanup(8), qmgr(8), smtp(8), ...) has its >> own view of the configuration settings. > > I thought some services could add extra info to queue messages, such as a > content_filter or smtpd proxy ? These are not main.cf parameter overrides. The access(5) FILTER action does not override the transport_maps setting in any other service. It does record transport:nexthop *value* in the queue_file that pre-empts normal transport lookups, but this is very different from changing some other service's setting the variable that defines the list of tables to consult. The queue file containts the message envelope and body, plus a small amount of metadata that includes DSN attributes, content encoding domain, ... and sometimes a content_filter setting. There are NO main.cf parameter settings in the queue file. -- Viktor.
Re: Multiple transport maps in master.cf?
email builder: > > > Can I override default_transport? > > > > As documented: > > > > http://www.postfix.org/postconf.5.html#default_transport > > Right, but from what I can tell (testing it), it's like transport_maps, > in that I can't change it willy-nilly in my smtpd process with a > -o line, right? Works fine if specified in main.cf, but ignored > if I set it in master.cf. The parameter is not documented in the smtpd(8) manpage, therefore you are wasting your time by setting it on the master.cf command line. I spend a huge amount of time keeping the documentation complete, and I would appreciate it if you paid attention to the result of this effort. If you need per-sender features, you must use a Postfix release that supports them. Wietse
Re: Multiple transport maps in master.cf?
On 04/04/2011 11:55 PM, email builder wrote: - Original Message From: Wietse Venema To: Postfix users Sent: Mon, April 4, 2011 2:34:00 PM Subject: Re: Multiple transport maps in master.cf? email builder: I've found that in main.cf, this works fine: > > > transport_maps = hash:/etc/postfix/transport1 >hash:/etc/postfix/transport2 But not in master.cf (under a smtpd process definition): >-o transport_maps=hash:/etc/postfix/transport1 > >hash:/etc/postfix/transport2 smtpd doesn't use transport_maps I realize that, but I had read that it was "global", which I thought meant I could override it before a message was handed to smtp. I guess that was naive. Can I override default_transport? As documented: http://www.postfix.org/postconf.5.html#default_transport Right, but from what I can tell (testing it), it's like transport_maps, in that I can't change it willy-nilly in my smtpd process with a -o line, right? Works fine if specified in main.cf, but ignored if I set it in master.cf. I think you need to think hard about what it is you're trying to achieve, since the options postfix offers are quite flexible. Try to re-state the problem, and see if it is solvable with the provided toolset. It usually is. -- J.
Re: Multiple transport maps in master.cf?
- Original Message > From: Wietse Venema > To: Postfix users > Sent: Mon, April 4, 2011 2:34:00 PM > Subject: Re: Multiple transport maps in master.cf? > > email builder: > > > > > I've found that in main.cf, this works fine: > > > > > > > > > > > > > transport_maps = hash:/etc/postfix/transport1 > > >hash:/etc/postfix/transport2 > > > > > > > > > > But not in master.cf (under a smtpd process definition): > > > > > > > > > > -o transport_maps=hash:/etc/postfix/transport1 > > > >hash:/etc/postfix/transport2 > > > > > > > > smtpd doesn't use transport_maps > > > > > > I realize that, but I had read that it was "global", which I thought >meant I > > > > could override it before a message was handed to smtp. I guess that > > > was > > > >naive. > > > > Can I override default_transport? > > As documented: > > http://www.postfix.org/postconf.5.html#default_transport Right, but from what I can tell (testing it), it's like transport_maps, in that I can't change it willy-nilly in my smtpd process with a -o line, right? Works fine if specified in main.cf, but ignored if I set it in master.cf.
Re: Multiple transport maps in master.cf?
On 04/04/2011 11:26 PM, Victor Duchovni wrote: On Mon, Apr 04, 2011 at 02:02:17PM -0700, email builder wrote: Hello, I've found that in main.cf, this works fine: transport_maps = hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 But not in master.cf (under a smtpd process definition): -o transport_maps=hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 The only Postfix service that consults the transport table is trivial-rewrite(8), which in turn is consulted by smtpd(8), cleanup(8), qmgr(8), ... with the main routing decision made in qmgr(8). Postfix parameter settings don't get recorded in the queue file as the message moves through the various stages of processing. Each service (smtpd(8), cleanup(8), qmgr(8), smtp(8), ...) has its own view of the configuration settings. I thought some services could add extra info to queue messages, such as a content_filter or smtpd proxy ? This needs to include the last-previous hop it was supposed to go to before hitting either of the above, so it can continue there when it returns from external processing, i.e. no extra lookup for the transport route is done after returning from a content_filter - that was already set in cleanup. -- J.
Re: Multiple transport maps in master.cf?
email builder: > > > > I've found that in main.cf, this works fine: > > > > > > > > > > transport_maps = hash:/etc/postfix/transport1 > >hash:/etc/postfix/transport2 > > > > > > > > But not in master.cf (under a smtpd process definition): > > > > > > > > -o transport_maps=hash:/etc/postfix/transport1 > > >hash:/etc/postfix/transport2 > > > > > > smtpd doesn't use transport_maps > > > > I realize that, but I had read that it was "global", which I thought meant > > I > > could override it before a message was handed to smtp. I guess that was > >naive. > > Can I override default_transport? As documented: http://www.postfix.org/postconf.5.html#default_transport Wietse
Re: Multiple transport maps in master.cf?
- Original Message > From: email builder > To: postfix-users@postfix.org > Sent: Mon, April 4, 2011 2:18:01 PM > Subject: Re: Multiple transport maps in master.cf? > > > > I've found that in main.cf, this works fine: > > > > > > > transport_maps = hash:/etc/postfix/transport1 >hash:/etc/postfix/transport2 > > > > > > But not in master.cf (under a smtpd process definition): > > > > > > -o transport_maps=hash:/etc/postfix/transport1 > >hash:/etc/postfix/transport2 > > > > smtpd doesn't use transport_maps > > I realize that, but I had read that it was "global", which I thought meant I > could override it before a message was handed to smtp. I guess that was >naive. Can I override default_transport?
Re: Multiple transport maps in master.cf?
On Mon, Apr 04, 2011 at 02:02:17PM -0700, email builder wrote: > Hello, > > I've found that in main.cf, this works fine: > > transport_maps = hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 > > But not in master.cf (under a smtpd process definition): > > -o transport_maps=hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 The only Postfix service that consults the transport table is trivial-rewrite(8), which in turn is consulted by smtpd(8), cleanup(8), qmgr(8), ... with the main routing decision made in qmgr(8). Postfix parameter settings don't get recorded in the queue file as the message moves through the various stages of processing. Each service (smtpd(8), cleanup(8), qmgr(8), smtp(8), ...) has its own view of the configuration settings. -- Viktor.
Re: Multiple transport maps in master.cf?
> > I've found that in main.cf, this works fine: > > > > transport_maps = hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 > > > > But not in master.cf (under a smtpd process definition): > > > > -o transport_maps=hash:/etc/postfix/transport1 >hash:/etc/postfix/transport2 > > smtpd doesn't use transport_maps I realize that, but I had read that it was "global", which I thought meant I could override it before a message was handed to smtp. I guess that was naive. > > I tried with comma-delimted instead of spaces, but no dice. Is this a >syntax > > > limitation in master.cf or a syntax misunderstanding on my part? Or? > > You probably need multiple instances. Been trying to figure out anything but. But yeah...
Re: Multiple transport maps in master.cf?
> I've found that in main.cf, this works fine: > > transport_maps = hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 > > But not in master.cf (under a smtpd process definition): > > -o transport_maps=hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 > > Postfix complains: > > fatal: unexpected command-line argument: hash:/etc/postfix/transport2 > > I tried with comma-delimted instead of spaces, but no dice. Is this a > syntax > limitation in master.cf or a syntax misunderstanding on my part? Or? Er, with more testing, it looks like I can't even override transport_maps in master.cf at all(?). I have a run-of-the-mill transport map in main.cf, and in master.cf, I was hoping to override it when it gets back from content filtering: 127.0.0.1:10024 inet n - n - - smtpd -o content_filter= -o receive_override_options=no_unknown_recipient_checks,no_header_body_checks -o smtpd_recipient_restrictions=permit_mynetworks,reject -o mynetworks=127.0.0.0/8 -o smtpd_authorized_xforward_hosts=127.0.0.0/8 -o transport_maps=hash:/etc/postfix/transport2 So transport_maps is static, un-mutable?
Re: Multiple transport maps in master.cf?
* email builder : > Hello, > > I've found that in main.cf, this works fine: > > transport_maps = hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 > > But not in master.cf (under a smtpd process definition): > > -o transport_maps=hash:/etc/postfix/transport1 hash:/etc/postfix/transport2 smtpd doesn't use transport_maps > I tried with comma-delimted instead of spaces, but no dice. Is this a syntax > limitation in master.cf or a syntax misunderstanding on my part? Or? You probably need multiple instances. -- Ralf Hildebrandt Geschäftsbereich IT | Abteilung Netzwerk Charité - Universitätsmedizin Berlin Campus Benjamin Franklin Hindenburgdamm 30 | D-12203 Berlin Tel. +49 30 450 570 155 | Fax: +49 30 450 570 962 ralf.hildebra...@charite.de | http://www.charite.de