VMS Help
TCPIP Services, SMTP

 *Conan The Librarian (sorry for the slow response - running on an old VAX)

    For exchanging electronic mail (e-mail) with users working on
    internet hosts, the DIGITAL TCP/IP Services for OpenVMS product
    includes Simple Mail Transfer Protocol (SMTP) and Post Office
    Protocol (POP) software.

    SMTP allows you to use the OpenVMS mail services to send and
    receive messages exchanged with users on other internet hosts.
    The POP software allows you to use your PC mail software to
    receive and send messages. The software stores mail sent to you,
    even when the PC is turned off.

    To use the DIGITAL TCP/IP Services for OpenVMS mail services, you
    need the following:

    o  Knowledge of the OpenVMS Mail utility

    o  User names and IP addresses of the people to whom you want to
       send mail

  1 - Sending Mail

    To send e-mail to another internet host also running SMTP, simply
    invoke the OpenVMS Mail utility at the DCL prompt, type SEND at
    the MAIL> prompt, and enter the destination. A remote destination
    consists of the user name followed by an ampersand (@) and the
    host (such as user_name@host). If the user is on your local host,
    omit the ampersand (@) and host name.

    $ MAIL
    MAIL> SEND
    To: destination_user@destination_host

    Specify the destination host as either a host name or an IP
    address.

    The OpenVMS Mail utility automatically detects destination
    addresses that include fully qualified host names (where the node
    component includes a period (.), such as MALCOLM@PHILOS.BU.EDU)
    and sends the mail using the SMTP protocol, unless your system
    has been set up to use a different Internet protocol (by defining
    an alternate protocol with the MAIL$INTERNET_TRANSPORT logical
    name).

    However, if you use a destination address that is not fully
    qualified - that is, one in which the node component does not
    include a period (.) - the Mail utility by default assumes
    the address is a DECnet address. For example, if you specified
    MALCOLM@PHILOS as the destination address, the Mail utility
    converts it to the DECnet format PHILOS::MALCOLM.

    You can force the OpenVMS Mail utility to use a specific protocol
    by defining the MAIL$INTERNET_MODE logical name. This is useful
    in cases where a mail address, such as MALCOLM@PHILOS, can be
    valid for either SMTP or DECnet.

    You can assign one of the following values to the MAIL$INTERNET_
    MODE logical name:

    o  SMTP

       Mail always interprets the node component of an unqualified
       address as an Internet address specification. (SMTP is the
       default mode unless you define an alternate Internet transport
       with the MAIL$INTERNET_TRANSPORT logical name.)

    o  DECNET

       Mail always interprets the node component of an unqualified
       address as a DECnet node specification.

    o  HYBRID (the default)

       Mail uses an Internet protocol if the node component of the
       address contains a period. If no periods are in the node
       component, Mail uses the DECnet protocol.

    Define the logical name in your LOGIN.COM file. For example, the
    following definition causes the Mail utility to interpret any
    address that does not include a period in the node component of
    the specification as an Internet address:

    $ DEFINE MAIL$INTERNET_MODE SMTP

    Another way to force the OpenVMS Mail utility to use SMTP is to
    include the SMTP% prefix. At the To: prompt, type SMTP% and, with
    no space, either the destination name or IP address. Enclose the
    destination in quotation marks, as in the following example:

    $ MAIL
    MAIL> SEND
    To: SMTP%"malcolm@philos"

    So, if you want to prevent the OpenVMS Mail utility from
    automatically converting an unqualified Internet host name
    address to a format for DECnet use, you have three choices:

    o  Fully qualify the host name (for example, specify
       MALCOLM@PHILOS.BU.EDU instead of MALCOLM@PHILOS).

    o  Define the MAIL$INTERNET_MODE logical name as SMTP.

    o  Include the SMTP% prefix and the destination address in
       quotation marks (for example, SMTP%"MALCOLM@PHILOS.BU.EDU").

    For more information on the OpenVMS Mail utility and how it
    interprets addresses, see the appropriate OpenVMS documentation.

  2 - Multiple Recipients

    To send mail to more than one user, use the SEND command, but at
    the To: prompt, type a list of names or the name of an existing
    distribution list.

    When you type a list of names, use the following guidelines:

    o  Separate each name with a comma ( , ).

    o  If multiple users are on the same remote host, type the full
       user_name@host combination for each user.

    o  If a user is on your local host, omit the ampersand (@) and
       host.

    Use the following syntax:

    MAIL> SEND
    To: user1,user2,user3@host3,user4@host4

    where:

       user1 is located at the local OpenVMS system.
       user2 is located at the local OpenVMS system.
       user3 is located at host3.
       user4 is located at host4.

    MAIL> SEND
    To: user1@host5,user2@host5

    In this example, both users are located at remote host5.

    To send mail to multiple users by entering the name of a
    distribution list, follow these guidelines:

    o  The file with the distribution list can be yours or belong to
       someone else.

    o  The file can reside locally or remotely.

    o  Do not include the names of other distribution lists in the
       distribution list.

    You can use two kinds of distribution lists: OpenVMS distribution
    lists and SMTP distribution lists.

 2.1 - OpenVMS list

    Generate an OpenVMS distribution list as follows:

    -  Create a .DIS file in your own directory or use an existing
       one.

    -  You can include comment lines (lines preceded by an
       exclamation mark (!)).

    -  You can include both OpenVMS addresses and SMTP addresses. If
       you want the Mail utility to use SMTP for all SMTP addresses,
       qualified and unqualified, either set the MAIL$INTERNET_MODE
       logical name to SMTP, specify fully qualified SMTP addresses
       only, or use the SMTP% prefix with the destination enclosed in
       quotation marks.

    -  To send mail to the people on your distribution list, enter:

       MAIL> SEND
       To: @list_name

 2.2 - SMTP list

    Generate an SMTP distribution list as follows:

    -  Create, or use an existing, .DIS file in
       SYS$SPECIFIC:[TCPIP$SMTP] or, if defined on your system,
       TCPIP$SMTP_COMMON:.

    -  Give the list a unique name that is not the same as a local
       user name.

    -  Specify comment lines with an exclamation mark (!) in the
       first column.

    -  Include only SMTP addresses.

    -  Use one address per line.

    -  To send mail to the people on this distribution list, enter
       the following command:

       MAIL> SEND
       To: list_name@host_where_list_resides

       If the MAIL$INTERNET_MODE logical name is not set to SMTP,
       specify a fully qualified host name or use the SMTP% prefix
       with quotation marks enclosing the distribution list/host
       specification.

 2.3 - Examples

    The following examples show some different methods of using
    distribution lists.

    1. This example sends mail to users whose names are on the local
       OpenVMS distribution list AGENCIES.DIS. The distribution list
       file is displayed in this example. The MAIL$INTERNET_MODE
       logical name is not set, so by default unqualified Internet
       addresses would be sent over DECnet; therefore, the AUDUBON@NY
       address is included with the SMTP% prefix and quotation marks.

       $ TYPE AGENCIES.DIS

       !
       ! This is an OpenVMS distribution file named AGENCIES.DIS.
       !
       SMTP%"audubon@ny"
       WILLIAMS@BELTWAY.ORG
       WILDLIFE@DALLAS.ORG
       jmuir@19.8.7.6
       SEC@GP.INTER8.ORG
       BATES::SCOPE
       !
       $ MAIL
       MAIL> SEND
       To:     @AGENCIES.DIS
       Subj:   NEWS TO WATCH FOR

    2. This example sends mail to users whose names are on the
       local SMTP distribution list SYS$SPECIFIC:[TCPIP$SMTP]NATL_
       INTEREST.DIS. The distribution list file is displayed in this
       example.

       $ TYPE NATL_INTEREST.DIS

       green@19.8.7.6
       wlf@19.7.6.5
       arlo@19.4.3.2
       free::monicaL
       wendell@biolo.ne.edu
       $ MAIL
       MAIL> SEND
       To:    natl_interest@main_office.org
       Subj:  News Items

    3. This example sends mail to the users on SMTP distribution list
       FINANCE_CENTERS.DIS, which is maintained on remote mail server
       host HOLBROOK.

       $ TYPE FINANCE_CENTERS.DIS

       ny_accts@23.9.7.4
       sf_stocks@23.7.11.2
       dallas_pfs@23.1.5.1
       denver_accts@holbrook
       $ MAIL
       MAIL> SEND
       To:     finance_centers@holbrook
       Subj:   Portfolio Activity

  3 - Receiving Mail

    To read received mail, follow these steps:

    1. At the DCL prompt, type MAIL.

    2. At the MAIL> prompt, use the DIRECTORY command to view a list
       of received messages.

    3. Use the READ command or indicate the message number you want
       to view in exactly the same way as you would for OpenVMS mail.

    In the following example, a user views the directory of unread
    new mail and selects Message 3 to read.

    $ MAIL

    You have 3 new messages.

    MAIL> DIRECTORY
    NEWMAIL

    # From                 Date         Subject

    1 GWAY::SMTP%"helenm@bhc 10-MAR-1998  Just Checking In
    2 GWAY::SMTP%"mays@sfg 11-MAR-1998  Common Bases
    3 CBIRD::SMTP%"seaway 12-MAR-1998  Cruises

    MAIL> 3

  4 - Name String

    You can define a "personal name" string that is included at
    the top of all the mail messages you send. To create a personal
    name with SMTP mail, use the SET PERSONAL_NAME command with the
    following restrictions:

    o  Enclose the string in quotation marks.

    o  Do not use additional double quotation marks within the
       string.

    o  You may use single quotation marks ( ' ' ).

    o  Do not use 8-bit ASCII characters, for example, ä or ö.
       The eighth bit is truncated. For example, ä becomes d and ö
       becomes v.

    The following example shows a user setting a personal name that
    includes quotation marks:

    $ MAIL
    MAIL> SET PERSONAL_NAME "'Wellth' is in the mind"

  5 - Carbon-Copies

    You can enable "carbon copying" by using the SET CC-PROMPT
    command. Follow these guidelines when you specify destinations
    for the CC: prompt:

    o  Follow the OpenVMS Mail conventions for copying mail to other
       people or to yourself.

    o  For entering the correct address, follow the guidelines listed
       in the Sending Mail section.

    The following example sends mail to user AL and carbon copies
    users ROLLINS, BOND, and RICH:

    MAIL> SEND
    To:     al@airways
    CC:     rollins,bond,rich@flight_central.com
    Subj:   Directions for Night Flight

  6 - Forwarding Messages

    You can forward any mail you receive to any internet host. Follow
    the OpenVMS Mail conventions for forwarding mail.

    If you move to another system that supports SMTP, SMTP can
    forward your mail to your new location. When you set this
    features, type the new address within three sets of quotation
    marks.

    Use the following syntax:

    MAIL> SET FORWARD
    _Address:SMTP%"""new_user_name@forwarding_host"""

  7 - Using UUCP

    The UNIX to UNIX Copy Program (UUCP) lets a system copy files to
    and from other systems running UUCP. UUCP is usually used to copy
    files over a dialup connection.

    To route mail using UUCP, ask your system manager to define the
    general gateway in the SMTP configuration.

    To use SMTP to route mail to a system running UUCP, address the
    mail as follows:

    MAIL> SEND
    To: SMTP%"user_name!uucp_host"

    The following example sends mail to geoffrey at host haldir:

    $ MAIL
    MAIL> SEND
    To: SMTP%"geoffrey!haldir.of.com"

    Ask your system manager if you need to specify a gateway host in
    mail addresses when you work on UNIX to UNIX Copy Program (UUCP)
    dialup lines.

  8 - Managing Mail

    The management commands that can help you work with SMTP mail
    currently in a queue are listed in the following table. Type them
    at the TCPIP> prompt.

    Table 1 Commands for Using SMTP

    Command          Function

    SHOW MAIL        Displays information about mail
    REMOVE MAIL      Deletes mail messages that are in holding state
                     in SMTP queues
    SEND MAIL        Releases for delivery a mail message that is in
                     a holding state

    Displaying Mail Status

    Use the SHOW MAIL command to display information about SMTP mail,
    such as:

    o  Message (entry) number of the queued mail

    o  User name of the sender (to display information about other
       users, you need SYSPRV or BYPASS privileges)

    o  File name of the queued mail

    o  Status of a message

    Deleting Queued Mail

    The following examples show how to delete mail messages from
    SMTP queues, using the TCPIP REMOVE command (similar to the DCL
    DELETE/ENTRY command).

                                   NOTE

       Use this command only to release mail messages that are
       being held; do not use this command to delete mail messages
       in the processing state.
    Releasing Queued Mail

    The following example shows how to requeue an SMTP mail message
    that is currently holding, using the TCPIP SEND MAIL command
    (similar to the DCL ENTRY/RELEASE command). You are prompted to
    confirm you want the mail message requeued.

    $ TCPIP SEND MAIL /ENTRY=828
    _PLUTO$DKD0:[MARLOW]970207015114580_MARLOW.TCPIP_PLUTO;1? y
  Close     HLB-list     TLB-list     Help  

[legal] [privacy] [GNU] [policy] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.