gLite Data Transfer Agents User's Guide

Paolo Badino

$Id: README.xml,v 1.5.4.1 2006/05/30 12:26:27 badino Exp $


Table of Contents

Introduction
Config Service
Agent Deployment Types
GLite Data Transfer Channel Agent
GLite Data Transfer VO Agent
Component Configuration Details
transfer-agent-sd
transfer-agent-myproxy
transfer-agent-fsm
transfer-agent-scheduler
transfer-agent-catalog-fireman
transfer-agent-ts-urlcopy
transfer-agent-ts-stork
transfer-agent-dao-mysql
transfer-agent-dao-mysql
transfer-agent-dao-oracle
transfer-agent-dao-oracle
transfer-agent-channel-actions
transfer-channel-agent
transfer-agent-vo-actions
transfer-agent-vo-fps-actions
transfer-vo-agent
transfer-vo-agent
Example of Configuration Files
glite-transfer-channel-agent-channel_1.properties.xml
glite-transfer-vo-agent-EGEE.properties.xml (FTS)
glite-transfer-vo-agent-EGEE.properties.xml (FPS)
glite-transfer-vo-agent-EGEE.log-properties
Extending VO Actions with Python Scripts
Structure of the FTS VO Agent Configuration File that uses python strategies
transfer-agent-python
transfer-agent-vo-actions-python
glite-transfer-vo-agent-python-EGEE.properties.xml (FTS)

Abstract

This document contains the information needed to configure thea GLite Data Transfer Agent. For additional information how to install that module, please refer to the gLite Data Transfer Agents Module Install Guide.

Introduction

This package provide the agents that perform the actions concerning the Data Transfers. We distinguished two different kinds of agent: the Channel Agent and the VO Agent.

The Channel Agent is responsible to manage all the file transfers through a channel, i.e. the entity that represent the phisical, monodirectional link between two sites: this agent will fetch the files transfers requests from a Queue and submit them to the configured TransferService.

The other type of agent, the VO Agent, is in charge to perform all the action that are related to a VO specific Virtual Organization, which involves applying VO policies, and Catalog interaction. Moreover, we dustinguish between two possible VO Agent deployment types:

File Transfer Service (FTS)

The agent would manage job where the source and destination contains Physical File Names (SURLs or TURLs). No catalog interaction is foreseen.

File Placement Service (FPS)

Extend the previous model adding the interaction with a Catalog Service, in order to retrieve the source and destination physical file names from the Logical File Names (LFNs and GUIDs) and source and destination sites. Once a transfer is completed, the new replicas are registered to the appropriate catalog.

One Channel Agent is needed for each channels available on the site, and one VO Agent is needed for each VO that what to perfoms data transfer requests. All of these agents share the same Queue, but the FTA frameworks guarantees that they interact each other in the proper way: a VO Agent is allowed to see just the jobs (and related information) that belongs to itself, in the same way a Channel Agent is not able to process requests belonging to a different channel. You can imagine that each agent act on a view of the entire Queue:


              /---------------\
              |     Queue     |
              \---------------/
              |--------       |
    VO_1      || Vo_1 |       |
    Agent =====> View |-------|
              |-------- Ch_1 ||    Channel_1
              |      |  View <=====  Agent
              |--------      ||
    VO_2      || Vo_2 |-------|
    Agent =====> View |-------|      
              |-------- Ch_2 ||    Channel_2 
              |      |  View <=====  Agent
              |--------      ||
    VO_3      || Vo_2 |-------|
    Agent =====> View |       |
              |--------       |
              \---------------/

The way of the Channel and the VO Agent work is the same: they periodically run some action in order to perform the step required to transfer data.

The Channel Agent actions are:

Fetch

Submit new File transfer request to the TransferService

Check

Check the state of all the active File transfer requests and update the Queue with the retrieved information

Cancel

Revoke active file transfers marked as canceling on the Queue

The VO Agent actions are:

  • File Transfer Service:

    Allocate

    Allocate a transfer job to a channel based on the source and destination of the related files

    Retry

    Reschedule failed transfers that are in waiting state

    Cancel

    Revoke pending (i.e. not yet processed by the Channel Agent) file transfers marked as canceling on the Queue.

  • File Placement Service; adds the following actions to the FTS ones:

    Resolve

    Resolve the source Logical File Names into an SURL and generate the destination SURL looking at the information provided by the Service Discovery

    Register

    When a Transfer Job is completed, register the new replicas on the Catalog Service

The GLite Data Transfer Agents module provides a default action for all of these types, but it would also allow to extend the behavior of an agent by configuring different actions.

Config Service

The gLite Data Transfer Agents use the gLite Data Config Service modules for retrieving initialization and configuration parameters. For a detailed explanation how that module works please have a look at the gLite Data Config Service User's Guide.

Agent Deployment Types

GLite Data Transfer Channel Agent

The GLite Transfer Agent requires the configuration files named glite-transfer-channel-agent-<CHANNEL_NAME>.properties.xml and glite-transfer-channel-agent-<CHANNEL_NAME>.log-properties in $GLITE_LOCATION_USER/etc, $GLITE_LOCATION/etc or $GLITE_LOCATION_VAR/etc, where <CHANNEL_NAME> is the name of the Channel which the agent is responsible for. The structure of theconfiguration file depends of the type of Queue and Transfer Service the Channel Agent has to contact:


<service name="transfer-channel-agent">
  <components>
    <component name="transfer-agent-sd">
      <!-- ServiceDiscovery client Configuration-->
    </component>
    <component name="transfer-agent-myproxy">
      <!-- MyProxy client Configuration-->
    </component>  
    <component name="transfer-agent-fsm">
      <!-- FSM Configuration-->
    </component>
    <component name="transfer-agent-dao-****">
      <!-- Queue (Data Access Object) Connector -->
    </component>
    <component name="transfer-agent-ts-****">
      <!-- Transfer Service Connector -->
    </component>
    <component name="transfer-agent-scheduler">
      <!-- Scheduler Configuration-->
    </component>
    <component name="transfer-agent-channel-actions">
      <!-- Channel Actions Configuration -->
    </component>
    <component name="transfer-channel-agent">
      <!-- Channel Agent Configuration -->
    </component>
  </components>
</service>

where the sections markled with **** depends on the connector that has to be used.

GLite Data Transfer VO Agent

The GLite Transfer Agent requires the configuration files named glite-transfer-vo-agent-<VO_NAME>.properties.xml and glite-transfer-vo-agent-<VO_NAME>.log-properties in $GLITE_LOCATION_USER/etc, $GLITE_LOCATION/etc or $GLITE_LOCATION_VAR/etc, where <VO_NAME> is the name of the Virtual Organization which the Agent belongs to. The structure of the configuration file depends also on the chosen VO Agent deployment type (FTS or FPS) and on the type of the Queue the Agent has to contact. Please note that a VO can't install both a FTS VO Agent and a FPS VO agent.

Structure of the FTS VO Agent Configuration File


