On 12/29/2015 11:11 AM, Jaco Lesch wrote: > Matteo > > You can use a HASH file with > "check_client_access hash:/etc/postfix/network" under > 'smtpd_recipient_restrictions, have a look at the documentation here: > http://www.postfix.org/postconf.5.html#smtpd_recipient_restrictions
While you /could/ use a check_client_access map, mynetworks is the proper place to list clients allowed to relay. The mynetworks parameter supports all the postfix table types such as hash: cdb: cidr: and *sql, so you can use whatever table type best suits your needs. Any of these table types will support (at least) hundreds of thousands of entries. See the docs for details http://www.postfix.org/postconf.5.html#mynetworks Please note that indexed mynetworks tables such as hash:, cdb: *sql support single IP lookup only, not network lookup. -- Noel Jones > > Or maybe use 'smtpd_relay_restrictions' need to read the > documentation here. > > Your /etc/postfix/network file will look like this: > 192.168.1 RELAY # This will be for the whole class-C block > 172.16 RELAY # This will be for the whole class-B block > 192.168.4.5 RELAY # For a single IP > > Of course remember to do a: > postmap -v /etc/postfix/network > to convert to a HASH file. > > Regards > > > > On 29/12/2015 17:30, Matteo Cazzador wrote: >> Hi, i need to insert many external ip (adsl) in mynetworks file, i >> need >> to give openrelay at all this ip's. >> There is a more fast solution? There is an alternative to use >> mynetworks file more fast? >> Is is possible to use hash file? >> which is teh content formato of text file to create hash networks >> table? >> >> Thanks >>