sun.com | docs.sun.com |  | How To Buy | My Sun | Worldwide Sites |

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Application Server Utility | cladmin(1m)

- NAME
- SYNOPSIS
- DESCRIPTION
- OPTIONS
- EXAMPLES
- EXIT STATUS
- ATTRIBUTES
- SEE ALSO

## NAME

> cladmin - runs certain `asadmin` commands simultaneously on all application server instances in a cluster

## SYNOPSIS

> `cladmin [ --help ] [ --instancefile instance_file_location ][ --passwordfile password_file_location ]asadmin_command`

## DESCRIPTION

> To simplify the task of cluster administration, you can use the `cladmin` command to run the following `asadmin` commands simultaneously on all application server instances in a cluster:

> start-instance

>   starts a server instance and all the services associated with it

> stop-instance

>   stops the specified server instance and all the services associated with it

> deploy

>   deploys the specified component

> undeploy

>   removes the component from the named instance

> create-jdbc-resource

>   registers the JDBC resource to the named instance

> create-jdbc-connection-pool

>   registers the JDBC connection pool to the named instance

> configure-session-persistence

>   enables configuration of parameters related to session persistence

> delete-jdbc-resource

>   removes the JDBC resource from the named instance

> delete-jdbc-connection-pool

>   removes the JDBC connection pool from the named instance

> To ensure consistency in configuration of all application server instances in a cluster, use the `cladmin` command for all the supported `asadmin` commands.

> The following input files are required for the `cladmin` command to function:

> `clinstance.conf`

>   contains information about the application server instances that are part of the cluster.

> `clpassword.conf`

>   contains the `asadmin` password and is pre-populated with the correct password during a standard installation.

> By default the input files are located in the application server configuration directory which is located in `/etc/opt/SUNWappserver7`. You can modify the input files to support different configurations. The server instances that are part of the cluster must be defined in the instance file (default name is `clinstance.conf`).

> Before editing the input files, keep in mind:

> - The order of the entries must not be changed.

> - Any line that starts with a hash mark (#) is treated as a comment.

> Before running the `cladmin` command you must:

> - have the `asadmin` command on the local machine.

> - use the `clsetup` command to setup a typical cluster configuration.

> - use the same administrator password for all domains that are part of the cluster.

> - start the administration servers of all instances that are part of the cluster.

> - make sure you list all the instances that are part of the cluster in the `clinstance.conf` file.

> - change the directory to `install_dir/bin`; where

>   install_dir is the server installation directory.

> During standard installation, the `clinstance.conf` file is created with entries for two instances. If you add more instances to the cluster, or create more clusters, you must update the `clinstance.conf` file with the information for the new instances. The information about the instances in each cluster must be identified in the instance file (default name is `clinstance.conf`). The following are the possible entries in the `clinstance.conf` file:

> Table 1: Entries in the clinstance.conf file
> Entry | Definition | Default Value(s)
> --- | --- | ---
> instance | name of the application server instance | server1, server2
> user | Administration server user name | admin
> host | Host name | localhost
> port | Port number of the Administration Server | 4848
> domain | Name of the Administrative domain | domain1
> instanceport | Port number of the application server instance | 80, 81

> The `clpassword.conf` file contains the administration server password. During execution of the `cladmin` command, the `asadmin` command requires the administration server password specified in the `clpassword.conf` file. The format for the `clpassword.conf` file is :

> >     AS_ADMIN_PASSWORD=password

> Where password is the administration server password.

> Permissions 0600 are preset on the `clpassword.conf` file and it can be accessed only by the root user.

> A log file, named `cladmin.log`, is available in the `/var/tmp/cladmin.log` directory. By default the `cladmin` command executes in verbose mode and logs information in the log file. Log file entries start and end with timestamp tags. If the log file exists prior to execution, the output is appended to the existing log file. Scan the log after each execution to verify that it ran properly.

> If you are running multiple clusters, a separate `clinstance.conf` file must be specified for each cluster. You can run the `cladmin` command on the instances in any cluster by specifying the path of the input files for that particular cluster.

## OPTIONS

> --help

>   displays the syntax of the command

> --instancefile

>   filepath location to the instance file (default is `clinstance.conf`).

> --passwordfile

>   filepath location to the password file (default is `clpassword.conf`).

## EXAMPLES

> Example 1. Using cladmin to start all instances in a cluster

> > >     ./cladmin start-instance

> > Since the location of the input files is not specified, the input files are read from the configuration directory (located by default in /etc/opt/SUNWappserver7).

> Example 2. Using cladmin to start all instances with Input file locations specified

> > >     ./cladmin --instancefile /tmp/clinstance.conf
> > >     --passwordfile /tmp/clpassword.conf start-instance

> Example 3. Using cladmin to create a JDBC connection pool

> > >     ./cladmin create-jdbc-connection-pool --user admin
> > >     --datasourceclassname com.sun.hadb.jdbc.ds.HadbDataSource
> > >     --isisolationguaranteed=true --isolationlevel repeatable-read
> > >     --isconnectvalidatereq=true --isconnectvalidatereq=true
> > >     --validationmethod auto-commit --failconnection=false --proprety
> > >     username=test:password=test:serverList=exampleserver1.example.
> > >     com\:15100,exampleserver2.example.com\:15120 CluJDBC

> Example 4. Using cladmin to configure session persistence for all instances in a cluster

> > >     ./cladmin configure-session-persistence --user admin
> > >     --type ha --frequency web-method --scope session --store jdbc_hastore

## EXIT STATUS

> 0

>   successful exit

> 2

>   syntax error

> 3

>   instance file not found

> 4

>   instance file cannot be read

> 5

>   password file not found

> 6

>   password file cannot be read

> 7

>   user trying to run the command is not a root user

> 8

>   cannot locate `asadmin` command

> 9

>   cannot create temporary file

> 10

>   command could not be executed

## ATTRIBUTES

> See `attributes`(5) for descriptions of the following attributes:

> ATTRIBUTE TYPE | ATTRIBUTE VALUE
> --- | ---
> Interface Stability | Unstable

## SEE ALSO

> `asadmin`(1M), `hadbm`(1M), `clsetup`(1M)

Sun Java System Application Server 7.1 Enterprise Edition | Go To Top | Last Changed 29 Dec 2003

Company Info | Contact | Copyright 2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.