<service name="transfer-vo-agent-fts">
  <components>
    <component name="transfer-agent-sd">
      <!-- ServiceDiscovery client Configuration-->
    </component>
    <component name="transfer-agent-myproxy">
      <!-- MyProxy client Configuration-->
    </component>  
    <component name="transfer-agent-fsm">
      <!-- FSM Configuration-->
    </component>
    <component name="transfer-agent-dao-****">
      <!-- Queue (Data Access Object) Connector -->
    </component>
    <component name="transfer-agent-scheduler">
      <!-- Scheduler Configuration-->
    </component>
    <component name="transfer-agent-vo-actions">
      <!-- VO Actions Configuration -->
    </component>
    <component name="transfer-vo-agent">
      <!-- VO Agent Configuration -->
    </component>
  </components>
</service>

Structure of the FPS VO Agent Configuration File


<service name="transfer-vo-agent-fps">
  <components>
    <component name="transfer-agent-sd">
      <!-- ServiceDiscovery client Configuration-->
    </component>
    <component name="transfer-agent-myproxy">
      <!-- MyProxy client Configuration-->
    </component>  
    <component name="transfer-agent-catalog-****">
      <!-- Catalog Service client Plugin -->
    </component>
    <component name="transfer-agent-fsm">
      <!-- FSM Configuration-->
    </component>
    <component name="transfer-agent-dao-****">
      <!-- Queue (Data Access Object) Connector -->
    </component>
    <component name="transfer-agent-scheduler">
      <!-- Scheduler Configuration-->
    </component>
    <component name="transfer-agent-vo-actions">
      <!-- VO Actions Configuration -->
    </component>
    <component name="transfer-agent-vo-fps-actions">
      <!-- VO FPS Actions Configuration -->
    </component>
    <component name="transfer-vo-agent">
      <!-- VO Agent Configuration -->
    </component>
  </components>
</service>

where the sections markled with **** depends on the connector/plug-in that has to be used.

Currently, the following Connectors are implemented:

Transfer Service:

Glite-Url-Copy -- transfer-agent-ts-urlcopy

It can be configured to use third party gsiftp transfers (type is "urlcopy") or to issue SRM copy requests (type is "srmcopy")

Stork -- transfer-agent-ts-stork

Deprecated. Maintained for testing.

Data Access Object:

  • MySQL -- transfer-agent-dao-mysql

  • Oracle -- transfer-agent-dao-oracle

The requirement is that the configuration should contain one connector per type (transfer-agent-ts-* and transfer-agent-dao-*).

For what concern the Catalog Client, currently we provide:

  • GLite Fireman -- transfer-agent-catalog-fireman

Note

Please note that a Catalog Client is required only for the VO Agent FPS deployment scenario.

Component Configuration Details

The following section describes the configuration parameter for the GLite Transfer Agents. The configuration for the Connectors/Plug-ins is reported in a dedicated section. Since most of the modules are common for the Channel, VO FTS and VO FPS Agents, deployment model specifics are discussed on the description note. For a structure of the configuration file for a given agent, please check the previous section.

transfer-agent-sd

Represents the module that should be use to retieve service information from ServiceDiscovery

Library:

libglite_data_transfer_agent_sd.so

Initialization:
SRM_ServiceType [expert]

The type used to register SRM Services on ServiceDiscovery

Type: string; Default value: 'SRM'

GridFTP_ServiceType [expert]

The type used to register GRIDFTP Servers on ServiceDiscovery

Type: string; Default value: 'gsiftp'

MyProxy_ServiceType [expert]

The type used to register MyProxy Catalog Services on ServiceDiscovery

Type: string; Default value: 'MyProxy'

FileTransfer_ServiceType [expert]

The type used to register FileTransfer Services on ServiceDiscovery

Type: string; Default value: 'org.glite.FileTransfer'

FilePlacement_ServiceType [expert]

The type used to register FilePlacement Services on ServiceDiscovery

Type: string; Default value: 'org.glite.FilePlacement'

SEMountPoint_Property [expert]

The name of the SRM Service Property that provides the mount point to be used

Type: string; Default value: 'SEMountPoint'

EnableCache [expert]

Enable caching of ServiceDiscovery information

Type: boolean; Default value: 'true'

Configuration:
Cache_TTL [expert]

The validity, in seconds, of the entries created in the cache. When this time elapsed, the entry is been refreshed automatically by the cache next time the user asked for it. Entry related to queries that returned no result are not refreshed. If this parameter is not provided, the internal default will apply (1 hour)

Type: integer; Default value: ''

Cache_StaleTime [expert]

The reduced validity time for the stale entries in the cache: When the validity of an entry expires, the cache try to refresh it using SevriceDiscovery. In case of failure, the entry is considered stale and kept into the cache with a shorter validity. If this parameter is not provided, the internal default will apply (15 minutes)

Type: integer; Default value: ''

Cache_ObsoleteTime [expert]

The number of seconds that should elaps before the entry in the cache are considered obsolete and can then be purged. Since entries are periodically refreshed based on the usage, the purge operation affects only stale entries. If this parameter is not provided, the internal default will apply (5 hours)

Type: integer; Default value: ''

Cache_NegativeObsoleteTime [expert]

The number of seconds that should elaps before considering obsolete the entries related to queries that didn't return any result. These "negative" results are not automatically refreshed, therefore should be cleaned more often. If this parameter is not provided, the internal default will apply (5 minutes)

Type: integer; Default value: ''

transfer-agent-myproxy

Represents the mmodule that provide a client to the MyProxy Server for retrieving proxy certificates to be used for the File Transfers

Library:

libglite_data_transfer_agent_myproxy.so

Initialization:
Server [advanced]

The host name of the MyProxy Server. If that parameter is not set or is empty, the Myproxy Server is looked up using the Service Discovery and then, if not found, the myproxy default will apply (MYPROXY_SERVER environment variable)

Type: string; Default value: ''

Port [advanced]

The port of the MyProxy Server. If that parameter is not set or is 0, the myproxy default will applies

Type: integer; Default value: '0'

ProxyLifetime [advanced]

The lifetime in seconds of the proxy certificates that will be created

Type: integer; Default value: '86400'

Repository [advanced]

The location where the certificates retrieved from the MyProxy Service will be stored. That location must already exist

Type: string; Default value: '/tmp'

MinValidityTime [advanced]

The minimum validity time (in seconds) an already existent certificate should have before submitting a new job. In case the certificate couldn't satisfy that requirement, a new certificate will be retrieved from the MyProxy Service

Type: integer; Default value: '3600'

Configuration:

<No configuration parameters>

transfer-agent-fsm

Represents the library that provides the logic for the File and Job State transitions

Library:

libglite_data_transfer_agent_fsm.so

Initialization:
EnableHold [expert]

When this parameter is set to true, in case of consecutive failures, a transfer will be moved to the "Hold" state, waiting for manual intervention, otherwise it will go in "Failed"

Type: boolean; Default value: 'true'

Configuration:

<No configuration parameters>

transfer-agent-scheduler

This module provides a scheduler class that is able to periodically execute FTA Actions

Library:

libglite_data_transfer_agent_scheduler.so

Initialization:

<No initialization parameters>

Configuration:
MaxFailures [expert]

The number of consecutive failures before an Action is considered disabled for <DisableTime> seconds. If that value is set to zero, actions will never be disabled and the parameter <DisableTime> is ignored

Type: integer; Default value: '0'

DisableTime [expert]

The number of seconds an action stays disabled

Type: integer; Default value: '300'

CheckInterval [expert]

Specify the time interval, in seconds, to periodically check if the DAO context is valid. If 0 is specified,the context is checked on every iteration

Type: integer; Default value: '60'

StopTimeout [expert]

