Re: qmail

From: Chris Wilkes (
Date: 09/27/01

Date: Thu, 27 Sep 2001 09:47:06 -0700 (PDT)
From: Chris Wilkes <>
Subject: Re: qmail
Message-ID: <>

On Thu, 27 Sep 2001, Baba Bogdan wrote:

> Hi people
> First excuse my english.
> I just installed qmail 1.03 with daemontools and ucspi-tcpd and all the
> stuff that you need for an medium tipe ISP .
> Haw do i know If after all the setups my server alows relay/spam.
> I know the relay check doesn`t work with qmail, there is
> oather way of checking if the host alows relay/spam

By default Qmail won't allow relaying. The file /etc/tcp.smtp controls
this. You'll be able to send email to the machine but it won't forward on

This means you'll have to put in something like
to let your users send mail through it. At least that's how I've done it
in the past.

Also you could run this program from a remote machine to see if your mail
server allows relaying. If the mail goes through your machine is open.
It should die with some note like "I'm sorry you're not in my rcpthosts"

If you can't get this program to work (you'll have to install the perl
module Net::SMTP) personally email me your mail server name and I'll run
it. Run it like "./" and also change the
$from and $to variables.


#!/usr/bin/perl -w

use Net::SMTP;
use strict;

my ($server, $smtp, $to, $from);

$server = shift || die "Pass me a server to test!\n";
$smtp = Net::SMTP->new($server, Debug=> 1, Port => 25);

$from = "me\";
$to = $from;


$smtp->datasend("To: $to");
$smtp->datasend("From: $from");
$smtp->datasend("Subject: Test message\n");
$smtp->datasend("A simple test message\n");