Sun Java System Messaging Server 6.3 Administration Guide

C.3.1 Adding an SMS Channel

Two steps are required to add an SMS channel to a Messaging Server configuration:

  1. C.3.1.1 Adding the Channel Definition and Rewrite Rules.

  2. C.3.2 Creating an SMS Channel Option File.

While there are no channel options which must be set in all situations, it is likely that one or more of the following options may need to be set: ESME_PASSWORD, ESME_SYSTEM_ID, MAX_PAGE_SIZE, DEFAULT_SOURCE_TON, and DEFAULT_DESTINATION_TON. And, as described, the SMPP server’s hostname or IP address and TCP port must be set either through the channel definition in the imta.cnf file or the channel option file.

You may configure more than one SMS channel, giving different characteristics to different SMS channels. See C.3.4 Adding Additional SMS Channels for further information on the use of multiple SMS channels.

Note for the instructions that follow: if you change the imta.cnf file you must recompile. if you change just a channel option file, there is no need to recompile.

Note also that the time before a channel change takes effect can differ depending on what the change is. Many channel option changes take effect in all channels started since the change was made, which may seem almost instantaneous since the Job Controller is often starting new channels. Some of the changes don’t take effect until you recompile and restart the SMTP server. These options are processed as a message is enqueued to the channel and not when the channel itself runs.

C.3.1.1 Adding the Channel Definition and Rewrite Rules

To add the channel definition and rewrite rules, do the following:

ProcedureTo Add Channel Definition and Rewrite Rules

  1. Before adding an SMS channel to the MTA’s configuration, you need to pick a name for the channel. The name of the channel may be either sms or sms_x where x is any case-insensitive string whose length is between one and thirty-six bytes. For example, sms_mway.

  2. To add the channel definition, edit the imta.cnf file located in the installation-directory/config/ directory. At the bottom of the file add a blank line followed by the two lines:

    channel-name port p threaddepth t \ 
      backoff "pt2m" "pt5m" "pt10m" "pt30m" notices 1

    where channel-name is the name you chose for the channel, p is the TCP port the SMPP server listens on, t is the maximum simultaneous number of SMPP server connections per delivery process, and smpp-host-name is the host name of the system running the SMPP server.

    For example, you might specify a channel definition as follows:

    sms_mway port 55555 threaddepth 20 \ 
    backoff "pt2m" "pt5m" "pt10m" "pt30m" notices 1

    For instructions on how to calculate threaddepth, see C.3.1.2 Controlling the Number of Simultaneous Connections

    See C.3.5 Adjusting the Frequency of Delivery Retries for a discussion of the backoff and notices channel keywords.

    If you wish to specify an IP address rather than a host name, for smpp-host-name, specify a domain literal. For example, if the IP address is, then specify [] for smpp-host-name. Alternatively, consider using the SMPP_SERVER channel option.

    Note –

    For Sun Java System Messaging Server 6.1, the use of the master channel keyword has been deprecated. It is ignored if present.

  3. Once the channel definition has been added, go to the top half of the file and add a rewrite rule in this format:

    smpp-host-name $u@smpp-host-name

    For example, $

  4. Save the imta.cnf file.

  5. Recompile the configuration with the imsimta cnbuild command.

  6. Restart the SMTP server with the imsimta restart dispatcher command.

  7. With the above configuration, email messages are directed to the channel by addressing them to id@smpp-host-name (for example, See C.2.2 The Email to SMS Conversion Process for further information on addressing.

  8. Optionally, if you wish to hide the SMPP server’s host name from users or associate other host names with the same channel, then add additional rewrite rules. For instance, to associate host-name-1 and host-name-2 with the channel, add the following to rewrite rules:

    host-name-1 $U%host-name-1@smpp-host-name
    host-name-2 $U%host-name-2@smpp-host-name

    For example, if the SMPP server’s host name is but you want users to address email to, then add the rewrite rule: $

    Note that the SMPP_SERVER and SMPP_PORT channel options will override the channel’s official host name and port channel keyword settings. When the SMPP_PORT option is used, it is not necessary to also use the port keyword. The advantage of using these two options is that they can be put into effect and subsequently changed without needing to recompile the configuration. An additional use of the SMPP_SERVER option is described inC.3.4 Adding Additional SMS Channels.

C.3.1.2 Controlling the Number of Simultaneous Connections

The threaddepth channel keyword controls the number of messages to assign to each delivery thread within a delivery process. To calculate the total number of concurrent connections allowed, multiply the values of the two following options: SMPP_MAX_CONNECTIONS and job_limit (SMPP_MAX_CONNECTIONS * job_limit). The SMPP_MAX_CONNECTIONS option controls the maximum number of delivery threads in a delivery process. And, the job_limit option, for the Job Controller processing pool in which the channel is run, controls the maximum number of simultaneous delivery processes.

To limit the total number of concurrent connections, you must adjust appropriately either or both of these options. For instance, if the remote SMPP server allows only a single connection, then both SMPP_MAX_CONNECTIONS and job_limit must be set to 1. When adjusting the values, it’s preferable to allow job_limit to exceed 1.