Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

System Administration Guide: Network Services
Previous Next

Administering the Queue Directories

This section describes some helpful tasks for queue administration. For information about the client-only queue, refer to submit.cf Configuration File From Version 8.12 of sendmail. For other related information, you can refer to Additional Queue Features From Version 8.12 of sendmail.

Refer to the following:

How to Display the Contents of the Mail Queue, /var/spool/mqueue

  • Show how many messages are in the queue and how fast they are being cleared from the queue.

    Type the following:

    # /usr/bin/mailq | more

    This command provides the following information.

    • The queue IDs

    • The size of the message

    • The date that the message entered the queue

    • The message status

    • The sender and the recipients

    Additionally, this command now checks for the authorization attribute, solaris.admin.mail.mailq. If the check is successful, the equivalent of specifying the -bp flag with sendmail is executed. If the check fails, an error message is printed. By default, this authorization attribute is enabled for all users. The authorization attribute can be disabled by modifying the user entry in prof_attr. For more information, refer to the man pages for prof_attr(4) and mailq(1).

How to Force Mail Queue Processing in the Mail Queue, /var/spool/mqueue

Use this procedure, for example, to process messages to a system that was previously unable to receive messages.

  1. Become superuser or assume an equivalent role.

    Roles contain authorizations and privileged commands. For more information about roles, see Configuring RBAC (Task Map) in System Administration Guide: Security Services. To configure a role with the Primary Administrator profile, see Chapter 2, Working With the Solaris Management Console (Tasks), in System Administration Guide: Basic Administration.

  2. Force queue processing and display the progress of the jobs as the queue is cleared.
    # /usr/lib/sendmail -q -v 

How to Run a Subset of the Mail Queue, /var/spool/mqueue

Use this procedure, for example, to force a substring of an address, such as a host name, to be processed. Also, use this procedure to force a particular message from the queue.

  1. Become superuser or assume an equivalent role.

    Roles contain authorizations and privileged commands. For more information about roles, see Configuring RBAC (Task Map) in System Administration Guide: Security Services. To configure a role with the Primary Administrator profile, see Chapter 2, Working With the Solaris Management Console (Tasks), in System Administration Guide: Basic Administration.

  2. Run a subset of the mail queue at any time with -qRstring.
    # /usr/lib/sendmail -qRstring
    string

    Use a recipient's alias or a substring of [email protected], such as a host name.

    Alternately, you can run a subset of the mail queue with -qInnnnn.

    # /usr/lib/sendmail -qInnnnn
    nnnnn

    Use a queue ID.

How to Move the Mail Queue, /var/spool/mqueue

If you are moving the mail queue, follow these instructions.

  1. Become root on the mail host or assume an equivalent role.

    Roles contain authorizations and privileged commands. For more information about roles, see Configuring RBAC (Task Map) in System Administration Guide: Security Services. To configure a role with the Primary Administrator profile, see Chapter 2, Working With the Solaris Management Console (Tasks), in System Administration Guide: Basic Administration.

  2. Kill the sendmail daemon.
    # svcadm disable network/smtp:sendmail

    Now sendmail is no longer processing the queue directory.

  3. Change to the /var/spool directory.
    # cd /var/spool
  4. Move the directory, mqueue, and all its contents to the omqueue directory. Then create a new empty directory that is named mqueue.
    # mv mqueue omqueue; mkdir mqueue
  5. Set the permissions of the directory to read/write/execute by owner, and read/execute by group. Also, set the owner and group to daemon.
    # chmod 750 mqueue; chown root:bin mqueue
  6. Start sendmail.
    # svcadm enable network/smtp:sendmail

How to Run the Old Mail Queue, /var/spool/omqueue

To run an old mail queue, follow these instructions.

  1. Become root or assume an equivalent role.

    Roles contain authorizations and privileged commands. For more information about roles, see Configuring RBAC (Task Map) in System Administration Guide: Security Services. To configure a role with the Primary Administrator profile, see Chapter 2, Working With the Solaris Management Console (Tasks), in System Administration Guide: Basic Administration.

  2. Run the old mail queue.
    # /usr/lib/sendmail -oQ/var/spool/omqueue -q

    The -oQ flag specifies an alternate queue directory. The -q flag says to run every job in the queue. Use the -v flag if you are displaying the verbose output on the screen.

  3. Remove the empty directory.
    # rmdir /var/spool/omqueue
Previous Next

 
 
  Published under the terms fo the Public Documentation License Version 1.01. Design by Interspire