Home | Download | Documentation | Programming | FAQ | About Me
Sendmail Server Configuration

Mails sent from Local Linux machine to Remote Linux machine.Remote machine's Sendmail Server will sent the mails to outside world.
Local Linux machine:10.222.12.44
Remote Linux Server machine:12.167.43.44
Things done at remote machine (12.167.43.44)

======================================
1)First login to that destination machine as root.
ssh root@12.167.43.44

2)Then go to mail directory.
#cd /etc/mail

3)change access file -(Access file -- controls which hosts are allowed to use sendmail)
#vi /etc/mail/access
connect:12.167 RELAY

4)type make command,
#make

5)open sendmail.mc file and make sure following line is commented.Only then sendmail will listen for connections from other machines on port 25.
dnl DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl

6)creat new configuration file using following command,
#m4 sendmail.mc > sendmail.cf
7)Restart the sendmail program.
#service sendmail restart

Things done at local machine (10.222.12.44)
==========================================
1) Make sure local sendmail port 25 is not blocked & Add ip address of remote machine in /etc/hosts file #vi /etc/hosts
12.167.43.44 xxxcomdev.xxx.com xxxcomdev

2) In sendmail.mc provide your sendmail server name and make sure DAEMON_OPTIONS is commented,

#vi /etc/mail/sendmail.mc

define(`SMART_HOST',`xxxcomdev.xxx.com')

dnl DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl

3)creat new configuration file using following command,
#m4 sendmail.mc > sendmail.cf

4)Restart the sendmail program.
#service sendmail restart

Website Designed by AxisSoftSolutions.