Previous  |  Next  >  
Product: Cluster Server Guides   
Manual: Cluster Server 4.1 Agent Developer's Guide   

Building a Custom VCS Agent

The VRTSvcs package installed by the VCS installation program includes the following files to facilitate agent development. Note that custom agents are not supported by VERITAS Technical Support.

Script Agents

Description Pathname

Ready-to-use VCS agent that includes a built-in implementation of the VCSAgStartup entry point.

$VCS_HOME/bin/ScriptAgent

ScriptAgent cannot be used with C++ entry points.

C++ Agents

Description Pathname

Directory containing a sample C++ agent and Makefile.

$VCS_HOME/src/agent/Sample

Sample Makefile for building a C++ agent.

$VCS_HOME/src/agent/Sample/Makefile

Entry point templates for C++ agents.

$VCS_HOME/src/agent/Sample/agent.C

Compiling is not required if all entry points are implemented using scripts. A copy of ScriptAgent is sufficient.

Compiling is required to build the agent if any entry points are implemented using C++. We recommend the following procedures for developers implementing entry points using C++:

  1. Edit agent.C to customize the implementation; agent.C is located in the directory $VCS_HOME/src/agent/Sample.
  2. After completing the changes to agent.C, invoke the make command to build the agent. The command is invoked from $VCS_HOME/src/agent/Sample, where the Makefile is located.

Additional Recommendations

We also recommend naming the agent binary resource_typeAgent. Place the agent in the directory $VCS_HOME/bin/resource_type.

The agent binary for Oracle would be $VCS_HOME/bin/Oracle/OracleAgent, for example. If the agent file is different, for example /foo/ora_agent, the types.cf file must contain the following entry:


  ...
   Type Oracle (
    ...
    static str AgentFile = "/foo/ora_agent"
    ...
  )

If entry points are implemented using scripts, the script file must be placed in the directory $VCS_HOME/bin/resource_type. It must be named correctly (if necessary, review Script Agents).

If all entry points are scripts, all scripts should be in the directory $VCS_HOME/bin/resource_type. Copy the ScriptAgent into the agent directory as $VCS_HOME/bin/resource_type/resource_typeAgent.

For example, if the online entry point for Oracle is implemented using Perl, the online script must be: $VCS_HOME/bin/Oracle/online.

 ^ Return to Top Previous  |  Next  >  
Product: Cluster Server Guides  
Manual: Cluster Server 4.1 Agent Developer's Guide  
VERITAS Software Corporation
www.veritas.com