Specify the timeout, in seconds, that a scheduler has to wait for the stopping its thread gracefully. If the timeout elapsed a signal in sent in order to try to abort the running action

Type: integer; Default value: '100'

Catalog Client: Client for retrieving Replica Information from a Catalog Service. In case the no catalog interaction is foreseen (like for the FTS deployment model), this component can be removed from the configuration file. This module will be loaded at run-time. Currently, the supported plugins are:

transfer-agent-catalog-fireman

This module represents the module that should be used to connect to the GLite Fireman Catalog in order to resolve logical file names and register new replicas

Library:

libglite_data_transfer_agent_catalog_fireman.so

Initialization:
Fireman_ServiceType [expert]

The type used to register a Fireman Catalog Services in ServiceDiscovery. If this parameter is set, the same value will be assigned to the Global and Local Catalog Service Types and the related Initialization Parameters are ignored.

Type: string; Default value: 'org.glite.FiremanCatalog'

GlobalCatalog_ServiceType [expert]

The type used to register a Global Fireman Catalog Services in ServiceDiscovery. This parameter is taken into account only if "Fireman_ServiceType" is not set

Type: string; Default value: 'org.glite.FiremanCatalog'

LocalCatalog_ServiceType [expert]

The type used to register a Local Fireman Catalog Services in ServiceDiscovery. This parameter is taken into account only if "Fireman_ServiceType" is not set

Type: string; Default value: 'org.glite.FiremanCatalog'

Configuration:

<No configuration parameters>

File Transfer Service Connector: the configuration file for the GLite Transfer Agent should specify one connector for contacting the Transfer Service. This module will be loaded at run-time.

transfer-agent-ts-urlcopy

Represents the connector to use the URLCopy as Transfer Service

Library:

libglite_data_transfer_agent_ts_urlcopy.so

Initialization:
TransferType []

The type of transfer that should be performed. This value can be either "urlcopy" or "srmcopy": In the first case, the TransferService would perform the SRM interaction and start a GridFTP transfer, in the latter the TransferService would delegate the transfer to the SRM by an SRMCopy call

Type: string; Default value: 'urlcopy'

MaxTransfers []

The maximum number of transfer request that the Transfer Service can process simultaneously

Type: integer; Default value: '50'

Streams [advanced]

The maximum number of parallel streams that could be used during the transfer. A transfer is performed with the number of streams specified in the channel table, if lesser than "Streams", otherwise this threshold would be used. In any case the value can be overwritten by a job using the job's parameter "-p". Currently, this value has no effect if the "TransferType" parameter is set to "srmcopy"

Type: integer; Default value: '10'

TcpBlockSize [advanced]

The TCP Block Size that should be used during the transfer.If set to 0, the default is used This parameter can be overwritten by a job using the job's parameter "-tcpbs". Currently, this value has no effect if the "TransferType" parameter is set to "srmcopy"

Type: integer; Default value: '0'

TransferTimeout [advanced]

The timeout value (in seconds) that should be used to detect that a transfer is hanging.0 means no timeout.In case the specified value is -1, the glite-url-copy default will apply. Please note that in case of SrmCopy bulk requests the global transfer timeout is computed by multiplying this value for the size of the request.If this property is not set, it will assume 600 in case of UrlCopy transfer type and 0 in case of SrmCopy transfer type

Type: integer; Default value: '600'

HttpTimeout [advanced]

The timeout value (in seconds) that should be used for the SOAP calls to the SRM. This timeout is used both for send and receiving.0 means no timeout. In case the specified value is -1, the glite-url-copy default will apply.

Type: integer; Default value: '-1'

SrmPutTimeout [advanced]

The timeout value (in seconds) that should be used for an SRM Put request. 0 means no timeout.In case the specified value is -1, the glite-url-copy default will apply. This value is ignored if the "TransferType" parameter is different from "urlcopy"

Type: integer; Default value: '60'

SrmGetTimeout [advanced]

The timeout value (in seconds) that should be used for an SRM Get request. 0 means no timeout. In case the specified value is -1, the glite-url-copy default will apply. This value if ignored is the "TransferType" parameter is different from "urlcopy"

Type: integer; Default value: '60'

SrmPutDoneTimeout [advanced]

The timeout value (in seconds) that should be used for trying to set the SRM status of the Destination File to Done.0 means no timeout.In case the specified value is -1, the glite-url-copy default will apply. This value is ignored if the "TransferType" parameter is different from "urlcopy"

Type: integer; Default value: '60'

SrmGetDoneTimeout [advanced]

The timeout value (in seconds) that should be used for trying to set the SRM status of the Source File to Done.0 means no timeout.In case the specified value is -1, the glite-url-copy default will apply. This value is ignored if the "TransferType" parameter is different from "urlcopy"

Type: integer; Default value: '60'

TransferMarkersTimeout [advanced]

The timeout value (in seconds) between two Transfer Markers that should be used to detect that a transfer is hanging.0 means no timeout.In case the specified value is -1, the glite-url-copy default will apply. This value is ignored if the "TransferType" parameter is different from "urlcopy"

Type: integer; Default value: '120'

SrmCopyTimeout [advanced]

The timeout value (in seconds) that should be used for an SRM Copy request. 0 means no timeout.In case the specified value is -1, the glite-url-copy default will apply. This value is ignored if the "TransferType" parameter is different from "srmcopy"

Type: integer; Default value: '120'

SrmStatusTimeout [advanced]

The time interval (in seconds) that should be used in order to abort an srm copy call: when the SRM can't be contacted for the time specified by that parameter, the transfer will be aborted. 0 means no timeout. This value is ignored if the "TransferType" parameter is different from "srmcopy"

Type: integer; Default value: '600'

MaxBulkSize [advanced]

The maximum size for a bulk SrmCopy request. This value is ignored if the "TransferType" parameter is different from "srmcopy"

Type: integer; Default value: '100'

SrmCopyDirection [expert]

The direction of the srm copy transfer. Can assume the following values: "pull" (the transfer is driven by the destination SRM), "push" (the transfer is driven by the source SRM), "default" (defualt value of glite-urlcopy, usually pull). This value is ignored if the "TransferType" parameter is different from "srmcopy"

Type: string; Default value: 'default'

Configuration:
LogLevel []

The Log Level for the Glite URL Copy Transfer. Allowed values are: DEBUG, INFO, WARN, and ERROR

Type: string; Default value: 'DEBUG'

transfer-agent-ts-stork

Represents the conncetor that should be used to contact Stork as Transfer Service

Library:

libglite_data_transfer_agent_ts_stork.so

Initialization:
ServerName []

The name of the host where the Stork Server is running

Type: string; Default value: 'localhost'

CredName [/mandatory]

the name of the CredD credential to be passed to Stork

Type: string; Default value: ''

MaxTransfers []

The maximum number of transfers Stork can process simultaneously

Type: integer; Default value: '1000'

Type []

The type of proxy that should be used to contact Stork. This param could assume the following values: - Api: Use Stork C API (Not yet implemented) - Exec: Use Stork Command Line Interface, spawining a process for each command and piping the result

Type: string; Default value: 'Exec'

BinLocation []

The location where Stork Command Line tools are installed. This parameter is required only if the <Type> parameter is set to "Exec"

Type: string; Default value: '/opt/stork/bin'

Configuration:

<No configuration parameters>

