69
Griglie Computazionali Data Management 1 Data Management in Grids [email protected] INFN – CNAF Corso di Laurea specialistica in Informatica Anno Acc. 2005/2006

Data Management In Grids

Embed Size (px)

Citation preview

Page 1: Data Management In Grids

Griglie Computazionali Data Management 1

Data Management in [email protected]

INFN – CNAF

Corso di Laurea specialistica in Informatica

Anno Acc. 2005/2006

Page 2: Data Management In Grids

Griglie Computazionali Data Management 2

Outline

• Storage Element• File naming• Catalogs • Data management:

– Data scheduler

– File placement/transfer service

– File transfer queue

– File transfer agenet

• Security• References

Page 3: Data Management In Grids

Griglie Computazionali Data Management 3

Data management: components (1/2)

1. Storage Element: storage management and File I/O

2. File catalogs

3. Data Scheduling services

Collective

Application

Fabric

Connectivity

Resource

Grid Architecture

Data movement

Data Storage andcatalogs

Page 4: Data Management In Grids

Griglie Computazionali Data Management 4

Data management components (2/2)

Page 5: Data Management In Grids

Griglie Computazionali Data Management 5

1. Data Storage: the Storage Element

• Different types of data:– files

– data sets: e.g. a collection of files• A directory is an explicit dataset by inclusion. Files may be added, removed by

the usual mechanisms.

• Datasets by reference may be a directory containing symbolic links to other files.

• A directory may have “real” files as well as symbolic links.

– data objects or tables in a relational database

– ...

• Storage Element (SE) definition: the Grid service responsible for saving/retrieving files to/from some data store, which can be any device from a hard disk to a mass storage system. – The SE manages disk space for permanent files.

– It maintains the cache for temporary files.

Page 6: Data Management In Grids

Griglie Computazionali Data Management 6

Storage Element (1/2)

• The Storage Element is the resource-level Grid service front-end of a storage system (back-end).

• For scalability reasons, running a world-wide distributed file system everywhere is not a workable solution for a lightweight middleware solution, hence the need of having multiple individual storage systems.

• Ubiquitousness: an interface to every available storage system at a given site is needed in order to not to have to deal with the peculiarities of each individual storag: the Storage Resource Manager (SRM) interface.

• SRM is standardized through the Global Grid Forum

• What type of DEVICE:– tape archiver, a thin layer of logic on top of a local hard-disk in user-space, disk-

arrays, DVD racks, etc.

• OTHER SERVICES INVOLVED:– The Storage Element is making use of the catalog services to resolve GUIDs and

LFNs to SURLs (see following slides)– VOMS for authentication to check authorization for the files.– File Transfer Service

Page 7: Data Management In Grids

Griglie Computazionali Data Management 7

Storage Element (2/2)

• The “QoS” in terms of data storage refers to how strong the commitment is on the side of the SE to actually keep the user’s data safe.

• Some SEs may be unable to give any guarantee to the user that the data will be still available the next minute because of the properties of the underlying technology.

• Other SEs have a Mass Storage System (MSS) backend, with proper backups and tape migration policies, being able to guarantee the storage and availability of the data.

Page 8: Data Management In Grids

Griglie Computazionali Data Management 8

Storage Element: interfaces

• These SRM and I/O interfaces will make use of many third-party storage and protocol components, but exposing a uniform interface to the client should keep the client shielded from local peculiarities. All the different semantics of different storages should be exposed in the information system and through site policy to control the access and the capabilities of the resource.

• The SE has three external interfaces: 1. GridFTP, 2. SRM 3. a native POSIX-like file I/O interface.

Depending on the underlying storage system, the SE may support more than one protocol to access the files. The list of examples for storage and I/O in the picture is non-exhaustive.

Page 9: Data Management In Grids

Griglie Computazionali Data Management 9

Storage Element: functionality (4/5)

• Storage space for files. – In an SE there is a certain amount of space available to store file-based data.

• Storage Resource Management (SRM) interface. – The SE has a standardised interface to manage the underlying storage resource.

Currently this is mainly for staging files from/to disk to/from other media.

• Storage space management. – The SE may provide a means to manage the available space through mechanisms

such as quotas, file lifetime management, space reservation, etc.

• POSIX-like I/O access to files. – The SE provides an interface that can be used to access the files directly through

