On Mon, Oct 09, 2000 at 03:58:58PM +0200, Marco wrote:
> Hi,
> I wanted to change the port numbers for the mail service (using qmail), while 
>forwarding it from a firewall to the server:
> 
> ipmasqadm portfw -a -P tcp -L <fw_address> 25 -R <mailserver_address> xxxx
> ipmasqadm portfw -a -P tcp -L <fw_address> 110 -R <mailserver_address> yyyy
> 
> Is it possible to install Qmail (and possibly manage it subsequently) so that it can 
>respond to port numbers xxxx and yyyy?

You can have qmail (I presume you mean qmail-smtpd) listen to any
port you want, or any number of ports.  What port it is running on
does not affect in the least it's manageability.

> If so, what should I do?

The INSTALL document describes how to start qmail-smtpd on port 25:

  16. Set up qmail-smtpd in /etc/inetd.conf (all on one line):
            smtp stream tcp nowait qmaild /var/qmail/bin/tcp-env
            tcp-env /var/qmail/bin/qmail-smtpd

In that line, the first word 'smtp' corresponds to this line in
/etc/services:

  smtp             25/tcp    mail         #Simple Mail Transfer

If you wanted to run qmail on another port, pick an unused port
from /etc/services, for example 2525.   Create a line like this in
/etc/services:

  mysmtp            2525/tcp    #Simple Mail Transfer

Pick any name you like, as long as it's different that any of the
others.

Now, set up qmail-smtpd in /etc/inetd.conf, using this new service
you invented (all on one line):

            mysmtp stream tcp nowait qmaild /var/qmail/bin/tcp-env
            tcp-env /var/qmail/bin/qmail-smtpd

Send a HUP signal to the inetd process, and your changes will be
in place.  See services(5), inetd(8).

The author does prefer that people use his tcpserver tool, rather
than inetd.  See question 5.1 in the qmail FAQ.  In that document,
the line:

  tcpserver -u 7770 -g 2108 0 smtp /var/qmail/bin/qmail-smtpd &

is an example invokation.  Again, the 'smtp' refers to the service
entry in /etc/services, replace it with 'mysmtp', or whatever you've
come up with...

> Thank you in advance.

Good luck...

> Marco
> [EMAIL PROTECTED]

-- 
Brian 'you Bastard' Reichert            <[EMAIL PROTECTED]>
37 Crystal Ave. #303                    Daytime number: (603) 434-6842
Derry NH 03038-1713 USA                 Intel architecture: the left-hand path

Reply via email to