lcg-ls(1) - Linux man page

Name

lcg-ls - list file information for given SURLs or LFNs

Synopsis

lcg-ls [ -h,--help ] [ -v,--verbose ] [ --connect-timeout "timeout" ] [ --sendreceive-timeout "timeout" ] [ --bdii-timeout "timeout" ] [ --srm-timeout "timeout" ] [ -D,--defaultsetypedefaulttype ] [ -T,--setype setype ] [ -b,--nobdii ] [ -l,--long ] [ -c,--count ] [ -o,--offset ] [ -d,--dir ] [ --vo virtual_organization ] [ --version ] file [...]

Description

lcg-ls lists the directory contents. If you specify a given command line option multiple times, the command takes into account only the very last one so that in a script, you can override a particular option in a pre-set option set (like gcc does).
--connect-timeout
Sets the connect timeout, used when connecting to a remote host. The connection will be aborted if the remote host doesn't reply after value seconds. Default: 60 seconds.
--sendreceive-timeout
Sets the send/receive data timeout, used when transferring data to/from a remote host. The connection will be aborted if no data is transfered after value seconds. Default: 0 (blocking).
--bdii-timeout
Sets the BDII timeout, used when searching information into BDII. The connection will be aborted if the search is longer than value seconds. Default: 60 seconds.
--srm-timeout
Sets the SRM timeout, used when doing an asynchronous SRM request. The request will be aborted if it is still queued after value seconds. Default: 3600 seconds (1 hour).
file
Can be a SURL or a LFN. Note that all files must have the same type (SURL, LFN), and in case of SURLs, they have to be from the same SRM endpoint (the request will be sent to the SRM endpoint of the first SURL). A SURL scheme can be sfn: for a classical SE or srm:.
defaulttype
specifies the default SE type you want to use. Possible values are none, se, srmv1, srmv2, for respectively no default type, classic SE, SRMv1, and SRMv2. But if according to the BDII the default type is not available for this SE, it will use another type.
setype
specifies the SE type you want to use. Possible values are none, se, srmv1, srmv2, for respectively no type, classic SE, SRMv1, and SRMv2. But if according to the BDII the default type is not available for this SE, it will fail.
-b,--nobdii
If this flag is present, it means that you don't want to make BDII calls to get SE type. So, you must provide the type of the SE for srm: arguments, and full endpoint in SURLs. For SE type, defaulttype can be used.
-c,--count
Ignored if the file is not an SRM. List "count" number of files only. Using with "offset", you can retrieve long list of files in chunks.
-o,--offset
Ignored if the file is not an SRM. Skip the first "offset" number of files in the list. Using with "count", you can retrieve long list of files in chunks.
-l,--long
use long listing format. The displayed fields depend on the file type. In case of LFN the fields are: file mode, number of links to the file, user id, group id, file size (bytes), file name. In case of SURL the fields are: file mode, number of links to the file, user id, group id, file size (bytes), locality, file name.
-d,--dir
does not list the directory contents, but shows information about the directory itself. This option is not compatible with Classic SEs.
-v,--verbose
Verbose mode. You can specify it twice for extra verbose mode.

Note

The environment variable LCG_GFAL_INFOSYS must point to the BDII, unless --nobdii option is used.

Example

    lcg-ls srm://lxpdm101.cern.ch/dpm/cern.ch/home
    /dpm/cern.ch/home/alice
    /dpm/cern.ch/home/atlas
    /dpm/cern.ch/home/cms
    /dpm/cern.ch/home/dteam
    /dpm/cern.ch/home/gin
    /dpm/cern.ch/home/gin.ggf.org
    /dpm/cern.ch/home/lhcb
    /dpm/cern.ch/home/ops

Exit Status

This program returns 0 if the operation was successful or >0 if the operation failed.

See Also

lcg-aa(1), lcg-cp(1), lcg-cr(1), lcg-del(1), lcg-getturls(1), lcg-gt(1), lcg-la(1), lcg-lg(1), lcg-lr(1), lcg-ra(1), lcg-rep(1), lcg-rf(1), lcg-sd(1), lcg-stmd(1), lcg-uf(1)

Referenced By

lcg-bringonline(1), lcg-get-checksum(1)