some supported protocol.

• File Transfer requests. – File Transfer Service controls the data influx into the SE from other SEs.

Page 10: Data Management In Grids

Griglie Computazionali Data Management 10

Storage Element (5/5)

• Functions:– File I/O service: needed by

the end-user application in order to access its data

– SRM service implementation on the given storage

– Transfer service for various transfer protocol(s)

– Auxiliary Security and Logging services

– Storage back-end with all the associated hardware and drivers

Collective

Application

Fabric

Connectivity (e.g. GridFTP)

Resource(SRM, file I/O)

Grid Architecture

StorageElement

Page 11: Data Management In Grids

Griglie Computazionali Data Management 11

Storage space types (1/3)

• Volatile or Temporary Space:– Data stores that provide temporary space semantics make little guarantee for

the data in storage. These are also sometimes called opportunistic stores or scratch spaces.

– Data stored in temporary space may disappear anytime.

– Such spaces are usually much easier to provide than permanent storage spaces.

– The security considerations of volatile space may also be much more relaxed, although the data stored in volatile space may also be well secured through proper authorization and authentication.

– Obviously, data stored in temporary space should not include master or primary copies of the data or important pieces of data that must not be lost. Such data stores may be used also to provide data caches.

– The concept of volatile space is not to be confused with data lifetime management; this is a property of the storage space, not of the data.

Page 12: Data Management In Grids

Griglie Computazionali Data Management 12

Storage space types (2/3)

• Permanent Space: – Data stores may provide storage space where the data can be kept

permanently or if in addition data lifetime management is provided, up to the guaranteed lifetime of the data.

– The data is not lost for the lifetime of the data.

– Some storage may provide ‘infinite’ lifetime semantics, in which case the storage takes care of migration to new technologies, etc.

– Of course the more guarantees are taken, the more expensive will the management of the data become, so the usage of permanent stores is usually more expensive than the usage of volatile space.

– For important data and for master copies, permanent storage should be used.

Page 13: Data Management In Grids

Griglie Computazionali Data Management 13

Storage space types (3/3)

• Durable Space: – The concept of durable space is introduced to describe a very specific use

case: when important, not to be lost data is being produced at a site where no permanent storage is available, the data must not be lost before it is transferred off-site to its final, permanent location. Durable Space provides these semantics.

– It will guarantee the safeguarding of a file until it has been moved to another ’safe’ place. Of course this guarantee has its limits, but it is better than pure temporary space.

– Durable space is not as ‘cheap’ as temporary space since important data that has not been migrated yet must not be lost. Durable data semantics supersede lifetime management.

– semantics: durable data may not be removed even if its lifetime has expired if it has not been migrated to permanent store yet.

Page 14: Data Management In Grids

Griglie Computazionali Data Management 14

2. Data scheduler

• Local data access:– Data is usually co-located (co-scheduled) with the application that needs it. In order

to be able to do so, the Grid job scheduler needs to invoke the a Data Scheduler service.

– The data scheduler makes sure that a given file is available at the chosen site where the job is to be run.

• Remote data access:– Job and file co-scheduling may not be always possible, so it may be necessary to

access the data remotely in which case the file I/O is used and acts as a proxy service of the Data Scheduling.

SECPUJob:

Open(<file>)

Computing Element

DataScheduler

CPUJob:

Open(<file>)

Computing Element

SE

Local data access Local data access with scheduler

1

2

1

23

4

SE

(local) (remote)

Page 15: Data Management In Grids

Griglie Computazionali Data Management 15

File naming (1/3)

• Files (and in general, data) may be replicated at many Grid sites if they are heavily used.

• We refer to file replicas (as opposed to file copies) if the instances of a given file are being tracked by the Replica Catalog (RC).

• The user application does not need to know which locations these are as long as it is able to run and read the data as if it were local.

• Therefore the name by which the user refers to the file has to be a location-independent logical file name (LFN). The users will only operate on this LFN namespace, as if it was a virtual file system.

• Upon creation, each file also acquires an immutable Grid Unique ID (GUID). The GUID is unique by construction.

• The applications may use either the LFN or GUID to identify their files:– GUID always mandated by the system

– LFN assigned by the users.

• Some files may not have LFNs at all.

Page 16: Data Management In Grids

Griglie Computazionali Data Management 16

File Naming (2/3)

