Sun N1 System Manager 1.2 Site Preparation Guide

Configuring the Management Server Mail Service and Account

This section provides the procedures for configuring system files on the management server can receive email event notifications from ALOM-based provisionable server. Certain management server system files are common to both the Solaris OS and the Linux OS, whereas others are specific to the operating system. The procedures in this section first address the configuration of the common files, and then address operating system specific file configuration.

The following topics are discussed:

ProcedureTo Configure the System Files and Account for the Mail Service

Steps
  1. Log in as root to the management server.

  2. Update the hosts entry in the file /etc/nsswitch.conf.

    Edit the file /etc/nsswitch.conf and ensure that the file contains the following line.

    hosts:      files dns
  3. Update the search and nameserver entries in the file /etc/resolv.conf.

    Edit the file /etc/resolv.conf and ensure that the file is configured for at least one name server. For example:


    # cat /etc/resolv.conf
    search nameserver.company.com
    nameserver name server IP address
    

    In this example, nameserver.company.com is the name of a name server that is accessible by the management server, and name server IP address is the IP address of the name server. More than one name server can be specified, and each name server must be accessible by the management server.

  4. Update the sendmail configuration SMTP IP address in the file /etc/mailsendmail.cf.

    Edit the file /etc/mailsendmail.cf and locate the SMTP line. The SMTP line should be similar to the following:

    # SMTP daemon options
     
    O DaemonPortOptions=Port=smtp,Addr=127.0.0.1, Name=MTA 

    In the DaemonPortOptions line, change 127.0.0.1 to the IP address of the management server, and then save and close the file.

  5. Configure the domains that will be accepted by the mail server in the file /etc/mail/local-host-names.

    Edit file /etc/mail/local-host-names and add the fully qualified domain name of the management server and fully qualified alias domain names. You can also add the management server IP addresses.

    For example, if your management server is assigned the following values:

    • The management server name is n1sm-manager and is assigned the IP address 10.0.5.67.

    • The management server is also assigned the alias name engineering, which is assigned IP address 10.0.5.10.

    • Your company domain name is company.com

    Your /etc/mail/local-host-names file would then contain the following entries:

    n1sm-manager.company.com
    engineering.company.com
    10.0.5.67
    10.0.5.10
  6. Create a user account, user password for the account, a user directory, and a user mail inbox on the management server.

    The user account, password, and mail inbox are used to receive event notifications sent by ALOM-architecture provisionable servers, and should be reserved for use solely by the N1 System Manager. During the configuration process, you are prompted for the email user account, password, and mail inbox. ALOM event notification email is made available for viewing on the N1 System Manager browser interface Event Log tab.

    Refer to your operating system documentations for mail account creation and configuration.

  7. Add the user account name and home directory names to the file /etc/aliases.

    Edit the file /etc/aliases and add the ALOM email account to the file. For example, if the ALOM email account name is emailuser1, you would then add the following line to the file /etc/aliases:

    emailuser1:    emailuser1
  8. Type the command newaliases to refresh the system mail aliases.

Next Steps

ProcedureTo Configure the Mail Service on a Solaris Management Server

Steps
  1. Log in as root to the management server.

  2. Add the following lines to the file /etc/inetd.conf:

    imap    stream  tcp     nowait  root    /opt/sfw/sbin/imapd imapd
    pop2    stream  tcp     nowait  root    /opt/sfw/sbin/ipop2d ipop2d
    pop3    stream  tcp     nowait  root    /opt/sfw/sbin/ipop3d ipop3d
  3. Type the command inetconv to generate the email service manifests.

    For example:


    # inetconv 
    inetconv: Notice: Service manifest for 100235/1 already generated as 
       /var/svc/manifest/network/rpc/100235_1-rpc_ticotsord.xml, skipped
    inetconv: Notice: Service manifest for tftp already generated as 
       /var/svc/manifest/network/tftp-udp6.xml, skipped
    inetconv: Notice: Service manifest for 100083/1 already generated as 
       /var/svc/manifest/network/rpc/100083_1-rpc_tcp.xml, skipped
    inetconv: Notice: Service manifest for 100068/2-5 already generated as 
       /var/svc/manifest/network/rpc/100068_2-5-rpc_udp.xml, skipped
    imap -> /var/svc/manifest/network/imap-tcp.xml
    Importing imap-tcp.xml ...Done
    pop3 -> /var/svc/manifest/network/pop3-tcp.xml
    Importing pop3-tcp.xml ...Done
  4. Restart the inetd service.

    Determine the inetd service process ID, and then restart the service using the command syntax kill -hup processid.

    For example:


    # ps -ef | grep inet
        root   410     1   0 16:12:20 ?           0:04 /usr/lib/inet/inetd start
    # kill -HUP 410
    
  5. Verify that the pop3 and imap mail services have started.

    Type the commands inetadm | grep pop3 and inetadmin | grep imap. For example:


    # inetadm |grep pop3
    enabled   online         svc:/network/pop3/tcp:default
    # inetadm |grep imap
    enabled   online         svc:/network/imap/tcp:default
  6. Type /etc/init.d/sendmail restart to restart the mail service.

Next Steps

Install and configure the N1 System Manager software on your management server as described in the Sun N1 System Manager 1.2 Installation and Configuration Guide.

ProcedureTo Configure the Mail Service on a Linux Management Server

Steps
  1. Log in as root to the management server.

  2. Configure the pop3 mail service.

    Edit the file /etc/xinetd.d/ipop3 and ensure that the file contains the following entries:

    # default: off
    # description: The POP3 service allows remote users to access their mail \
    #              using an POP3 client such as Netscape Communicator, mutt, \
    #              or fetchmail.
    service pop3
    {
            disable = no
            socket_type             = stream
            wait                    = no
            user                    = root
            server                  = /usr/sbin/ipop3d
            log_on_success  += HOST DURATION
            log_on_failure  += HOST
            instances               = 50
            cps                     = 70 30
    }
  3. Ensure that the ipop3 service has been set to run at levels 3, 4, and 5 by typing the command chkconfig --level 345 ipop3 on.

  4. Type the following commands to restart the mail service.

    Wait for the first command to complete before typing the second command.

    /etc/rc3.d/S80sendmail restart

    /etc/rc3.d/S56xinetd restart

    For example:


    [root]# /etc/rc3.d/S80sendmail restart
    Shutting down sendmail:                                [  OK  ]
    Shutting down sm-client:                               [  OK  ]
    Starting sendmail:                                     [  OK  ]
    Starting sm-client:                                    [  OK  ]
    [root]# /etc/rc3.d/S56xinetd restart
    Stopping xinetd:                                       [  OK  ]
    Starting xinetd:                                       [  OK  ]
  5. Type the following commands to verify whether the mail service has restarted.

    netstat -an |grep 110

    netstat -an |grep 25

    For example:


    [root]# netstat -an | grep 110
    tcp    0    0 0.0.0.0:110         0.0.0.0:*          LISTEN
    [root]# netstat -an | grep 25
    tcp    0    0 192.168.1.104:25    0.0.0.0:*          LISTEN
Next Steps

Install and configure the N1 System Manager software on your management server as described in the Sun N1 System Manager 1.2 Installation and Configuration Guide.