Gentoo Archives: gentoo-user

From: Dan Farrell <dan@×××××××××.cx>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] POSTFIX mail hub configuration
Date: Sat, 24 Mar 2007 16:10:45
Message-Id: 20070324110114.33c66969@pascal.spore.ath.cx
In Reply to: Re: [gentoo-user] POSTFIX mail hub configuration by Neal McConachie
1 On Mon, 19 Mar 2007 20:41:54 -0600
2 Neal McConachie <McConachieNeal@××××.com> wrote:
3
4 > 1) mydestination =
5 > - change it to include all the other hosts on your local network
6 > that you want to accept mail for.
7 > ex: mydestination = $mydomain, localhost.$mydomain,
8 > mail.$mydomain, davey.$mydomain, foo.$mydomain
9
10 > Now, that's all well and good, but it also has to know what an
11 > acceptable <user>@*.spore.cth.cx is.
12 >
13 > 2) local_recipient_maps =
14 I chose not to change that, the main.cf comments seemed to suggest it
15 made things more difficult.
16 > Once those things are done, any external email that's addressed to any
17 > of your machines should be nicely deposited on your mailserver.
18 That's working very well, thank you.
19 > The next thing to consider is mail that gets sent internally. For
20 > that, each of the machines on your network should use mail.$mydomain
21 > as their relay host. For this to work, a) the mailserver has to be
22 > willing to relay their mail, and b) they need to know that they
23 > should relay mail to the mailserver.
24 >
25 > 3a)(on the mailserver) mynetworks=
26 > - this should be set to allow your local network to relay mail
27 > through the mailserver. It looks like you've set it up already.
28 >
29 > 3b)(on each machine) relayhost=
30 > - here, I'm assuming that you're using postfix to send mail on
31 > each of your hosts. You'll want to put in mail.$mydomain as your
32 > relay host.
33 >
34 > Oh, and actually, you also need:
35 > mydestination=<blank> on each local machine - this is assuming you
36 > want all logs and such going to the mailserver too - I'm not sure if
37 > that's what you want or not... You could play around with this by
38 > allowing localhost as a destination on each machine, and specifying
39 > root@localhost as the log email destination, for example.
40 I tried that, but unfortunately the mails then bounced back and forth
41 indefinitely. The best I could do was put the right address in
42 ~/.forward
43 > Hope that helps,
44 > - nkm
45 At least external mail is routed correctly ; ) In one sense, if I
46 address mail to a host that doesn't accept mail, I guess it's my
47 fault.
48
49 Thanks for the advice.
50 --
51 gentoo-user@g.o mailing list