Sun GlassFish Communications Server Diameter Adapter 1.0 Installation and Quick Start Guide

Using the Diameter Commands

This section provides instructions for using the Diameter asadmin commands. The following topics are addressed:

These tasks can also be accomplished by using the Admin Console, with the exception of creating or deleting the Diameter service which can only be done on the command line. Instructions for using the Admin Console are provided in the online help.

Administering the Diameter Service

The Diameter service itself can only be administered on the command line. You cannot create or delete the Diameter service by using the Admin Console. However, all the other Diameter tasks can be performed either on the command line or in the Admin Console.

The following topics are addressed here:

ProcedureTo Create the Diameter Service

Use the create-diameter-service command in remote mode to create the Diameter service on an instance or cluster. The default Diameter stack configuration is applied. If you do not specify the target operand, the default instance is used. If the task applies to a cluster, target must specify the cluster name.

The Diameter service can only be created from the command line. After you create the Diameter service by using the create-diameter-service command, the Diameter node appears in the Communications Server Admin Console. Then you can use the Admin Console for other Diameter tasks if you prefer.

Before You Begin

The Diameter Adapter must be installed before the Diameter service can be created.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. Create the Diameter service by using the create-diameter-service(1) command.


Example 2–2 Creating the Diameter Service on a Server Instance

This example creates the Diameter service on the default instance.


asadmin> create-diameter-service
Command create-diameter-service executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help create-diameter-service at the command line.

ProcedureTo Delete the Diameter Service

Use the delete-diameter-service command in remote mode to delete the Diameter service configuration on a cluster or server instance. The Diameter service can only be deleted from the command line. This command disables the Diameter service and removes the Diameter node in the Admin Console until you recreate the Diameter service. As child elements of the Diameter service, all Diameter configuration elements will be deleted.

If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. Delete the Diameter service by using the delete-diameter-service(1) command.


Example 2–3 Deleting the Diameter Service

This example disables the Diameter service on the default instance.


asadmin> delete-diameter-service
Command delete-diameter-service executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help delete-diameter-service at the command line.

Administering Diameter Applications

The following topics are addressed here:

ProcedureTo Create a Diameter Application

Use the create-diameter-application command in remote mode to create a vendor-specific Diameter application. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

Before You Begin

The Diameter service must be created before a Diameter application can be created.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. Create a Diameter application by using the create-diameter-application(1) command.

    Information about the options and properties of the command is included in this help page.


Example 2–4 Creating a Diameter Application

This example creates a vendor-specific Diameter accounting application that is added to the application set referenced by the ID apps_1. The vendor ID of this application is 10415.


asadmin> create-diameter-application --applicationsid apps_1 --acctappid 300 10415
Command create-diameter-application executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help create-diameter-application at the command line.

ProcedureTo Delete a Diameter Application

Use the delete-diameter-application command in remote mode to remove a Diameter application for a specific vendor. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. List the Diameter applications in a by using the list-diameter-applications(1) command.

  3. Delete a Diameter application by using the delete-diameter-application(1) command.


Example 2–5 Deleting a Diameter Application


asadmin> delete-diameter-application --applicationsid apps_2 2000
Command delete-diameter-application executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help delete-diameter-application at the command line.

ProcedureTo Delete a Diameter Application Set

An application set is a place holder that is used to group a set of applications that have different vendor IDs. This helps peers to refer to applications easily. Use the delete-diameter-applications command in remote mode to remove a Diameter application set. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. Delete a Diameter application set by using the delete-diameter-applications(1) command.


Example 2–6 Deleting a Diameter Application Set

This examples deletes the application set named apps_2.


asadmin> delete-diameter-applications apps_2
Command delete-diameter-applications executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help delete-diameter-applications at the command line.

ProcedureTo Delete Diameter Accounting Application

Use the delete-diameter-acctapp command in remote mode to delete a Diameter accounting application. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. Delete a Diameter accounting application by using the delete-diameter-acctapp(1) command.

  3. Restart the server for changes to take effect.

    Use the stop-domain(1) and start-domain(1) commands.


Example 2–7 Deleting a Diameter Accounting Application

This example deletes the accounting application 300.