• The LFN is the key by which the users usually locate the actual locations of their files.

• The replicas are identified by Site URLs (SURLs). Each replica has its own SURL, specifying implicitly which Storage Element needs to be contacted to extract the data. The SURL is a valid URL that can be used as an argument in an SRM interface. An example SURL is:

srm://castorgrid.cern.ch:8443/srm/managerv1?SFN=/castor/cern.ch/file1

• Usually, users are not directly exposed to SURLs, but only to the logical namespace defined by LFNs.

• The Grid Catalogs provide mappings needed for the services to actually locate the files.

• To the user the illusion of a single file system is given.

SRM end-point

Site URL (SURL)

Page 17: Data Management In Grids

Griglie Computazionali Data Management 17

File naming (3/3)• LFN (Logical File Name):

– A logical (human readable) identifier for a file. LFNs are unique but mutable, i.e. they can be changed by the user. The namespace of the LFNs is a global hierarchical namespace.

– Each Virtual Organisation can have its own namespace (everybody in the VO needs to agree with this convention).

– One LFN may have many of symbolic links pointing to it. Symbolic links have to be specified using absolute paths.

• GUID (Global Unique Identifier): A logical identifier, which guarantees its uniqueness by construction.

– Each LFN also has a GUID (1:1 relationship). – GUIDs are immutable, i.e. they cannot be changed by the user, otherwise consistency cannot be assured.

• SURL (Site URL) specifies a physical instance of a file replica. Also referred to as the Physical File Name (PFN).

– SURLs are accepted by the Storage Element’s SRM interface. Their schema is therefore srm. – A file may have many replicas, hence the mapping between GUIDs SURLs is 1:N.

• StURL (Storage URL) is another term used by the SRM specification, for the actual file name inside the storage system. To the Storage:

• the Site URL is a logical name;• StURL is the real location of the file on disk.

• TURL (Transport URL) It is a URL that can be used to actually transfer a file using any standard transport protocol.

– The TURL is a fully qualified URL starting with the protocol to be used for transfer.

Page 18: Data Management In Grids

Griglie Computazionali Data Management 18

Logical file names

• The LFN is the name of a file in the VO-internal logical namespace, organised in a hierarchical directory structure. A valid LFN might be a string like:

/glite/myVO.org/production/run/07/123456/calibration/cal/cal-table100

• The logical namespace has to be unique.

• The grid service component storing the logical namespace is the File Catalog.

• If the same catalog is to be shared among several Virtual Organisations, they are well advised to agree on some naming conventions for some of the logical hierarchy, as it is the case for most distributed file systems.

• It is conceivable that VOs sharing the logical namespace agree on prefixing their respective branches by a unique VO name (this of course means that VO names themselves have to be unique).

Page 19: Data Management In Grids

Griglie Computazionali Data Management 19

Directories in Logical File Namespace

• We define the concept of a directory in the LFN namespace. The directory may be manipulated just as in a normal file system:– It can be listed in the same manner as traditional directories, – new entries may be made to it – existing entries renamed and removed.– A user can copy logical files from other logical directories into their own

directory.

• The LFN contains the directory structure that can be navigated in such a manner to reference all the logical files for a given VO.

• Symbolic links may be set to other directories. – Symbolic links have to be specified using absolute paths. – They have the same semantics as the Unix file system symbolic links, i.e.

their consistency is weak and they might point to non-existing LFNs. – Any operation on the target LFN does nothing to update the link.– Symbolic links can create cycles, etc.

Page 20: Data Management In Grids

Griglie Computazionali Data Management 20

Grid unque ID (GUID)• The LFN and GUID are both unique but with the important difference that:

– LFN human-readable and mutable

– GUID is neither.

• Some VOs may enforce the policy of immutable LFNs in which case there is no semantic difference, except that:

– LFN namespace hierarchically grouping the files

– GUID namespace flat.

• The internal GUID does not need to be known by the users who will usually only see the human readable LFN.

• The GUID is necessary to allow us to distribute the catalog content across the wide area.

• By keeping the GUID immutable, the distributed catalog can detect accidental duplication of LFNs should they occur:

– A batch farm producing some output is disconnected from the wide area network and registers a new file (and a new LFN) in its local File Catalog.

– Upon reconnection, the local File Catalog instance tries to re-sync with the rest of the world, and finds the LFN already registered.