Data Access Object Connector: the configuration file for the GLite Transfer Agent should specify one connector for contacting the Queue. This module will be loaded at run-time.

transfer-agent-dao-mysql

Represents the module to Access Data (DAO) using MySQL as Data Source

Library:

libglite_data_transfer_agent_dao_mysql.so

Initialization:
HostName []

The name of the DB Server where mySQL is installed

Type: string; Default value: 'localhost'

Port [advanced]

The port of the mySQL DB Server. 0 means the mySQL default

Type: integer; Default value: '0'

DBName []

the name of the Database holding the queue

Type: string; Default value: 'transfer'

User [/mandatory]

the name of the user that should be used to connect to the DB

Type: string; Default value: ''

Password [/mandatory]

the password of the user that should be used to connect to the DB

Type: string; Default value: ''

SocketName [advanced]

The name of the socket to be used to connect to the DB Server in case <HostName> is "localhost". If no value is specified, the mysql default is used

Type: string; Default value: ''

VOView [expert]

Enable the VO View DAO Factory

Type: string; Default value: 'false'

ChannelView [expert]

Enable the Channel View DAO Factory

Type: string; Default value: 'true'

Configuration:

<No configuration parameters>

transfer-agent-dao-mysql

Represents the module to Access Data (DAO) using MySQL as Data Source

Library:

libglite_data_transfer_agent_dao_mysql.so

Initialization:
HostName []

The name of the DB Server where mySQL is installed

Type: string; Default value: 'localhost'

Port [advanced]

The port of the mySQL DB Server. 0 means the mySQL default

Type: integer; Default value: '0'

DBName []

the name of the Database holding the queue

Type: string; Default value: 'transfer'

User [/mandatory]

the name of the user that should be used to connect to the DB

Type: string; Default value: ''

Password [/mandatory]

the password of the user that should be used to connect to the DB

Type: string; Default value: ''

SocketName [advanced]

The name of the socket to be used to connect to the DB Server in case <HostName> is "localhost". If no value is specified, the mysql default is used

Type: string; Default value: ''

VOView [expert]

Enable the VO View DAO Factory

Type: string; Default value: 'true'

ChannelView [expert]

Enable the Channel View DAO Factory

Type: string; Default value: 'false'

Configuration:

<No configuration parameters>

transfer-agent-dao-oracle

Represents the module to Access Data (DAO) using Oracle as Data Source

Library:

libglite_data_transfer_agent_dao_oracle.so

Initialization:
ConnectString [/mandatory]

The Oracle ConnectString identifying the DB

Type: string; Default value: 'localhost'

User [/mandatory]

the name of the user that should be used to connect to the DB

Type: string; Default value: ''

Password [/mandatory]

the password of the user that should be used to connect to the DB

Type: string; Default value: ''

StatementCacheSize [expert]

The Size of the statement Cache.0 means that the caching is disabled. Note: since some memory leaks has been observed, it better for the moment to keep the cache disabled

Type: integer; Default value: '0'

VOView [expert]

Enable the VO View DAO Factory

Type: string; Default value: 'false'

ChannelView [expert]

Enable the Channel View DAO Factory

Type: string; Default value: 'true'

Threaded [expert]

Specify if the application is using Threads or not. Allowed value are: none - No threads; mutexed - Thread safe mode, mutexed internally by OCCI; unmutexed - Thread safe mode, client is responsible for mutexing.

Type: string; Default value: 'none'

Configuration:

<No configuration parameters>

transfer-agent-dao-oracle

Represents the module to Access Data (DAO) using Oracle as Data Source

Library:

libglite_data_transfer_agent_dao_oracle.so

Initialization:
ConnectString [/mandatory]

The Oracle ConnectString identifying the DB

Type: string; Default value: 'localhost'

User [/mandatory]

the name of the user that should be used to connect to the DB

Type: string; Default value: ''

Password [/mandatory]

the password of the user that should be used to connect to the DB

Type: string; Default value: ''

StatementCacheSize [expert]

The Size of the statement Cache.0 means that the caching is disabled. Note: since some memory leaks has been observed, it better for the moment to keep the cache disabled

Type: integer; Default value: '0'

VOView [expert]

Enable the VO View DAO Factory

Type: string; Default value: 'true'

ChannelView [expert]

Enable the Channel View DAO Factory

Type: string; Default value: 'false'

Threaded [expert]

Specify if the application is using Threads or not. Allowed value are: none - No threads; mutexed - Thread safe mode, mutexed internally by OCCI; unmutexed - Thread safe mode, client is responsible for mutexing.

Type: string; Default value: 'none'

Configuration:

<No configuration parameters>

Channel Agent: this section will report the Channel Agent-specific modules

transfer-agent-channel-actions

Represents the module that provides the Channel Agent Actions. These actions are: <Fetch> : Submit job through the channel; <CheckState> : Check Active Jobs' State; <CancelActive>: Cancel Active Transfers;

Library:

libglite_data_transfer_agent_channel_actions.so

Initialization:
SurlNormalization [expert]

The strategy to be used to change the format of the SURLs. Allowed values are: compact: SURLs would be converted to the format srm://<host>/<sfn> compact-with-port: SURLs would be converted to the format srm://<host>:<port>/<sfn> fully-qualified: SURLs would be converted to the format srm://<host>:<port>/<path>?SFN=<sfn> where <path> is usually retrieved from the SRM endpoint and it's usually <srm/managerv1> disabled: no convertion is performed. The SURLs are processed as submitted by the users

Type: string; Default value: 'compact'

Configuration:
EnableDelegation [expert]

Enable Client Credential Delagation. If this value is set to true, transfers would be executed using client delegated credentials, retrieved from MyProxy, otherwise the agent would use its Service credentials.

Type: boolean; Default value: 'true'

transfer-channel-agent

This module represent the agent that should run the actions concerning a Channel. Actions are provided by different libraries that should be loaded into the the agent process using GLite Data Config Service. The Channel Agent requires to run three different kind of action: <Fetch> : Transfer files through the channel using the configured TransferService; <Check> : Check the status of pending TransferService requests; <Cancel>: Cancel a pending transfer TransferService request; This configuration assign a default value for all of these types, however it would be possible to provide different action types and use them, just provide the type of the action on the related <action_type>_Type initialization parameter. By default, all the action are scheduled to be executed periodically with an interval provided by the "DefaultInterval" configuration parameter. In order to modify the sceduling interval based on the action type, just provide a <action_type>_Interval configuration parameter with the value you want to assign. In addition to the actions described above, the Channel Agent also execute other two internal actions: <Heartbeat> : Periodically refresh the status of agent in teh Database <CleanSDCache>: Clean the ServiceDiscovery Cache For what concern the scheduling interval of these actions, the values are specified by the parameters <Heartbeat_Interval> and <CleanSDCache_Interval>

Library:

libglite_data_transfer_channel_agent.so

Initialization:
Name [/mandatory]

The name of the Channel which the agent is responsible for

Type: string; Default value: ''

Contact []

The contact information of the Administrator responsible for that agent

Type: string; Default value: ''

VOShareType [expert]

