HostedDB - Dedicated UNIX Servers

Securing-Optimizing-RH-Linux-1_2_269
Comments and suggestions concerning this book should be mailed to gmourani@videotron.ca © Copyright 1999-2000 Gerhard Mourani and Open Network Architecture ® 269 · Set the immutable bit on “sendmail.mc” file: [root@deep /]# chattr +i /etc/sendmail.mc · Set the immutable bit on “aliases” file: [root@deep /]# chattr +i /etc/aliases · Set the immutable bit on “access” file: [root@deep /]# chattr +i /etc/mail/access · Set the immutable bit on “null.mc” file: [root@deep /]# chattr +i /etc/null.mc Further documentation For more details, there are several man pages you can read: $ man aliases (5)            - aliases file for sendmail $ man makemap (8)             - create database maps for sendmail $ man sendmail (8)             - an electronic mail transport agent $ man mailq (1)              - print the mail queue $ man newaliases (1)          - rebuild the data base for the mail aliases file $ man mailstats (8)          - display mail statistics  $ man praliases (8)              - display system mail aliases  Sendmail Administrative Tools The commands listed bellows are some that we use often in our regular use but much more exist and you must check the man page and documentation for more details and information. newaliases The purpose of the “newaliases” program utility of Sendmail is to rebuilds and update the random access database for the mail aliases file “/etc/aliases”. It must be run each time you change the content of this file in order for the change to take effect. · To update the aliases file with the “newaliases” utility, use the following command: [root@deep /]# /usr/bin/newaliases makemap The purpose of the “makemap” program utility is to create the database maps in Sendmail. The “makemap” command must be used only when you need to create a new database for file like aliases, access, or domaintable, mailertable, and virtusertable. · To run the makemap to create new database for access, use the following command: [root@deep /]# makemap hash /etc/mail/access.db < /etc/mail/access Where <hash> is the database format, makemap can handles up to three different database formats, they may be “hash”, “btree” and “dbm”. The </etc/mail/access.db> is the location and the name of the new database that will be created. The </etc/mail/access> is the location of the file from where makemap will read from the standard input file. In our example we have created a new “access.db” file with the makemap command above. To create database for other files like aliases, domaintable, mailertable, and virtusertable, you must indicate the location and name of the corresponding file in the “makemap” command. mailq