You can use the command line interface to create a service that uses DGS that is the equivalent of using the SunPlex Agent Builder.
Create the service.
For a failover service, use the following command:
# scdscreate -g -V NET -T app -d /usr/local/wdir |
For a scalable service, use the following command:
# scdscreate -g -s -V NET -T app -d /usr/local/wdir |
The -d parameters are optional. If it is not specified, the working directory defaults to the current directory.
Configure the service.
# scdsconfig -s "/usr/local/app/bin/start' \ -t "/usr/local/app/bin/stop" \ -m "/usr/local/app/bin/probe" \ -d /usr/local/wdir |
Only the start command is required. All other parameters are optional.
Install the completed package on both nodes of the cluster.
# cd /usr/local/wdir/NETapp/pkg # pkgadd -d . NETapp |
The following files will be installed during the pkgadd:
/opt/NETapp /opt/NETapp/README.app /opt/NETapp/man /opt/NETapp/man/man1m /opt/NETapp/man/man1m/removeapp.1m /opt/NETapp/man/man1m/startapp.1m /opt/NETapp/man/man1m/stopapp.1m /opt/NETapp/man/man1m/app_config.1m /opt/NETapp/util /opt/NETapp/util/removeapp /opt/NETapp/util/startapp /opt/NETapp/util/stopapp /opt/NETapp/util/app_config |
The man pages and script names will correspond to the Application Name you entered above preceded by the script name; for example, startappname.
To view the man pages, you need to specify the path to the man page. For example, to view the startapp man pages, use the following command:
% man -M /opt/NETapp/man startapp |
On one node of the cluster, configure the resources and start the application.
# /opt/NETapp/util/startapp -h logichostname \ -p port-and-protocol-list |
The arguments to the start script will vary according to the type of resource: failover or scalable. Check the customized man page or run the start script without any argument to get a usage statement.
# /opt/NETapp/util/startapp The resource name of LogicalHostname or SharedAddress must be specified. For failover services: Usage: startapp -h <logical host name> -p <port and protocol list> [-n <nafogroup/adapter list>] [-v] For scalable services: Usage: startapp -h <shared address name> -p <port and protocol list> [-l <load balancing policy>] [-n <nafogroup/adapter list>] [-w <load balancing weights>] [-v] For stand-alone (non-network aware applications): Usage: startapp [-v] |