This parameter specify how to interpret the VO Share values associated to a channel. It should be one the following values: * normalized: the share is the value of the channel voshare property for the given VO, normalized to the sum of all the share for all the VOs in the same channel. This option could be used when channel administrators wantto guarantee slots for certain VOs, in order to implement some sort of QoS, accepting to eventually penalize the total throughput (transfer slots would be reserved to a VO even if that VO has no job to process) * absolute: the share is the value on the channel voshare property expressed as a percentage. No normalization is performed, that means that the sum of all the shares on the same channel can exceed 100%. This option could be used when channel administrators want to balance the share between the VOs, without allowing that a single VO fully allocate a channel but minimizing the risk to allocate slots to VOs that don't have any job to process. This option implies some tuning on the VO share values based on the experience, but it would allow to have a compromise between throughput and QoS * normalized-on-active: the share is the value of the channel voshare property for the given VO, normalized to the sum of all the share for all the VOs in the same channel that has at least one job that can be processed by the Channel Agent (job state should be Active, Pending or Canceling). This option is the default one and could be used when the channel administrators want to optimize the throughput of the channel (the channel can be fully allocated even by one VO), but with a lower QoS

Type: string; Default value: 'normalized-on-active'

Fetch_Type [expert]

The name of the action that provides the logic to fetch transfers

Type: string; Default value: 'glite:Fetch'

Check_Type [expert]

The name of the action that provides the logic to check the state of running transfers

Type: string; Default value: 'glite:CheckState'

Cancel_Type [expert]

The name of the action that provides the logic to cancel active transfers

Type: string; Default value: 'glite:CancelActive'

Configuration:
DefaultInterval []

The default interval, in secons, to be used for scheduling the Channel actions

Type: integer; Default value: '3'

Heartbeat_Interval [expert]

The interval, in seconds, to be used for scheduling the Heartbeat action. The purpose of this action is to periodically update the lastActive timestamp in the t_agent table, in order to demonstrate that agent is up and running. If this value is 0, the Heartbeat action will be disabled

Type: integer; Default value: '60'

CleanSDCache_Interval [expert]

The interval, in seconds, to be used for purging obsolete entries from the ServiceDiscovery cache in order to evaluate changes in the information system. If the SD Cache is disabled, this action doesn't do anything

Type: integer; Default value: '300'

Fetch_Interval [expert]

The interval, in secons, to be used for scheduling the Fetch action. If this parameter is not set or is empty, the Fetch action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Fetch action will be disabled (useful only for debugging purposes)

Type: integer; Default value: ''

Check_Interval [expert]

The interval, in secons, to be used for scheduling the Check State action. If this parameter is not set or is empty, the Check State action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Check action will be disabled (useful only for debugging purposes)

Type: integer; Default value: ''

Cancel_Interval [expert]

The interval, in secons, to be used for scheduling the Cancel action. If this parameter is not set or is empty, the Cancel action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Cancel action will be disabled (useful only for debugging purposes)

Type: integer; Default value: ''

VO Agent: this section will report the VO Agent-specific modules

transfer-agent-vo-actions

Represents the module that provides the VO Agent Actions. These actions are: <Allocate> : allocate a job into a channel based on the source and destination ; <CancelPending>: revoke pending job in Canceling state ; <BasicRetry< : reschedule transfers that are in waiting state;

Library:

libglite_data_transfer_agent_vo_actions.so

Initialization:
SurlNormalization [expert]

The strategy to be used to change the format of the SURLs. Allowed values are: compact: SURLs would be converted to the format srm://<host>/<sfn> compact-with-port: SURLs would be converted to the format srm://<host>:<port>/<sfn> fully-qualified: SURLs would be converted to the format srm://<host>:<port>/<path>?SFN=<sfn> where <path> is usually retrieved from the SRM endpoint and it's usually <srm/managerv1> disabled: no convertion is performed. The SURLs are processed as submitted by the users

Type: string; Default value: 'compact'

EnableDelegation [expert]

Enable Client Credential Delagation. If this value is set to true, vo agent actions would be executed using client delegated credentials, retrieved from MyProxy, otherwise the agent would use its Service credentials. Please note that this option is introduced for testing purposes and therefore is not supported in production

Type: boolean; Default value: 'true'

Configuration:
MaxFailures []

The maximum number of failures before moving the file to Hold (or Failed, depending on "Transfer Agent FSM" EnableHold advanced parameter)

Type: integer; Default value: '3'

ResubmitDelay []

The delay in second before a Waiting transfer is resubmitted

Type: integer; Default value: '600'

EnableUnknownSource [advanced]

Enable Unknown Source Site. If this value is set to true, during the allocation phase, in case the source SE is not listed on the Information System, the job would be assigned to the fake "UNKNOWN" site; otherwise the job would fail. This option is useful in order to transfer files from an SE that is on a different Grid

Type: boolean; Default value: 'false'

EnableUnknownDest [advanced]

Enable Unknown Destination Site. If this value is set to true, during the allocation phase, in case the destination SE is not listed on the Information System, the job would be assigned to the fake "UNKNOWN" site; otherwise the job would fail. This option is useful in order to transfer files to an SE that is on a different Grid

Type: boolean; Default value: 'false'

transfer-agent-vo-fps-actions

Represents the module that provides the VO FPS Actions. These actions are: <Resolve> : Resolve Logical name into phisical ones; <Register>: Register the new replicas when the transfer is finished;

Library:

libglite_data_transfer_agent_vo_fps_actions.so

Initialization:

<No initialization parameters>

Configuration:

<No configuration parameters>

VO FTS Agent:

transfer-vo-agent

This module represents the agent that should run the actions concerning a Virtual Organization in order to provide the FTS/FPS functionality. Actions are provided by different libraries that should be loaded into the the agent process using GLite Data Config Service. The VO Agent configured in FTS mode requires to run three different kind of actions: <Allocate> : Allocate transfer job to a channel; <Retry> : Try to resubmit failed transfers; <Cancel> : Cancel a pending file (not yet processed by a channel); In configured inb FPS mode, the VO Agent requires to run two additional actions: <Resolve> : Resolve source and destination physical file names starting from; the logical name <Register> : Register the new replica when the transfer is completed; This module provides a default value for all of these types, however it would be possible to provide different action types and use them, by specifying the type of the action on the related <action_type>_Type initialization parameter. By default, all the actions (except the Retry which) are scheduled to be executed periodically with an interval provided by the "DefaultInterval" configuration parameter. The interval for the Retry Action is specified by the <Retry_Interval> parameter. In order to modify the scheduling interval based on the action type, you can provide a <action_type>_Interval configuration parameter with the value you want to assign. In addition to the actions described above, the VO Agent also execute other two internal actions: <Heartbeat> : Periodically refresh the status of agent in teh Database <CleanSDCache>: Clean the ServiceDiscovery Cache For what concern the scheduling interval of these actions, the values are specified by the parameters <Heartbeat_Interval> and <CleanSDCache_Interval>

Library:

libglite_data_transfer_vo_agent.so

Initialization:
Name [/mandatory]

The name of the VO which the agent belong to

Type: string; Default value: ''

Contact []

The contact information of the Administrator responsible for that agent

Type: string; Default value: ''

DisableDelegationForTransfers [expert]

If that parameter is set to true, the transfers will be performed using the related Channel Agent service credentails, otherwise they will use the client proxy certificate downloaded from MyProxy

Type: boolean; Default value: 'false'

DeploymentType [expert]

The deployment type of the agent. It could be "fts" in case the agent should act as File Transfer Service or "fps" in case it should act as File Placement Service

