...
Code Block |
---|
-bash-4.2$ gfal-ls srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4 generated virgo RomePSS virgoin virgoout_O2LH_01_0127_067_-81.305_-90.000_.mat prova_lucia2 prova_lucia3 vedovato virgojob_summary_O2LH_01_0127_067_-81.305_-90.000_.mat virgoRomePSS testalbe vdbroeck prova_lucia prova_andrea -bash-4.2$ gfal-rm srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea DELETED -bash-4.2$ gfal-copy /home/USER-SUPPORT/arendina/sleep.sub srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea Copying file:///home/USER-SUPPORT/arendina/sleep.sub [DONE] after 2s -bash-4.2$ gfal-sum srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea ADLER32 srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea 2bca5372 |
For all the gfal commands see [16].
...
some experiments it is also possibile to use the https or davs protocol contacting directly the StoRM frontend in the same way, but some configuration changes of the gfal tool are needed on the client. In fact, the SRM plugin specifcs into the /etc/gfal2.d/srm_plugin.conf
file can be ordered as in the following example:
Code Block |
---|
# ordered list of turls protocols for remote I/O
# the top priority protocol is the first one
TURL_PROTOCOLS=davs;gsiftp;rfio;gsidcap;dcap;kdcap
# ordered list of turls protocols for third party transfer
# only protocol supporting third party copy should be here
# the top priority protocol is the first one
TURL_3RD_PARTY_PROTOCOLS=https;gsiftp;root |
For all the gfal commands see [16].
Anchor ClientSRM utils ClientSRM utils
ClientSRM utils
ClientSRM utils | |
ClientSRM utils |
In case of local to remote transfer, you have to request the storage space in the destination filesystem and this is done with the command clientSRM PtP
, where PtP stands for Prepare to Put. For example:
Code Block |
---|
$ |
...
In case of local to remote transfer, you have to request the storage space in the destination filesystem and this is done with the command clientSRM PtP
, where PtP stands for Prepare to Put. For example:
Code Block |
---|
$ clientSRM PtP -e httpg://storm-fe-archive.cr.cnaf.infn.it:8444 -s srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea |
where:
- -e is used to specify the endpoint.
- -s is used to specify the destination surl, which is composed by a space token (virgo4 in the example) and the file path. The space token will be communicated by the Experiment Support group.
- -v is the verbose level, further.
and the complete list of the options is listed by the command clientSRM PtP
-help
or in [17].
The output should be something like this:
Code Block |
---|
-bash-4.2$ clientSRM PtP -e httpg://storm-fe-archive.cr.cnaf.infn.it:8444 -s srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea |
where:
- -e is used to specify the endpoint.
- -s is used to specify the destination surl, which is composed by a space token (virgo4 in the example) and the file path. The space token will be communicated by the Experiment Support group.
- -v is the verbose level, further.
and the complete list of the options is listed by the command clientSRM PtP
-help
or in [17].
The output should be something like this:
Code Block |
---|
-bash-4.2$ clientSRM PtP -e httpg://storm-fe-archive.cr.cnaf.infn.it:8444 -s srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea ============================================================ Sending PtP request to: httpg://storm-fe-archive.cr.cnaf.infn.it:8444 Before execute: Afer execute: Request Status Code 17 Poll Flag 0 ============================================================ Request status: statusCode="SRM_REQUEST_QUEUED"(17)Sending PtP request to: httpg://storm-fe-archive.cr.cnaf.infn.it:8444 Before execute: Afer execute: Request Status Code 17 Poll Flag 0 ============================================================ SRMRequest Responsestatus: requestTokenstatusCode="51e58c63-afdd-4ccb-8a6d-8551b4261c33" arrayOfFileStatuses (size=1) [0] SURL="srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea" [0] status: statusCode="SRM_REQUEST_QUEUED"(17) explanation="" SRM_REQUEST_QUEUED"(17) =================================================================== |
...
SRM Response: requestToken="51e58c63-afdd-4ccb-8a6d-8551b4261c33 |
...
Code Block |
---|
clientSRM SPTP -v -e httpg" arrayOfFileStatuses (size=1) [0] SURL="srm://storm-fe-archive.cr.cnaf.infn.it:8444 -t 51e58c63-afdd-4ccb-8a6d-8551b4261c33 |
where with -t
you provide the token shown in the output of the clientSRM PtP
command. The output will show you whether the request is successful in the status field.
Code Block |
---|
-bash-4.2$ clientSRM SPTP -v -e httpg://storm-fe-archive.cr.cnaf.infn.it:8444 -t 51e58c63-afdd-4ccb-8a6d-8551b4261c33 /virgo4/prova_andrea" [0] status: statusCode="SRM_REQUEST_QUEUED"(17) explanation="" ==================================================================================== Sending |
It is important to pay attention to the request token (in this case 51e58c63-afdd-4ccb-8a6d-8551b4261c33
), which will be used later. Then it is necessary to check the status of the request with clientSRM SPtP
(Status of Prepare to Put) :
Code Block |
---|
clientSRM SPTP -v -e StatusPtP request to: httpg://storm-fe-archive.cr.cnaf.infn.it:8444 -t 51e58c63-afdd-4ccb-8a6d-8551b4261c33 |
where with -t
you provide the token shown in the output of the clientSRM PtP
command. The output will show you whether the request is successful in the status field.
Code Block |
---|
-bash-4.2$ clientSRM SPTP -v -e httpg://storm-fe-archive.cr.cnaf.infn.it:8444 -t 51e58c63-afdd-4ccb-8a6d-8551b4261c33 Before execute: Afer execute: Request Status Code 0 Poll Flag 0 ============================================================= Request status: statusCode="SRM_SUCCESS"(0) explanation="All chunks successfully handled!" ===Sending StatusPtP request to: httpg://storm-fe-archive.cr.cnaf.infn.it:8444 Before execute: Afer execute: Request Status Code 0 Poll Flag 0 ============================================================ SRMRequest Responsestatus: arrayOfFileStatuses (size=1) [0] SURL="srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea" [0] status: statusCode="SRM_SPACE_AVAILABLE"(24) explanation="srmPrepareToPut successfully handled!" [0] TURL="gsiftp://ds-815.cr.cnaf.infn.it:2811//storage/gpfs_virgo4/virgo4/prova_andrea" statusCode="SRM_SUCCESS"(0) explanation="All chunks successfully handled!" ============================================================ SRM Response: arrayOfFileStatuses (size=1) [0] SURL====="srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/prova_andrea" [0] status: statusCode="SRM_SPACE_AVAILABLE"(24) explanation="srmPrepareToPut successfully handled!" [0] TURL="gsiftp://ds-815.cr.cnaf.infn.it:2811//storage/gpfs_virgo4/virgo4/prova_andrea" ============================================================ |
It is important to remember the TURL which It is important to remember the TURL which will be used in transfer command with the globus-url-copy
command. After that, we can perform the file transfer:
...
A user is also able to delete a file using the SRM clients. An easy example follows below::
Code Block |
---|
[arendina@ui-tier1 ~]$ clientSRM Rm -e httpg://storm-fe-archive.cr.cnaf.infn.it:8444 -s srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/test2402
============================================================
Sending Rm request to: httpg://storm-fe-archive.cr.cnaf.infn.it:8444
Before execute:
Afer execute:
Request Status Code 0
Poll Flag 0
============================================================
Request status:
statusCode="SRM_SUCCESS"(0)
explanation="All files removed"
============================================================
SRM Response:
arrayOfFileStatuses (size=1)
[0] SURL="srm://storm-fe-archive.cr.cnaf.infn.it:8444/virgo4/test2402"
[0] status: statusCode="SRM_SUCCESS"(0)
explanation="File removed"
============================================================ |
More information on using SRM clients can be found here [18].
NB: For some VOs there is also the possibility to retrieve an https TURL using the ClientSRM utils. Indeed, this could be done adding the -T -P https
option, for instance:
Code Block |
---|
[arendina@ui-tier1 ~]$ clientSRM PtP -T -P https -e httpg://storm-fe-ams.cr.cnaf.infn.it:8444 -s srm://storm-fe-ams.cr.cnaf.infn.it:8444/juno/storm/prova_andrea
============================================================
Sending PtP request to: httpg://storm-fe-ams.cr.cnaf.infn.it:8444
Before execute:
Afer execute:
Request Status Code 17
Poll Flag 0
============================================================
Request status:
statusCode="SRM_REQUEST_QUEUED"(17)
============================================================
SRM Response:
requestToken="de8af950-9869-4e50-891f-a8510c36cfdd"
arrayOfFileStatuses (size=1)
[0] SURL="srm://storm-fe-ams.cr.cnaf.infn.it:8444/juno/storm/prova_andrea"
[0] status: statusCode="SRM_REQUEST_QUEUED"(17)
explanation=""
============================================================
|
Code Block |
[arendina@ui-tier1 ~]$ clientSRM RmSPtP -e httpg://storm-fe-archiveams.cr.cnaf.infn.it:8444 -s srm://storm-fe-archiveams.cr.cnaf.infn.it:8444/virgo4/test2402juno/storm/prova_andrea -t "de8af950-9869-4e50-891f-a8510c36cfdd" ============================================================ Sending RmStatusPtP request to: httpg://storm-fe-archiveams.cr.cnaf.infn.it:8444 Before execute: Afer execute: Request Status Code 0 Poll Flag 0 ============================================================ Request status: statusCode="SRM_SUCCESS"(0) explanation="All chunks filessuccessfully removedhandled!" ============================================================ SRM Response: arrayOfFileStatuses (size=1) [0] SURL="srm://storm-fe-archiveams.cr.cnaf.infn.it:8444/virgo4/test2402juno/storm/prova_andrea" [0] status: statusCode="SRMSRM_SPACE_SUCCESSAVAILABLE"(024) explanation="srmPrepareToPut successfully handled!" explanation="File removed[0] TURL="https://ds-510.cr.cnaf.infn.it:8443/juno/storm/prova_andrea" ============================================================ |
...