Knowledgebase

May
12
Posted on 12-05-2008
Filed Under (Linux VPS Hosting) by bodhost

Please follow the steps given below to restart Sendmail after editing your configuration Files:-

#!/bin/bash

cd /etc/mail

make

newaliases

/etc/init.d/sendmail restart

It will first runs the make command, which creates a new sendmail.cf file from the sendmail.mc file and then compiles supporting configuration files in the /etc/mail directory according to the instructions in the file /etc/mail/Makefile. After thar it generates new e-mail aliases with the newaliases command, and then restarts sendmail.

To make the script executable use this command.

chmod 700 filename

You will need to run the script every time you change any of the sendmail configuration files described in the sections to follow.

The line in the script that restarts sendmail is only needed if you have made changes to the /etc/mail/sendmail.mc file, but It included it so that you don’t forget.

Note: When sendmail starts, it reads the file sendmail.cf for its configuration. sendmail.mc is a more user friendly configuration file and really is much easier to fool around with without getting burned. These sendmail.cf file is located in different directories depending on the version of RedHat you use. The /etc/sendmail.cf file is used for versions up to 7.3, and /etc/mail/sendmail.cf is used for versions 8.0 and higher and Fedora Core.

We support Sendmail on our Linux VPS Hosting packages

Comments Off    Read More   

Comments are closed.