Type: string; Default value: 'fts'

Allocate_Type [expert]

The name of the action type that provides the logic to allocate a transfer job to a channel

Type: string; Default value: 'glite:Allocate'

Retry_Type [expert]

The name of the action type that provides the logic to retry failed transfers

Type: string; Default value: 'glite:BasicRetry'

Cancel_Type [expert]

The name of the action type that provides the logic to cancel pending (i.e. not yet processed by a channel) file transfers

Type: string; Default value: 'glite:CancelPending'

Configuration:
DefaultInterval []

The default interval, in seconds, for scheduling the VO actions

Type: integer; Default value: '3'

Heartbeat_Interval [expert]

The interval, in seconds, to be used for scheduling the Heartbeat action. The purpose of this action is to periodically update the lastActive timestamp in the t_agent table, in order to demonstrate that agent is up and running. If this value is 0, the Heartbeat action will be disabled

Type: integer; Default value: '60'

CleanSDCache_Interval [expert]

The interval, in seconds, to be used for removing obsolete entries from the ServiceDiscovery cache in order to evaluate changes in the information system. If the SD Cache is disabled, this action doesn't do anything

Type: integer; Default value: '300'

Allocate_Interval [expert]

The interval, in seconds, to be used for scheduling the Allocate action. If this parameter is not set or is empty, the Allocate action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Allocate action will be disabled (useful only for debugging purposes)

Type: integer; Default value: ''

Retry_Interval [expert]

The interval, in seconds, to be used for scheduling the Retry action. If this parameter is not set or is empty, the Retry action will be scheduled every 60 seconds. If this value is 0, the Retry action will be disabled (useful only for debugging purposes)

Type: integer; Default value: '60'

Cancel_Interval [expert]

The interval, in seconds, to be used for scheduling the Cancel action. If this parameter is not set or is empty, the Cancel action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Cancel action will be disabled (useful only for debugging purposes)

Type: integer; Default value: ''

VO FPS Agent:

transfer-vo-agent

This module represents the agent that should run the actions concerning a Virtual Organization in order to provide the FTS/FPS functionality. Actions are provided by different libraries that should be loaded into the the agent process using GLite Data Config Service. The VO Agent configured in FTS mode requires to run three different kind of actions: <Allocate> : Allocate transfer job to a channel; <Retry> : Try to resubmit failed transfers; <Cancel> : Cancel a pending file (not yet processed by a channel); In configured inb FPS mode, the VO Agent requires to run two additional actions: <Resolve> : Resolve source and destination physical file names starting from; the logical name <Register> : Register the new replica when the transfer is completed; This module provides a default value for all of these types, however it would be possible to provide different action types and use them, by specifying the type of the action on the related <action_type>_Type initialization parameter. By default, all the actions (except the Retry which) are scheduled to be executed periodically with an interval provided by the "DefaultInterval" configuration parameter. The interval for the Retry Action is specified by the <Retry_Interval> parameter. In order to modify the scheduling interval based on the action type, you can provide a <action_type>_Interval configuration parameter with the value you want to assign. In addition to the actions described above, the VO Agent also execute other two internal actions: <Heartbeat> : Periodically refresh the status of agent in teh Database <CleanSDCache>: Clean the ServiceDiscovery Cache For what concern the scheduling interval of these actions, the values are specified by the parameters <Heartbeat_Interval> and <CleanSDCache_Interval>

Library:

libglite_data_transfer_vo_agent.so

Initialization:
Name [/mandatory]

The name of the VO which the agent belong to

Type: string; Default value: ''

Contact []

The contact information of the Administrator responsible for that agent

Type: string; Default value: ''

DisableDelegationForTransfers [expert]

If that parameter is set to true, the transfers will be performed using the related Channel Agent service credentails, otherwise they will use the client proxy certificate downloaded from MyProxy

Type: boolean; Default value: 'true'

DeploymentType [expert]

The deployment type of the agent. It could be "fts" in case the agent should act as File Transfer Service or "fps" in case it should act as File Placement Service

Type: string; Default value: 'fps'

Allocate_Type [expert]

The name of the action type that provides the logic to allocate a transfer job to a channel

Type: string; Default value: 'glite:Allocate'

Retry_Type [expert]

The name of the action type that provides the logic to retry failed transfers

Type: string; Default value: 'glite:BasicRetry'

Cancel_Type [expert]

The name of the action type that provides the logic to cancel pending (i.e. not yet processed by a channel) file transfers

Type: string; Default value: 'glite:CancelPending'

Resolve_Type [expert]

The name of the action type that provides the logic to resolve source and destination physical file names starting from a logical name (LFN or GUID) and the source and destination sites. This parameters is used only in case the <DeploymentType> is set to "fps"

Type: string; Default value: 'glite:Resolve'

Register_Type [expert]

The name of the action type that provides the logic to register the new replicas into a Catalog Service when the file transfer are completed. This parameters is used only in case the <DeploymentType> is set to "fps"

Type: string; Default value: 'glite:Resolve'

Configuration:
DefaultInterval []

The default interval, in seconds, for scheduling the VO actions

Type: integer; Default value: '3'

Heartbeat_Interval [expert]

The interval, in seconds, to be used for scheduling the Heartbeat action. The purpose of this action is to periodically update the lastActive timestamp in the t_agent table, in order to demonstrate that agent is up and running. If this value is 0, the Heartbeat action will be disabled

Type: integer; Default value: '60'

CleanSDCache_Interval [expert]

The interval, in seconds, to be used for removing obsolete entries from the ServiceDiscovery cache in order to evaluate changes in the information system. If the SD Cache is disabled, this action doesn't do anything

Type: integer; Default value: '300'

Allocate_Interval [expert]

The interval, in seconds, to be used for scheduling the Allocate action. If this parameter is not set or is empty, the Allocate action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Allocate action will be disabled (useful only for debugging purposes)

Type: integer; Default value: ''

Retry_Interval [expert]

The interval, in seconds, to be used for scheduling the Retry action. If this parameter is not set or is empty, the Retry action will be scheduled every 60 seconds. If this value is 0, the Retry action will be disabled (useful only for debugging purposes)

Type: integer; Default value: '60'

Cancel_Interval [expert]

The interval, in seconds, to be used for scheduling the Cancel action. If this parameter is not set or is empty, the Cancel action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Cancel action will be disabled (useful only for debugging purposes)

Type: integer; Default value: ''

Resolve_Interval [expert]

The interval, in seconds, to be used for scheduling the Name Resolution action. If this parameter is not set or is empty, the Name Resolution action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Name Resolution action will be disabled (useful only for debugging purposes). This parameters is used only in case the <DeploymentType> is set to "fps"

Type: integer; Default value: ''

Register_Interval [expert]

The interval, in seconds, to be used for scheduling the Replica Registration action. If this parameter is not set or is empty, the Replica Registration action will be scheduled using the value provided by the "DefaultInterval" parameter. If this value is 0, the Replica Registration action will be disabled (useful only for debugging purposes). This parameters is used only in case the <DeploymentType> is set to "fps"

Type: integer; Default value: ''

Example of Configuration Files

This section contains some example of the GLite Data Transfer Channel and VO Agent configuration files. Those values should be changed according to the environment where the GLite Data Transfer Channel Agent is installed. Fireman, UrlCopy and Oracle connectors are used.

