Unix Network Admin
Domain Name Service
Top Level Domains
IP Address Name
DNS Recursive Query
DNS Caching Only
Name Servers - Quiz
Zone File Generalities
Zone File Format
Resource Record Types
nslookup Resource Records
Name Server Configuration
Configuring DNS Server
NDS Server Configuration
DNS Zone File
Preparing Zone Files
Starting name Server Process
Linux DNS Configuration
Network Information Service
How to Configure sendmail using M4 - Exercise
Use M4 and a template file to create sendmail.cf automatically.
This exercise contains a slideshow to simulate a UNIX command line and allows you to practice entering commands.
This exercise is not scored. When you have completed the exercise, click the
button to review the solution and continue with the course.
In this exercise, you will use a .mc template to configure
for a generic Solaris machine. Start the simulation below and work through the situation presented.
You are logged on as root and are in the usr/sendmail/cf/cf directory. Enter ls -l.
List the files
Notice that this directory has several files, including generic-solaris2.mc. You can customize any of these files, then run them through M4 to create a valid sendmail.cf file automatically. Now, view the contents of generic-solaris2.mc by using cat.
View the contents of the file
Type cat generic-solaris2.mc to view the contents of the file.
Normally, an .mc file has much more information, including notes on how to use it. The pertinent information here tells you that this .mc file configures sendmail for a Solaris box, is masquerading as marketing.mail.com, and uses SMTP. You are still in the
directory. The m4.cf command is in the usr/sendmail/cf/m4 directory. Type (S1)m4 ../cf/m4/cf.m4 generic-solaris2.mc > sendmail.cf to configure the sendmail.mc file.
Configure the .mc file,22,362,499,1,3,0,0
m4 ../cf/m4/cf.m4 generic-solaris2.mc > sendmail.cf
You have now created an entire sendmail.cf file. You are ready to test the sendmail file to see if it works in your particular situation. After testing the file, you can deploy it. This is the end of the simulation. Click the Exit button.