– The typical resolution would be to assign a different LFN to the file. In general, the application should take reasonable steps to ensure that the LFN is unique.

Page 21: Data Management In Grids

Griglie Computazionali Data Management 21

Catalogs (1/4)• File Catalog (file name used: LFN and GUID)

– allows for operations on the LFN namespace that it manages.

– Management of GUID LFN mapping

– OPERATIONS:1. making directories,

2. renaming files

3. creating symbolic links.

• Metadata Catalog (file name used: LFN)– Metadata is by definition data about data, i.e. it needs to have a point of

reference to which it provides additional information.

– Based on the LFN, the file may have additional metadata associated with it.

– OPERATIONS:1. Set and get metadata

2. Query metadata

Page 22: Data Management In Grids

Griglie Computazionali Data Management 22

Catalogs (2/4)

• Replica Catalog (file names used : GUID and SURL)– The Replica Catalog exposes operations concerning the replication aspect of

the grid files.– The “master replica” is a flag for a SURL (in the File catalog) which may be

used to flag a SURL as the only replica where update operations are allowed. This may then also be the only source for replications

– OPERATIONS: 1. List replicas (GUID list of SURLs)2. add and remove replicas to a file (GUID)

• Combined Catalog – All operations that need synchronised and consistent (ATOMIC) access to

at least two catalogs, such as creation of virtual directories, creation of new files and deletion.

– The Combined Catalog needs to maintain a persistent state of all operations it performs across catalogs in order to make sure that the operations only occur in a synchronised manner.

Page 23: Data Management In Grids

Griglie Computazionali Data Management 23

Catalogs (3/4)

Page 24: Data Management In Grids

Griglie Computazionali Data Management 24

Catalogs (4/4): mappings

Page 25: Data Management In Grids

Griglie Computazionali Data Management 25

Virtual directories

• A virtual directory is a special directory created from a metadata query. – A user defines a metadata query whose output is a set of logical files that are

then made accessible through the virtual directory as symbolic links.

• Only a limited set of operations are available in such directories.

• The result of a query is stored in the File Catalog, so whenever the user issues the list command, the same stored results are retrieved.

• In order to refresh the contents of the directory, a virtual directory refresh has to be issued explicitly.

Page 26: Data Management In Grids

Griglie Computazionali Data Management 26

LFNs and metadata

• each file in a directory shares the same metadata schema.

• /grid/MyVO/home/data/set1 and /grid/MyVO/home/data/set2 both have the schema S1, ie. all files in these two directories may have AttributeA, AttributeB and AttributeC set.

• Queries on metadata may be scoped on either the schema or the directory, returning files from either – 1. a set of directories or

– 2. all files sharing the same schema.

• A directory may have more than one schema table.

MetadataFiles

Page 27: Data Management In Grids

Griglie Computazionali Data Management 27

Catalog deployment

Catalogs may also be distributed over many sites or just deployed as a single central instance:

• CENTRAL APPROACH: – PRO: offers maximum consistency – CONS: is a single point of failure which is generally to be avoided in a distributed

Grid. • DISTRIBUTED APPROACH:

1. PARTITIONING• each partition or branch of the catalog may be stored at a separate location. The filesystem

analogy is that of mount points: each remote catalog is like a separate disk in the same overall namespace.

• site local catalog having all information on local files and using a messaging infrastructure to communicate between the catalogs using a publish-subscribe mechanism. These two mechanisms may of course be combined – the messaging distribution may just be used for a given branch of the catalog.

2. CATALOG REPLICATION to many sites• It is possible to share services across VOs, but we expect that each VO has its

own set of catalog services.• Bulk operations are preferable, as they minimize the overhead introduced to

establish a connection.

Page 28: Data Management In Grids

Griglie Computazionali Data Management 28

4. Grid I/O

• Grid data services provide an abstraction that is being presented as a global file system, with very similar semantics.

• A client user application may look like a Unix shell which can seamlessly navigate in this virtual file system, listing files, changing directories, etc.

• The most important Grid I/O API enables user applications to:– open, read, write and seek through their files,

– using just the LFN or GUID as the file name to open the data.

Page 29: Data Management In Grids

Griglie Computazionali Data Management 29

Grid I/O mechanism