glite-transfer-channel-agent-channel_1.properties.xml


<?xml version="1.0" encoding="UTF8"?>
<service>
  <components>
    <component name="transfer-agent-sd">
      <lib>libglite_data_transfer_agent_sd.so</lib>
    </component>
    <component name="transfer-agent-myproxy">
      <lib>libglite_data_transfer_agent_myproxy.so</lib>
      <init>
        <param name="Server">
          <value>lxb1414.cern.ch</value>
        </param>
      </init>
    </component>
    <component name="transfer-agent-fsm">
      <lib>libglite_data_transfer_agent_fsm.so</lib>
    </component>
    <component name="transfer-agent-dao-oracle">
      <lib>libglite_data_transfer_agent_dao_oracle.so</lib>
      <init>
        <param name="ConnectString">
          <value>@DBNAME</value>
        </param>
        <param name="User">
          <value>@DBUSER</value>
        </param>
        <param name="Password">
          <value>@DBPASSWORD</value>
        </param>
        <param name="VOView">
          <value>false</value>
        </param>
        <param name="ChannelView">
          <value>true</value>
        </param>
      </init>
    </component>
    <component name="transfer-agent-ts-urlcopy">
      <lib>libglite_data_transfer_agent_ts_urlcopy.so</lib>
      <dependencies>
        <lib>libglite_data_transfer_url_copy.so</lib>
      </dependencies>
      <init>
        <param name="MaxTransfers">
          <value>3</value>
        </param>
      </init>
      <config>
        <param name="LogLevel">
          <value>DEBUG</value>
        </param>
      </config>
    </component>
    <component name="transfer-agent-scheduler">
      <lib>libglite_data_transfer_agent_scheduler.so</lib>
    </component>
    <component name="transfer-agent-channel-actions">
      <lib>libglite_data_transfer_agent_channel_actions.so</lib>
    </component>
    <component name="transfer-channel-agent">
      <lib>libglite_data_transfer_channel_agent.so</lib>
      <init>
        <param name="Name">
          <value>channel_1</value>
        </param>
        <param name="DefaultInterval">
          <value>3</value>
        </param>
      </init>
    </component>
  </components>
</service>

glite-transfer-vo-agent-EGEE.properties.xml (FTS)


<?xml version="1.0" encoding="UTF8"?>
<service>
  <components>
    <component name="transfer-agent-sd">
      <lib>libglite_data_transfer_agent_sd.so</lib>
    </component>
    <component name="transfer-agent-myproxy">
      <lib>libglite_data_transfer_agent_myproxy.so</lib>
      <init>
        <param name="Server">
          <value>lxb1414.cern.ch</value>
        </param>
      </init>
    </component>
    <component name="transfer-agent-fsm">
      <lib>libglite_data_transfer_agent_fsm.so</lib>
    </component>
    <component name="transfer-agent-dao-oracle">
      <lib>libglite_data_transfer_agent_dao_oracle.so</lib>
      <init>
        <param name="ConnectString">
          <value>@DBNAME</value>
        </param>
        <param name="User">
          <value>@DBUSER</value>
        </param>
        <param name="Password">
          <value>@DBPASSWORD</value>
        </param>
        <param name="VOView">
          <value>true</value>
        </param>
        <param name="ChannelView">
          <value>false</value>
        </param>
      </init>
    </component>
    <component name="transfer-agent-scheduler">
      <lib>libglite_data_transfer_agent_scheduler.so</lib>
    </component>
    <component name="transfer-agent-vo-actions">
      <lib>libglite_data_transfer_agent_vo_actions.so</lib>
    </component>
    <component name="transfer-vo-agent">
      <lib>libglite_data_transfer_vo_agent.so</lib>
      <init>
        <param name="Name">
          <value>EGEE</value>
        </param>
        <param name="DeploymentType">
          <value>fts</value>
        <param name="DefaultInterval">
          <value>3</value>
        </param>
      </init>
    </component>
  </components>
</service>

glite-transfer-vo-agent-EGEE.properties.xml (FPS)


<?xml version="1.0" encoding="UTF8"?>
<service>
  <components>
    <component name="transfer-agent-sd">
      <lib>libglite_data_transfer_agent_sd.so</lib>
    </component>
    <component name="transfer-agent-myproxy">
      <lib>libglite_data_transfer_agent_myproxy.so</lib>
      <init>
        <param name="Server">
          <value>lxb1414.cern.ch</value>
        </param>
      </init>
    </component>
    <component name="transfer-agent-catalog-fireman">
     <lib>libglite_data_transfer_agent_catalog_fireman.so</lib>
    </component>
    <component name="transfer-agent-fsm">
      <lib>libglite_data_transfer_agent_fsm.so</lib>
    </component>
    <component name="transfer-agent-dao-oracle">
      <lib>libglite_data_transfer_agent_dao_oracle.so</lib>
      <init>
        <param name="ConnectString">
          <value>@DBNAME</value>
        </param>
        <param name="User">
          <value>@DBUSER</value>
        </param>
        <param name="Password">
          <value>@DBPASSWORD</value>
        </param>
        <param name="VOView">
          <value>true</value>
        </param>
        <param name="ChannelView">
          <value>false</value>
        </param>
      </init>
    </component>
    <component name="transfer-agent-scheduler">
      <lib>libglite_data_transfer_agent_scheduler.so</lib>
    </component>
    <component name="transfer-agent-vo-actions">
      <lib>libglite_data_transfer_agent_vo_actions.so</lib>
    </component>
    <component name="transfer-agent-vo-fps-actions">
     <lib>libglite_data_transfer_agent_vo_fps_actions.so</lib>
    </component>
    <component name="transfer-vo-agent">
      <lib>libglite_data_transfer_vo_agent.so</lib>
      <init>
        <param name="Name">
          <value>EGEE</value>
        </param>
        <param name="DeploymentType">
          <value>fps</value>
        <param name="DefaultInterval">
          <value>3</value>
        </param>
      </init>
    </component>
  </components>
</service>

glite-transfer-vo-agent-EGEE.log-properties

An example of a logging configuration file is:

log4j.rootCategory=DEBUG, file
                                                                                
log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%m%n
                                                                                
log4j.appender.file=org.apache.log4j.FileAppender
log4j.appender.file.fileName=/var/log/glite/glite-transfer-vo-agent-EGEE.log
log4j.appender.file.layout=org.apache.log4j.PatternLayout
log4j.appender.file.layout.ConversionPattern=%d %-6p %c - %m%n

The agent configuration template file can then be generated by concatenating the differenet transfer-agent-*.config-template.xml files contained into the config folder. This configuration template file can then be used to generate the configuration file as explained in the gLite Data Transfer Agents Install Guide document.

Extending VO Actions with Python Scripts

All the VO Agent Actions can be overridden specifying the appropriate action type in the vo-agent configuration. In order to do that, the library providing the action should be loaded inside the process (using the Glite Sevrice Configurator Library) and the related action types shoudl be registered in ActionFactory. However, this approach is quite complex and requires that the actions reimplement most of the logic already provided by the default ones. Due to that reason, from version 2.2.0 FileTransferAgent starts adopting the Strategy Pattern, decoupling the logic of the action (that a VO may want to customize) from the common tasks (get instances from the DB, update changes, etc...). This new approach, combined with the possibility to call python scripts within the VO Agent process, would allow then to specify these strategy in a easier way. At the moment, the only action startegy that can be overridden is the Retry, but new ones will be added in future versions.