asadmin> delete-diameter-acctapp --applicationsid apps_1 --vendorid 10415 300
Command delete-diameter-acctapp executed successfully

See Also

You can also view the full syntax and options of the command by typing asadmin help delete-diameter-acctapp at the command line.

ProcedureTo Delete a Diameter Authentication Application

Use the delete-diameter-authapp command in remote mode to delete a Diameter authentication application. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. Delete a Diameter authentication application by using the delete-diameter-authapp(1) command.

  3. Restart the server for changes to take effect.

    Use the stop-domain(1) and start-domain(1) commands.


Example 2–8 Deleting an Authentication Application

This example deletes authentication application 200.


asadmin> delete-diameter-authapp --applicationsid apps_1 --vendorid 10415 200
Command delete-diameter-authapp executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help delete-diameter-authapp at the command line.

ProcedureTo List Vendors for a Diameter Application Set

Use the list-diameter-application command in remote mode to list the vendor IDs for a specific Diameter application set. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. List vendor IDs for a Diameter application set by using the list-diameter-application(1) command.


Example 2–9 Listing Vendor IDs for a Diameter Application Set

This example lists the vendor IDs for application set apps_1.


asadmin> list-diameter-application apps_1
10415
Command create-diameter-service executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help list-diameter-application at the command line.

ProcedureTo List Diameter Applications

Use the list-diameter-applications command in remote mode to list the Diameter applications in a specific cluster or server instance. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. List the Diameter applications in a particular server or cluster by using the list-diameter-applications(1) command.


Example 2–10 Listing Diameter Applications

This example list the Diameter applications on the default instance.


asadmin> list-diameter-applications
apps_1
Command list-diameter-applications executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help list-diameter-applications at the command line.

Administering Diameter Peers

The following topics are addressed here:

ProcedureTo Create a Diameter Peer

Use the create-diameter-peer command in remote mode to add peer host information to the known peer list in the specified cluster or server instance. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

Before You Begin

A Diameter application must be created before a Diameter peer can be created.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. Add peer host information to the Diameter peer list by using the create-diameter-peer(1) command.

    Information about the options and properties of the command is included in this help page.


Example 2–11 Adding Peer Information to a Diameter Application Set

This example creates a peer named peer_1 on the default instance.


asadmin> create-diameter-peer --applicationsref apps_1 --realm Sun.com --peerhost nyx
--peerport 3878 --transport tls peer_1
Command create-diameter-peer executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help create-diameter-peer at the command line.

ProcedureTo Update a Diameter Peer

Use the set command to update an existing Diameter peer.

  1. List Diameter peers by using the list-diameter-peers(1) command.

  2. Update a Diameter peer by using the set(1) command.

    This example changes the listening port of the peer with ID p1.


    asadmin> set server-config.diameter-service.peer-configuration.peers.peer.p1.port=3737
    server-config.diameter-service.peer-configuration.peers.peer.p1.port = 3737
    

    where p1 is the peer ID which can be changed.

  3. Restart the server for changes to take effect.

    Use the stop-domain(1) and start-domain(1) commands.

ProcedureTo Delete a Diameter Peer

Use the delete-diameter-peer command in remote mode to remove a peer in the Diameter service from the specified cluster or server instance. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. List Diameter peers by using the list-diameter-peers(1) command.

  3. Delete a Diameter peer by using the delete-diameter-peer(1) command.


Example 2–12 Deleting a Diameter Peer

This example deletes peer_1 from the default instance.


asadmin> delete-diameter-peer peer_1
Command delete-diameter-service executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help delete-diameter-peer at the command line.

ProcedureTo List Diameter Peers

Use the list-diameter-peers command in remote mode to list all peers on the specified cluster or server instance. If you do not specify the --target option, the default instance is used. If the task applies to a cluster, the --target option must specify the cluster name.

  1. Ensure that the server is running.

    Remote commands require a running server.

  2. List Diameter peers by using the list-diameter-peers(1) command.


Example 2–13 Listing Diameter Peers

This example lists the Diameter peers on the default instance.


asadmin> list-diameter-peers
peer_1
Command list-diameter-peers executed successfully.

See Also

You can also view the full syntax and options of the command by typing asadmin help list-diameter-peers at the command line.