Step 1: The client’s POSIX I/O request is received (the I/O client library accepts either LFN or GUID as an input to the API).1- The client of the Grid I/O will have to have a Grid certificate, signedby his VOMS server. 2- In addition, the client will have to find the proper I/O server to talk to through the Service Discovery services.

Page 30: Data Management In Grids

Griglie Computazionali Data Management 30

Grid I/O mechanism

Step 2: file access authorization (Grid ACL enforcement) – combining steps 2 and 3 is possible if FAS and Catalog interfaces are implemented by the same service

Page 31: Data Management In Grids

Griglie Computazionali Data Management 31

Grid I/O mechanism

Step 3: returns the actual SURL

Page 32: Data Management In Grids

Griglie Computazionali Data Management 32

Grid I/O mechanism

Steps 4 and 6: SE interactions through the SRM and native I/Oprotocols

Page 33: Data Management In Grids

Griglie Computazionali Data Management 33

Grid I/O mechanism

Steps 5 and 7: The SE makes sure the client is authenticated and authorized locally

Page 34: Data Management In Grids

Griglie Computazionali Data Management 34

Grid I/O: file creation

• APPROACH 1: if a new file is created through the gLite I/O open() command, it has to be: – declared what kind of file the system is supposed to create (see discussion

about file access patterns below).

– A new GUID will be allocated by the system (in order to avoid inconsistencies).

– Associated file metadata may have to be added as well. Such a creation is not as efficient as the first method.

• APPROACH 2:– However, it is also possible to create the file locally outside of the Grid

efficiently, and to move it into the Grid through the gLite I/O CLI.

– There is a glite-put and glite-get utility available in order to do

Page 35: Data Management In Grids

Griglie Computazionali Data Management 35

PART II

Data movement

Page 36: Data Management In Grids

Griglie Computazionali Data Management 36

Data movement

• Definition The data movement services provide scalable and robust managed data transfer between Grid sites, to and from Grid storage.

• Components:– Data scheduler

– File transfer and File Placement Services

– Transfer agent

– Transfer queue

Page 37: Data Management In Grids

Griglie Computazionali Data Management 37

Components (1/3)

Data Scheduler It accepts high-level transfer requests, where the user does not specify 1. the source replica, or 2. even the destination of any given transfer.– From the VO’s point of view the Data Scheduler is a single central service. It may

actually be distributed and there may be several of them, but that depends on the implementation.

File Transfer/Placement Service may get transfer requests from the user directly or through the Data Scheduler. The difference between a transfer and placement service is only their connection to the catalog.TRANSFER SERVICE: does not provide LFN and GUID resolution into SURL/TURLs.

Transfer Queue It keeps track of all ongoing transfers and may also be used to keep a transfer history, for logging and accounting purposes.– The transfer queue is persistent and is not tied to a site, but rather to a (set of)

connections, which are wide area network channels (links).

Transfer Agent gets the next transfer job out of the queue and reorders the queue according to site and VO policies The transfer agent again is tied to both the network channels and the VOs

Page 38: Data Management In Grids

Griglie Computazionali Data Management 38

Components (2/3)

Page 39: Data Management In Grids

Griglie Computazionali Data Management 39

Components (3/3)

• The Data Scheduler is a high-level component. • There may be many File Placement Services around, acting as interfaces to put

requests into the Transfer Queues.• Each File transfer queue comprises one sub-queue for every channel associated to

the corresponding file placement/transfer service

Data schedulerVO 1

Data schedulerVO 2

Data schedulerVO n

File placement/transferService_1

File placement/transferService_2

File placement/transferService_3

Tx queue File placement/transferService_4

Tx queue

Tx queue

Tx queue

Page 40: Data Management In Grids

Griglie Computazionali Data Management 40

Data scheduler

The Data Scheduler (DS) is the high-level service that keeps track of most ongoing WAN transfers inside a VO.

• The DS schedules data movement based on user requests.

• Users and the job scheduling system will contact the DS in order to move data in a scalable, coordinated and controlled fashion between two SEs.

Page 41: Data Management In Grids

Griglie Computazionali Data Management 41

Data scheduler components

• VO Policies which can apply policies with respect to data scheduling. These may include:– priority information / preferred sites / recovery modes / security considerations. – global VO policies (fetched from some configurable place) where the same global

policy may apply for many VOs.

