Date: Tue, 5 Jan 2016 11:29:34 +0000 From: Matthew Seaman <m.seaman@infracaninophile.co.uk> To: freebsd-questions@freebsd.org Subject: Re: sendmail config help Message-ID: <568BA91E.20208@infracaninophile.co.uk> In-Reply-To: <201601051105.u05B56gg065179@mech-as222.men.bris.ac.uk> References: <201601051105.u05B56gg065179@mech-as222.men.bris.ac.uk>
next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --Cmd0jRDhLXCmpGxjJ0WSiwq84rv3EiR8r Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 2016/01/05 11:05, Anton Shterenlikht wrote: > The best I can get is: >=20 > 553 5.3.5 z.com. config error: mail loops back to me (MX problem?) > 554 5.3.5 Local configuration error This indicates that although the MX records in the DNS point to your machine to handle the e-mail for z.com, the machine's sendmail configuration doesn't state that it should handle the final delivery for z.com messages. You need to add z.com to the file /etc/mail/local-host-names and then bounce sendmail. What this does is add z.com to sendmail's class w -- the list of addresses which this instance of sendmail 'owns.' > My questions: >=20 > 1. Do I even need MX for this simple setup? > Some sources suggest that MX is need when > multiple domains are involved. Here I have > only a single domain on a single server, > with a single IP. Do I still need MX? No, you can get away without an MX record, but on the whole it's better to have one. Otherwise you'll need to add an A record at the zone apex for z.com pointing at your mail server. Personally, I'd name the mail server as 'smtp.z.com' and use an MX record to direct the mail to it. That's pretty standard and it will help avoid your messages getting classed as spam. > 2. Is virtual hosting relevant? > I followed this guide: >=20 > http://www.sendmail.com/sm/open_source/tips/virtual_hosting/ >=20 > and set up /etc/mail/virtusertable as: >=20 > joe@z.com joe >=20 > and made a map of it with >=20 > makemap hash virtusertable < virtusertable >=20 > Is virtusertable relevant at all? virtusertable is strictly an optional extra here. Essentially it exists so that you can receive email for an address like 'fred.bloggs@z.com' and map that only the local unix account name 'fred' for delivery. There are a bunch of other things you can do with virtusertable -- it is most useful when your sendmail instance is handling e-mail for a number of different domains[*], and you can use it to implement a 'catch-all' address, but the name mapping stuff is probably what it's most used for. See genericstable for the way to do the converse of that: send out using a full name rather than a unix userid. You shouldn't need any entries in relay-domains with this setup: if your machine is the final delivery point for email to ...@z.com then by definition you aren't relaying that anywhere else. Cheers, Matthew [*] Although my advice here is 'if you want to handle anything more complicated than a low traffic server for a single domain then ditch sendmail and use postfix instead' --Cmd0jRDhLXCmpGxjJ0WSiwq84rv3EiR8r Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQJ8BAEBCgBmBQJWi6kmXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQxOUYxNTRFQ0JGMTEyRTUwNTQ0RTNGMzAw MDUxM0YxMEUwQTlFNEU3AAoJEABRPxDgqeTnzDgP/AtsFNY7D5gOrFEOLbhs7awx D9KnslxYKvQEtPB0vGvE0y1sjyqQiLaurOOyHbLxylLO9thWLUTEraMPRU0pzC2l xhWEYmBQiw8ietj2BYm1nStiTTL7ByOT5AzMOfaIno33LJXTaPdF+FdNKYcRplNN n7jBeYIanxVCVRMf6lwPViI2hZGWt+Jbq/vhWLb0dlrSIL+xoU68b3j3QAfekIk+ RB2TvnUOZM6m3NlUGc9GGGaCpYUZYQ39bv5B6YdcYslaId+aCAYqUnQTrOCbv0xS cDezPgSFbvjxWm1nmS57+rYMZuTHOst/eF5qhAgu+00Ic2w7WowJ17Bzhl/SR0zE HjLqe2FMcH/z4Dh7r7CxDlSQFkuS6KwN6Hk/ZtUKcQYZiLxSyNXgqyGXLSbzG2WW +t4n48rGWuvWRmCmMVXEimBSFw1SLrYv9ktqr0z7rsTV6P0Ux/pqtI+R57OOSyQS U4rd4xyg8wnwTZ0eEpq61BfPDCUc9+LQZ+DKHcT7XYiO62R6rrqh/omXUHVI8iAN kq9xjUFA1LlBOekuNuouoppoIb62URiTyVHHGygUTZs9nq1Y/qxIhh/AxR4wMgau J/px195fO5BDptQkglUyCYeJ8kj9C21Dh8zt5Z9ts2EK8SSY+wILY65xT2j2sZup h+6S+AJkX385Eca9EmO/ =VK4N -----END PGP SIGNATURE----- --Cmd0jRDhLXCmpGxjJ0WSiwq84rv3EiR8r--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?568BA91E.20208>