View Single Post
Old 05-29-2006, 08:00 AM   #1 (permalink)
istanbul
Inactive
 
istanbul's Avatar
 
Join Date: 05-29-06
Posts: 22
iTrader: 0 / 0%
Latest Blog:
None

istanbul is on the right pathistanbul is on the right pathistanbul is on the right path
Unhappy Plesk Linux server with qmail

How can I configure qmail to run on another port on my Plesk Linux server?

I made all these but not working.

In /etc/xinetd.d/ you will see this:

[root@root xinetd.d]# ls -l smpt*
-rw-r--r-- 1 root root 400 Jul 18 23:18 smtp_psa
-rw-r--r-- 1 root root 401 Jul 18 23:18 smtps_psa
[root@root xinetd.d]#


The contents of the files:


[root@root xinetd.d]# cat smtp_psa

service smtp
{
socket_type = stream
protocol = tcp
wait = no
disable = no
user = root
instances = UNLIMITED
server = /var/qmail/bin/tcp-env
server_args = /usr/sbin/rblsmtpd -r bl.spamcop.net /var/qmail/bin/relaylock /var/qmail/bin/qmail-smtpd /var/qmail/bin/smtp_auth /var/qmail/bin/true /var/qmail/bin/cmd5checkpw /var/qmail/bin/true
}

Copy one of these files to another file called something like "smtp2_psa", change the "service" name in the file, then add the service "smtp2" to /etc/services, corresponding to the NEW port number, such as 26.


[root@root xinetd.d]# cp smtp_psa smtp2_psa


Change the service line in the new file 'smtp2_psa" to be this:


service smtp2
{
socket_type = stream
protocol = tcp
wait = no
disable = no
user = root
instances = UNLIMITED
server = /var/qmail/bin/tcp-env
server_args = /usr/sbin/rblsmtpd -r bl.spamcop.net /var/qmail/bin/relaylock /var/qmail/bin/qmail-smtpd /var/qmail/bin/smtp_auth /var/qmail/bin/true /var/qmail/bin/cmd5checkpw /var/qmail/bin/true
}


Edit /etc/services with your favorite editor and add the tcp and udp lines for this service the lines should look like this:

smtp2 26/tcp mail
smtp2 26/udp mail


After this restart xinetd:


[root@root xinetd.d]# /etc/init.d/xinetd restart
Stopping xinetd: [ OK ]
Starting xinetd: [ OK ]


And you should see smtp listening on ports 25, and 26:


[root@root xinetd.d]# netstat -anp | grep xinetd
****cut****
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 6989/xinetd
tcp 0 0 0.0.0.0:26 0.0.0.0:* LISTEN 6989/xinetd
****cut****
[root@root xinetd.d]#


Make the appropriate changes if you want to run this second service on a port other than 26.
istanbul is offline   Reply With Quote
Sponsored Links
SEO Hosting by HostGator  Advertise Here  Buy Blog Links