• Data Scheduler Interface The actual service interface that the clients connect to, exposing the service logic. All operations that the clients can use are exposed through this service.

• Task Queue holds the list of transfers to be done. – The queue is persistent and holds the complete state of the DS, so that operations can

be recovered if the DS is shut down and restarted.– This queue is the heart of the DS, all services and service processes operate on this

persistent queue.

• Optimisers A set of modules to fill in missing information (like the source to copy from), or modifying the details of a request based on some algorithm (such as the protocol or the source replica to be used).

Page 42: Data Management In Grids

Griglie Computazionali Data Management 42

File transfer and placement service (1/2)• There is no difference between the FTS and FPS service in terms of

functionality, except that the FPS accepts LFNs and GUIDs in its interface and resolves them through the Grid Catalogs whereas the FTS does not.

• The FTS and FPS receive requests either through their Web Service interface directly from the clients or indirectly through the Data Scheduler. If the request cannot be managed by the local service, it may be forwarded to a known Data Scheduler for further processing.

• Once a request is accepted, it is simply put into the associated File Transfer Queue. If the request came through the FPS interface, the LFNs and GUIDs are first resolved through the catalog, and only the resolved names (SURLs) are put into the persistent queue. However, it is made sure that FPS requests also are updating the proper replica catalogs after successful transfer.

Page 43: Data Management In Grids

Griglie Computazionali Data Management 43

File transfer and placement service (2/2)

• The transfers managed by the FTS/FPS are all asynchronous, i.e. the client submits a transfer ’job’, which may contain a list of files (with proper source and destination qualifiers) to be transferred. The FTS/FPS assigns a unique string identifier to the job if it is accepted.

• The states of the whole job and the states of the individual files (that can be tracked using this ID) are NOT the same: the reason for the difference is that there may be many files to be transferred in a single job.

Page 44: Data Management In Grids

Griglie Computazionali Data Management 44

Operations

• 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) files 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 SURLs 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

Page 45: Data Management In Grids

Griglie Computazionali Data Management 45

Basic concepts: job

• Job A job or transfer job consists of a set of files to be transferred. A job contains:– a list of Files (source / destination pairs);

– an optional parameters key/value pair block, for passing options to the underlying transport layer.

– Example of options, which are then passed to the gridFTP command line: gridFTP parameters for TCP buffer size and number of streams. If present, the key must be for example:

{gridFTP, (-tcp-bs, 1000), (-p, 20)}

• Options are advisory to the service. If not specified, the service defaults are used.

• a MyProxy password - this will be used together with the client’s subject name to retrieve the user’s proxy to be used for the transfer.

Page 46: Data Management In Grids

Griglie Computazionali Data Management 46

Transfer job states: a job may comprise many files

Page 47: Data Management In Grids

Griglie Computazionali Data Management 47

States for a file that is being transferred

Page 48: Data Management In Grids

Griglie Computazionali Data Management 48

Transfer channels (1/2)

The Data Movement services need to interoperate and manage two basic resources: Storage and networking. For the network side, we use the concept of network channels.

• Channels may be dedicated or shared resources.

• The channel is unidirectional.

• Each channel has its own queue in a File Transfer Queue, which is managed by at least one File Transfer Agent.

Page 49: Data Management In Grids

Griglie Computazionali Data Management 49

Transfer channels (2/2)

The following channel states are defined (explained by referring to the two FTA Actors defined above):

• Active The Allocator is looking for work to assign to a channel and the Trigger is looking for work in that channel to be put on the wire.

• Drain The Allocator will not add anything new to a channel but the Trigger will continue to serve jobs that have been assigned to its channel. The effect is to drain all pending transfers from the channel.

• Inactive The Allocator will assign work to a channel but the Trigger will not put any more jobs on the wire. This is used by a sysadmin to empty the network. Note that jobs currently active on the wire will complete.

• Stopped Neither the Trigger or Allocator will do any work. Nothing will be assigned to the channel and no work will be put on the wire. Existing jobs on the wire will complete.

• Halted A serious error has been detected on the channel (e.g. there have been a certain number of ’sequential’ failures on the channel in the last few minutes) and that the channel has been automatically stopped by some monitoring process. When a channel is halted an alarm should be raised to alert an operator for manual intervention. This state is designed to prevent the transfer queue draining in case of problems.

Page 50: Data Management In Grids