In order to use this feature, the structure of the VO Agent shold be modified as illustrated below:

Structure of the FTS VO Agent Configuration File that uses python strategies


<service name="transfer-vo-agent-fts">
  <components>
    <component name="transfer-agent-sd">
      <!-- ServiceDiscovery client Configuration-->
    </component>
    <component name="transfer-agent-myproxy">
      <!-- MyProxy client Configuration-->
    </component>  
    <component name="transfer-agent-python">
      <!-- FTS Python module -->
    </component>
    <component name="transfer-agent-fsm">
      <!-- FSM Configuration-->
    </component>
    <component name="transfer-agent-dao-****">
      <!-- Queue (Data Access Object) Connector -->
    </component>
    <component name="transfer-agent-scheduler">
      <!-- Scheduler Configuration-->
    </component>
    <component name="transfer-agent-vo-actions">
      <!-- VO Actions Configuration -->
    </component>
    <component name="transfer-agent-vo-actions-python">
      <!-- VO Python Actions Configuration -->
    </component>
    <component name="transfer-vo-agent">
      <!-- VO Agent Configuration -->
    </component>
  </components>
</service>

The configuration properties of these new modules are:

transfer-agent-python

The purpose of this module is to load and initialize the Python interpreter in order to run python script inside the FileTransferAgent process. The module also initialize some wrapper modules that can be used to pass object to the scripts

Library:

libglite_data_transfer_agent_python.so

Initialization:
PythonPath []

The location where the python interpret look for modules and packages. The value can be a list of directory path separated by ':' (in a unix-like sistem). If this property is set, the module would add the value to the PYTHONPATh environment variable

Type: string; Default value: ''

Configuration:

<No configuration parameters>

transfer-agent-vo-actions-python

Represents the module that overrides some VO Actions allowing to specify the strategy as a python script These actions are, at the moment: <Retry>: Retry failed transfers or move them to hold;

Library:

libglite_data_transfer_agent_vo_actions_python.so

Initialization:
RetryModule [/mandatory]

The name of the python module that contains the function that would be evaluated in order to choose if a file has to be retried, faild or let it in Waiting state. If you want to configure the VO agent in order to use the retry action that call this module, you have to set the property "transfer-vo-agent.Retry_Type" to "glite:PythonRetry"

Type: string; Default value: ''

RetryParams [advanced]

This parameter represent an initialization string that will be passed to the python module that contains the retry logic, specified by the "RetryModule" parameter. The format of that string is module dependent

Type: string; Default value: ''

Configuration:

<No configuration parameters>

Please note that in order to be able to call the strategy defined in the python script you have to, you have to set the expert property "transfer-vo-agent.Retry_Type" to "glite:PythonRetry"

In case of the VO Agent configured to handle transfers starting from the logical name is exactly the same, you need just to take as reference the VO Agent FPS configuration.

The current release of transfer-agents provides two python retry strategies, located in GLITE_LOCATION/lib/python/glite/fts/strategies:

  • basic_retry.py: the python implementation of the default BasicRetry Strategy. No configuration parameters are exposed this script

  • smarter_retry.py a more advanced retry logic that check for the last transfer failures: fail immediately if source files doesn't exist; wait more if a timeout on get is received;delete destination file if a "file exists" error follows a "transfer error". This script accepts the following configuration parameters, that you could pass through the "transfer-agent-vo-actions-python.RetryParams":

    • MaxFailures : The maximum number of failures allowed for a file (Default:10)

    • MaxFileExistsFailures : The maximum number of consecutive "File Exists" failures (Default: 3)

    • HoldEnabled : If this value is set to true, when a file fails,it will be moved to HOLD. If this value is set to false, the file status will be FAILED(Default: true)

    • OverwriteFailedFiles : When the strategy detect that a "file exists" failure is due by a incomplete cleanup of a previous failed transfer, delete the destination file before performing the new attempt (Default: true)

    • OverwriteExistingFiles : In case of "file exists" failure, always delete the destination before retrying the transfer (Default: false)

    • DefaultRetryDelay : The default interval (in seconds) before retyring a transfer (Default:600)

    • RetryDelayForTimeoutOnGet : The interval (in seconds) before retyring a transfer that failed with a "Timeout on Get" error (Default:1800)

    • RetryDelayForDestFileExists : The interval (in seconds) before retyring a transfer that failed at the destination (Default:600)

    • RetryDelayForDestFileExists : The interval (in seconds) before retyring a transfer that failed at the destination (Default:600)

    • SrmServiceType : The service type that identify an SRM into the information systrem (Default: SRM)

The following section illustrate an example of configuration that use a python script as retry strategy

glite-transfer-vo-agent-python-EGEE.properties.xml (FTS)


<?xml version="1.0" encoding="UTF8"?>
<service>
  <components>
    <component name="transfer-agent-sd">
      <lib>libglite_data_transfer_agent_sd.so</lib>
    </component>
    <component name="transfer-agent-myproxy">
      <lib>libglite_data_transfer_agent_myproxy.so</lib>
    </component>
    <component name="transfer-agent-fsm">
      <lib>libglite_data_transfer_agent_fsm.so</lib>
    </component>
    <component name="transfer-agent-dao-oracle">
      <lib>libglite_data_transfer_agent_dao_oracle.so</lib>
      <init>
        <param name="ConnectString">
          <value>@DBNAME</value>
        </param>
        <param name="User">
          <value>@DBUSER</value>
        </param>
        <param name="Password">
          <value>@DBPASSWORD</value>
        </param>
        <param name="VOView">
          <value>true</value>
        </param>
        <param name="ChannelView">
          <value>false</value>
        </param>
      </init>
    </component>
    <component name="transfer-agent-scheduler">
      <lib>libglite_data_transfer_agent_scheduler.so</lib>
    </component>
    <component name="transfer-agent-python">
      <lib>libglite_data_transfer_agent_python.so</lib>
      <init>
        <param name="PythonPath">
            <value>/opt/glite/lib/python2.2/site-packages:
                /opt/glite/lib/python/glite/fts/strategies/</value>
        </param>
      </init>
    </component>
    <component name="transfer-agent-vo-actions">
      <lib>libglite_data_transfer_agent_vo_actions.so</lib>
    </component>
    <component name="transfer-agent-vo-actions-python">
      <lib>libglite_data_transfer_agent_vo_actions_python.so</lib>
      <init>
        <param name="RetryModule"> 
          <value>smarter_retry</value> 
        </param>
        <param name="RetryParams"> 
          <value>
            MaxFailures = 10 ;
            HoldEnabled  = true ;
            OverwriteFailedFiles = true ;
            OverwriteExistingFiles = false ;
            DefaultRetryDelay  = 60  ; 
            RetryDelayForTimeoutOnGet   = 300 ;
            RetryDelayForDestFileExists = 60 ;
          </value>
        </param>
      </init>
    </component>
    <component name="transfer-vo-agent">
      <lib>libglite_data_transfer_vo_agent.so</lib>
      <init>
        <param name="Name">
          <value>EGEE</value>
        </param>
        <param name="Retry_Type">
          <value>glite:PythonRetry</value> 
        </param>
        <param name="DeploymentType">
          <value>fts</value>
        </param>
      </init>
    </component>
  </components>
</service>