How to Configure SMTP Mail Server should accessible from Remote Host and Local Host

Normally SMTP mail configuration is accessible only by the local host 127.0.0.1
By edit the SMTP configuration file /etc/mal/sendmail.mc we can change it as mail server access in local host and remote host.Start service using chkconfig Linux command
Change the configuration file.Restart the service and Check the status
[root@rhel5 ~]# chkconfig sendmail on
Edit the file /etc/mail/sendmail.mc
Go to the line 116

DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl
Disable this line by through adding dnl # command to the pervious of these lines.
dnl #DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl
[root@rhel5 ~]# service sendmail restart
Shutting down sm-client: [ OK ]
Shutting down sendmail: [ OK ]
Starting sendmail: [ OK ]
Starting sm-client: [ OK ]
Check the status by using netstat Linux command using –tulpn option
[root@rhel5 ~]# netstat -tulpn | grep sendmail*
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 4772/send
tcp is enable state at 0.0.0.0 It means send mail should accessible from remote login

Post a Comment

0 Comments