Griglie Computazionali Data Management 50

Example: single channel

Page 51: Data Management In Grids

Griglie Computazionali Data Management 51

Example: multiple channels

Single set of servers canmanage multiple channelsfrom a site

Channels

Channels

Page 52: Data Management In Grids

Griglie Computazionali Data Management 52

File transfer agent

• For each transfer queue, we have at least one file transfer agent which is a set of actors (i.e. processes), which are periodically executed to operated on the queue.

• There are two kinds of views: channel and VO views. 1. The channel view will expose all transfers relevant for a given channel;

2. the VO view will show all transfers associated with a certain VO.

• Each channel configured on the site has at least two File Transfer Agents:– One Channel Agent.

– One VO Agent is needed for each VO that is authorized to perform data transfer requests on that given channel.

• 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.

• All of these agents share the same Queue. 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:

Page 53: Data Management In Grids

Griglie Computazionali Data Management 53

Actors (1/2)

• Standard FTA Actors will:– resolve names,

– apply VO policy and channel policy,

– trigger and monitor the actual file transfer

– change the state in the queue if the state of the transfer has changed.

• Examples. The Channel File Transfer Agent includes: – the Channel Allocator Actor: looks for work to assign to a certain channel.

– the Transfer Trigger Actor actually triggers the transfers based on the parameters set for the channel configuration (e.g. number of parallel streams, socket sizes etc.)

Page 54: Data Management In Grids

Griglie Computazionali Data Management 54

File transfer queues, agents and actors in case of multiple channels

File Transfer Queue_1

Transfer trigger actor

Channel AgentChannel allocator actor

Channel_1

FTS(Channel_1)

FTS = {Channel Agent, ( VO_Agent_1, ..., VO_Agent_n)}; Channel Agent = {Channel_Allocator_Actor, Transfer_Trigger_Actor}

VO Agent n

VO Agent 2

VO Agent 1

...

Page 55: Data Management In Grids

Griglie Computazionali Data Management 55

File transfer queues, agents and actors in case of multiple channels

• For each channel there is one VO agent for every authorized VO and one Channel Agent.

• Both the VO and the Channel agents are examples of “File Transfer Agents”.

• The FTS is deployed per physical channel, where the channel actually is unidirectional:– E.g. in an infrastructure graph where you have 10 links, you would have 20

FTS instances (the FTS instance can be run at one of the ends of the link) and each FTS runs one agent per VO.

Page 56: Data Management In Grids

Griglie Computazionali Data Management 56

Application-layer services

• it is straightforward to put additional convenience services in place, usually in the application layer. An example is a component that automatically schedules data transfers based on some trigger or event. – The event may be application specific or it may be linked through the

catalogs (new entries) or from the SE (new data) or other monitoring services.

– The auto-scheduling service would place new requests into either the local FPS or the global DS periodically whenever the event is triggered.

• It is also possible to extend the FTS/FPS and the File Transfer Agent by implementing custom actions directly into the FTA, which are executed periodically and may be used to enforce some special policy (reordering the queue) or to add additional tasks (register data and metadata in application specific catalogs), etc.

Page 57: Data Management In Grids

Griglie Computazionali Data Management 57

PART III

Security in Data management

Page 58: Data Management In Grids

Griglie Computazionali Data Management 58

Security

• All of the services share the same security infrastructure. In a Grid, resources owners are either sites or Virtual Organizations (VO).

• All users have to acquire an X.509 credential from their Certificate Authority (CA). The certificate will have a unique Distinguished Name (DN) for each user.

• With this personal certificate, users have to become member of one or more VOs. Before any user is able to perform any operation, they have to acquire a short-lived proxy certificate, and have it signed by at least one VO Membership Service (VOMS) which will append all the capabilities the user has in the given VO (like which group she belongs to, etc) to the user’s proxy certificate. It is with this VOMS proxy certificate which will be used to contact the data management services.

• Authentication – is done the usual X.509 way: if the CA the user has gotten his certificate from is trusted by the

site running the service, the user will be authenticated.

• Authorization – the data management services make use of either the DN or the VOMS attributes to authorize

the users to perform any given operation. – The access to the files are controlled by Access Control Lists (ACLs) for which the user’s DN or

VOMS membership and role attributes are used to identify the client. – The file I/O and Grid Catalogs will enforce the ACLs.

