On 26-Apr-2001 Tim Legant wrote:
> On Thu, Apr 26, 2001 at 05:54:20AM +0200, Marco Calistri wrote:
[..cut] 
>> > 5. Do you actually have the following, individual machines on your
>> > network?
>> > 
>> >    a. ik5bcu.ampr.org
>> >    b. linux.ik5bcu.ampr.org
>>  
>> Yes,on "b" I have qmail and fetchmail and this is not
>> a FQDN, while "a" is LAN connected.
> 
> Ok. Let's start simple and work our way up. First, let's get your
> "official Internet address" working. I know that you have a LAN; I
> believe you mentioned before that your private IP addresses are in the
> 192.168.2.xxx block. For now, we're going to ignore them.
> 
> You say machine (b), above, has qmail. I assume that machine (b) is
> connected to the Internet and that machine (a) is connected to machine
> (b) through your local network.

True!

> One of the problems we have to solve is that your mail comes to 'tin.it'
> but that is not your home domain. When you retrieve mail using fetchmail
> and feed that mail into qmail-smtpd, you complicate things for yourself.
> 
> I recommend the following:
> 
> 1. For now, do NOT run qmail-smtpd. If you are using DJB's daemontools
>    (supervise, etc) to run qmail-smtpd, type the following as root:
> 
> cd /service/qmail-smtpd
> rm /service/qmail-smtpd
> svc -dx . ./log
 
What's the last line stays for?

>    NOTE: I don't know what you called your 'qmail-smtpd' link in /service.
>          Use that name instead of 'qmail-smtpd' if it's different.
> 
> 2. Use Charles Cazabon's getmail program
> 
> http://www.qcc.sk.ca/~charlesc/software/getmail-2.0/getmail.html
 
I already tested getmail and I commented here that it's very good,
but I need to pass internet mail to "a" machine as well,
and I do it via fetchmail/qmail.

>    instead of fetchmail. getmail won't let you send your mail to an SMTP
>    server like qmail-smtpd. It will deliver it directly into your mailbox.
>    In your situation, that's the simplest and it's what you want.
> 
> 3. In the /var/qmail/control/ directory you should have this file:
> 
> me
> 
>    For now, delete all the rest. You don't need them yet or maybe at
>    all.
 
Since I need to forward mail (hopefully filtered one of these days)
to "a" machine I have rcpthosts and smtproutes for it.

> 4. In your /var/qmail/control/me file you should have this line:
> 
> linux.ik5bcu.ampr.org

Yes that is there!

>    After you remove all the files but 'me', type the following as root:
> 
> svc -t /service/qmail-send
> 
> Now, a ps waux | grep qmail should show you something like this:
> 
> root     217  0.0  0.4   Mon01PM   0:00.26 supervise qmail-send
> qmaill   230  0.0  0.4   Mon01PM   0:02.03 /usr/local/bin/multilog t
> /var/log/qmail
> qmails  1043  0.0  0.7   Mon03PM   0:07.97 qmail-send
> root    1045  0.0  0.5   Mon03PM   0:01.71 qmail-lspawn ./Maildir/
> qmailr  1046  0.0  0.6   Mon03PM   0:00.16 qmail-rspawn
> qmailq  1047  0.0  0.6   Mon03PM   0:01.30 qmail-clean
> 
> At this point, qmail will not /accept/ any mail from the outside world but
> it is capable of /sending/ your mail to the outside world. You should be
> using getmail to retrieve all of your tin.it mail and deliver it
> directly to your mailbox with no qmail involved.

Ok,I see...

> -----
> Now you need to configure your system and your local email client (XFMail, if
> I recall
> correctly) so that you can send mail using qmail-inject and still have
> the 'From:' header look like you want.
> 
> 1. In your '.profile', the same one where you set the QMAILMFTFILE, set
>    the following variables:
> 
> export QMAILSUSER=ik5bcu
> export QMAILSHOST=tin.it
> 
> 2. In XFMail, you should be able to set your From address. Set it to
>    whatever you like, something like:
> 
> Marco Calistri <[EMAIL PROTECTED]>
> 
>    Note that this From: header and the QMAILSUSER and QMAILSHOST
>    variables that we set in client step 1 refer to completely 
>    different things. This one is the address people will reply to. The
>    one in the QMAILSxxx variables is called the "envelope sender". When
>    qmail sends mail to other SMTP servers, it tells them that the mail
>    is being sent by $QMAILSUSER@$QMAILSHOST. You don't really care, as
>    long as it's valid.

That's valid for internet world!

> 3. Finally, configure XFMail to use /var/qmail/bin/sendmail to send your
>    mail, rather than SMTP. This will end up calling qmail-inject which
>    will use the list of mailing lists in $QMAILMFTFILE to create the
>    Mail-Followup-To: header.
> 
> 
> Once this is successfully running and you can join all the lists you
> want and you can post to all the lists, we can talk about other
> questions, such as allowing all the machines on your LAN to send mail.
> 
> Good luck,
> 
> Tim

Tim I'll save this nice qmail how-to for future reference.
For the moment I'll stay a bit more on the safest (for me)
qmail-SMTP since I lost a lot of e-mails and mailing-lists
accounts working around my configuration files.
I guess that setting the variables as you explained,
I could also avoid to stop qmail-smtpd.
Wonder if would be better if I continue this topic
writing directly to your personal address because
I think to abuse to much on this list with my small problems.

-- 
Regards,: Marco Calistri <[EMAIL PROTECTED]>
gpg key available on http://www.qsl.net/ik5bcu
Xfmail 1.4.7p2 on linux RedHat 6.2 kernel-2.4.2
--
Excellent day to have a rotten day.

Reply via email to