"Crow, Ian" <[EMAIL PROTECTED]> wrote:
>I've been experimenting most of the day, but can't figure out what's wrong.
>
>Here's the setup:
>RedHat 5.2
>qmail 1.03
>Dial-up link to ISP
>
>The following domains, etc are involved:
>mydomain.demon.co.uk - A domain with a real MX record
>fake-domain.com - A domain we use locally, no DNS server, just hosts
>box.fake-domain.com - The Linux server
What does qmail-showctl say?
>There's one other thing that might be confusing when looking through the
>following. The aim is for the Linux box to send all mail (even for local
>users) out to the ISP mail relay, so that its available to them while
>they're not in the office. This is why I want mail from
>[EMAIL PROTECTED] to [EMAIL PROTECTED] to travel down
>the wire, and not simply be routed to a local mail store. I haven't done
>anything to influence this behaviour as far as I'm aware, and don't think
>this is part of my problem. I'm mentioning it just so it doesn't confuse you
>in the following.
Hmm, I'm not sure how I'd go about achieving that behavior.
>If I run qmail-inject -n I get, which looks right:
>
>Return-Path: <[EMAIL PROTECTED]>
>Date: 6 Mar 2000 17:39:07 -0000
>Message-ID: <[EMAIL PROTECTED]>
>From: "My Name" <[EMAIL PROTECTED]>
>to: [EMAIL PROTECTED]
>
>If I drop the -n to qmail-inject so that things really happen I get, which
>is not so good:
>
>Mar 6 17:37:57 box qmail: 952364277.225610 new msg 67796
>Mar 6 17:37:57 box qmail: 952364277.242731 info msg 67796: bytes 251 from
><[EMAIL PROTECTED]> qp 2284 uid 500
>Mar 6 17:37:57 box qmail: 952364277.377483 starting delivery 39: msg 67796
>to remote [EMAIL PROTECTED]
>Mar 6 17:37:57 box qmail: 952364277.378444 status: local 0/10 remote 1/20
>Mar 6 17:37:57 box qmail: 952364277.420403 delivery 39: deferral:
>Sorry,_I_couldn't_find_a_host_by_that_name._(#4.1.2)/
>Mar 6 17:37:57 box qmail: 952364277.421614 status: local 0/10 remote 0/20
>
>[...]
>noticed I changed 'any' to 'a' in the error message to make sure I'd got the
>right spot), and added some code to dump the qmail-remote command line:
>
>I then found that I could invoke qmail-remote directly and successfully send
>the message:
>
>/var/qmail/bin/qmail-remote mydomain.demon.co.uk
>[EMAIL PROTECTED] [EMAIL PROTECTED]
>This is a test
>rK194.217.242.92 accepted message.
>Remote host said: 250 OK id=12S1TY-000CyR-0Y
>
>So, I'm now completely stumped. My best guess is that something in the
>environment of the daemon processes is stopping the name lookup working.
Try replacing qmail-remote by a wrapper that logs its environment
before exec'ing the real qmail-remote.
>Two
>things make me think this: a) The error is about name resolution; b) The
>dial-up link doesn't fire up, which it does if I do the qmail-remote
>directly.
>
>Any ideas anyone?
If the above wrapper doesn't help, try a wrapper that runs
qmail-remote under strace. Compare the results from a working and
nonworking run to see where they differ.
-Dave