Page 59: Data Management In Grids

Griglie Computazionali Data Management 59

Access Control Lists

• There are two possibilities of how ACLs may be implemented:– POSIX-like ACL

• The POSIX semantics follow the Unix filesystem semantics.

• In order to check whether the user is eligible to perform the requested operation, all of the parent ACLs need alsobe parsed.

– NTFS-like ACL • The Microsoft Windows (and ex-VMS) semantics are simpler.

• The ACLs are stored with the file and the branch has no effect on the ACL. These are

Page 60: Data Management In Grids

Griglie Computazionali Data Management 60

Security interactions

Green: service managed by the VOBlue: service managed by a Grid site administrator

Page 61: Data Management In Grids

Griglie Computazionali Data Management 61

Security interactions

C1: The Client first needs to acquire a VOMS proxy by issuing voms-proxy-init. The VOMS serverreturns a signed VOMS proxy, with some additional fields in the proxy.

Page 62: Data Management In Grids

Griglie Computazionali Data Management 62

VOMS

• Information relevant from the VOMS proxy certificate:– DN The DN provided in the user certificate identifies the user. Its

uniqueness within its VOMS domain is guaranteed by the VOMS server.

– VO The VO name is also provided as part of the VOMS proxy. This is an extension.

– Groups The user may be member of one or several VOMS groups. These groups are also provided as part of the VOMS proxy extension.

Page 63: Data Management In Grids

Griglie Computazionali Data Management 63

Security interactions

C2: The user can also put a long-lived certificate into a MyProxy server. ’Normal’ certificates last for a few hours (12 is the default), which may be insufficient for some tasks (like very long lastingdata transfers). Therefore a longer proxy can be acquired by the user upon request. However, along lasting proxy should not be used directly (otherwise the proxy concept would be useless) So it is kept in a MyProxy server, which uses it to extend the lifetime of short-lived proxy certificates. The lifetime of the short proxies may of course be only extended up to the total lifetime of the long-lived proxy.

Page 64: Data Management In Grids

Griglie Computazionali Data Management 64

Security interactions

C3 and C4:C3 After having acquired a proxy and optionally having placed a long-lived one into MyProxy, the user can contact the service Grid I/O or File Transfer/Placement Service), which will successfully authenticate and authorize the user if the credential is valid. C4 Although the user may not be aware of this process, the useralso delegates his credential to the server so that it can further process the request on the user’s behalf.

Page 65: Data Management In Grids

Griglie Computazionali Data Management 65

Security interactions

S1 and S2:S1Authorization: it also contacts the File Authorization Service (FAS) using the user’sdelegated credentials (from C4). It is as if the user would contact the FAS himself. The FAS willauthorize the operation, i.e. whether the given file may be accessed, read or written by the user.The FAS takes the DN and the Groups of the user into account.S2 proxy renewal: requests sit on the Transfer Queue for hours. If the user’sdelegated proxy nears expiration, a Transfer Agent Actor will contact MyProxy and ask for arenewed proxy

Page 66: Data Management In Grids

Griglie Computazionali Data Management 66

Security interactions

S3:VOMS signatures and attributes may need to be renewed as well, since they expire also periodically; so the same Actor also has to call VOMS to fill in the necessary attributes in order to get a fully renewed VOMS proxy. These two steps are not necessary in the synchronous Grid I/O case.

Page 67: Data Management In Grids

Griglie Computazionali Data Management 67

Security interactions

S4:if the user’s certificate is valid and not expired, the server will contact the SE (either its native I/O or GridFTP or SRM interface) using the user’s delegated proxy and will try to access the data.

Page 68: Data Management In Grids

Griglie Computazionali Data Management 68

Security interactions

S5:for each access the SE also authorizes and maps the userlocally (based on the certificate it’s being handed with the request) by contacting the site-local (blue) authorization and mapping service.

Page 69: Data Management In Grids

Griglie Computazionali Data Management 69

References

• Kunszt, P. et al.; EGEE Middleware Architecture and planning, EGEE Project Deliverable EGEE-DJRA1.1-594698-v1.0, Jul 2005 (https://edms.cern.ch/document/594698/)

• Space Reservation Management (SRM) Interface v. 2.1.1 (http://sdm.lbl.gov/srm-wg/doc/SRM.spec.v2.1.1.html)