How to Access Files in SAM » History » Version 6

« Previous - Version 6/8 (diff) - Next » - Current version
Qizhong Li, 12/04/2014 08:50 AM

How to Access Files in SAM

To setup SAM:
> kinit
> kx509
> setup sam_web_client

To setup IFDH commands:
> setup ifdhc v1_6_2

To fetch one file from SAM using the file name:
> ifdh_fetch -e lbne filename

For example:

<> ifdh_fetch -e lbne v35t_r0000101_s0001_test_raw.root
found file on enstore, using dcache gridftp
doing: ifdh cp gsi ./v35t_r0000101_s0001_test_raw.root

<> ls *.root

To get all files from a dataset definition:
> /lbne/app/users/qzli/dhtools/ definition-name destination-location

For example:
<> /lbne/app/users/qzli/dhtools/ singleparticle-test /scratch/lbne/qzli/files/
Project name is qzli_singleparticle-test_20141203120539
Project URL is
<> ls /scratch/lbne/qzli/files/
35T_singleparticle_piplus_01.root  35T_singleparticle_proton_01.root