Sunday, September 6, 2009

How to change MTA on Centos5.3(RHEL based server)

Here you can see, how to change MTA qmail to any other you can set as simple sendmail or postfix, exim or qmail.

[root@hostshot ~]#ll /etc/alternatives/mta
lrwxrwxrwx 1 root root 23 Aug 31 03:39 /etc/alternatives/mta -> /var/qmail/bin/sendmail


[root@hotshot ~]# alternatives --config mta

There are 4 programs which provide 'mta'.

Selection Command
-----------------------------------------------
*+ 1 /var/qmail/bin/sendmail
2 /usr/sbin/sendmail.exim
3 /usr/sbin/sendmail.postfix
4 /usr/sbin/sendmail.sendmail

Enter to keep the current selection[+], or type selection number: 2

[root@vh115sj ~]# /etc/init.d/qmail stop
Stopping : [root@hotshot ~]# /etc/init.d/exim restart
Shutting down exim: [ OK ]
Starting exim: [ OK ]

[root@hotshot ~]# echo " for shrikant " | mail -s " for shrikant " shrikant.lokhande@betterlabs.net

;) Its done. Please comment if any issue.

0 comments: