Managing the system

A common task is to add customers, web users and EMG accounts to the system.

It is important to understand the order in which this should be done.

  • First an account should be created. This is the account used by customers connecting to the EMG server via, for example, SMPP and where the message credit handling takes place.
  • When the account has been created a customer (company) should be added and one or more accounts should then be linked/assigned to the customer.
  • Finally the users are added and each user must be connected to an account (and thereby a customer) .

Accounts

EMG accounts are added to the EMG server and the account credentials (username and password) are used for authenticating connector connections, for example binds via SMPP.

Please note that SMPP specification limits the password to 8 characters and using longer passwords than that may cause problems.

Account access

It is possible to limit access to an account to specific IP addresses or ranges.

If you do not want to limit access you still need to add one access entry with connector “Any”, ip address “0.0.0.0” and ip width “0”.

Pre-paid vs post-paid accounts

An account can be either pre-paid or post-paid. A pre-paid account for which the account balance reaches 0 will reject any further attempts to send messages.

Routes

A hard-coded route can be specified for the account but using the route table is recommended.

It is possible to specify a specific route for delivery reports (DLRs) which may be necessary if DLRs are to be forwarded via HTTP for example.

Adding credits

By clicking the value next to “Account balance” you can add or deduct from the account balance. A positive value adds to the account balance and a negative value deducts from the account balance.

Any changes to the account balance are stored in the account balance history table.

Screenshots

Add account

Customer

A customer (company) can be linked to one or more EMG accounts.

You can have a daily e-mail report sent to the customer by enabling it on the customer and setting up the corresponding cron job.

Routes

This functionality requires that the EMG billing plugin is configured and used.

The routes view can be used to manage message routes.

Routes can be defined both for MT and MO traffic.

More specific routes take priority in the routing decision.

Matching is done in the following order (top priority first):

Connector inRouteUsernamePrefix
MatchAnyMatchMatch (longest first)
MatchAnyMatchAny
AnyAnyMatchMatch (longest first)
AnyAnyMatchAny
MatchAnyAnyMatch (longest first)
MatchAnyAnyAny
AnyAnyAnyMatch (longest first)
AnyAnyAnyAny

It is recommended to define a “default route” with “Any” for all criteria so that a message not matching any of the other routes will fall back on the default route.

Load balancing and fail-over

If multiple routes for same rule set are present with same priority then the connector will be picked randomly random and thereby load-balancing can be configured.

If one of the connectors is in a non-bound state then that connector will not be used.

If multiple routes for same rule set are present with different priorities then rules with the highest priority are used first, provided connector is in bound state.

Connector queue size limit

Starting with EMG 7 and EMG Portal 2 it is possible to define a max queue size per connector (connector keyword MAXQUEUESIZE).

If a connector which is a potential route target has reached its maximium queue size then it will be considered unavailable.

If no other connector can be used for the routing the message will be rejected with an error code “queue full” or “busy” depending on protocol.

Screenshots

Add route

Create routes

List routes

List routes

Prices


This functionality requires that the EMG billing plugin is licensed, configured and used.

The prices view can be used to manage message prices (and optionally costs).

More specific prices take priority in the price decision.

Matching is done in the following order (top priority first):

Connector inRouteUsernamePrefix
MatchAnyMatchMatch (longest first)
MatchAnyMatchAny
AnyAnyMatchMatch (longest first)
AnyAnyMatchAny
MatchAnyAnyMatch (longest first)
MatchAnyAnyAny
AnyAnyAnyMatch (longest first)
AnyAnyAnyAny

It is recommended to define a “default price” with “Any” for all criteria so that a message not matching any of the other routes will fall back on the default price.

Connector configuration

This requires EMG watchdog integration

Connectors can be configured from EMG Portal when a database-driven configuration (DBCONFIG) is being used.

When the configuration is changed from EMG Portal a timestamp will be updated.

If the “last updated” timestamp is newer than the active configuration EMG Portal will offer the possibility to activate the new configuration.

configured connectors

Some changes require a EMG server restart to take effect. This includes:

  • Changing connector type, protocol or address (host/ip or port)
  • Renaming a connector

When EMG watchdog is used the server can easily be stopped and restarted from within EMG Portal.

connector dashboard
create connector

EMG server log files

When EMG watchdog integration is configured in EMG Portal it is possible to display and search the EMG server log files.

EMG Portal will retrieve a list of the log files in the log directory on the server side and for each of the log files the last lines in the log file can be displayed.

It is also possible to specify a search term which will be used to retrieved only the matching line from the log file (using “grep” on the server side).

Screenshot

EMG log file