lcg_gt_python(3) - Linux man page
Name
lcg_gt - get the TURL for a given SURL and transfer protocolSynopsis
(int returncode, string turl, int reqid, int fileid, string token, string errmsg ) lcg_gt3 (string surl, string defaulttype, string setype, int nobdii, listOfString protocols, int timeout, string spacetokendesc);
Description
lcg_gt gets the TURL for a given SURL and transfer protocol.- surl
- specifies the Site URL. An SURL scheme can be sfn: for a classical SE or srm:.
- protocol
- specifies the protocol which will be used to access the file.
- protocols
- specifies the list of protocols which can be used to access the file. This list must end by the empty string.
- turl
- will be set by the routine to the address of the buffer which contains the TURL. This buffer should be freed by the application after use.
- reqid
- will receive the request identifier to be used to set the file state to "Running" or "Done".
- fileid
- will receive the file ordinal to be used to set the file state to "Running" or "Done".
- token
- will receive the request token to be used to set the file state to "Running" or "Done".
- timeout
- specifies the value of timeout(default 0)
- defaulttype
- specifies the default SE type you want to use. Possible values are TYPE_NONE, TYPE_SE, TYPE_SRM, TYPE_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 TYPE_NONE, TYPE_SE, TYPE_SRM, TYPE_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.
- nobdii
- If set to a non-zero value, 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.
- spacetokendesc
- specifies the space token to use with surl. Can be NULL.
Notes
The arguments (token, errbuf, errbufsz) are only meaningful if the space is managed by an SRM. The environment variable LCG_GFAL_INFOSYS must point to the BDII, unless nobdii is set to a non-zero value.Return Value
This routine returns 0 if the operation was successful or -1 if the operation failed. In the latter case, errno is set appropriately.Errors
- ENOENT
- The named file does not exist.
- EACCES
- Permission denied.
- EFAULT
- One of the arguments is an invalid pointer.
- EINVAL
- surl has an invalid syntax.
- ECOMM
- Communication error.
- ENAMETOOLONG
- The host name contained in surl is too long.
- EPROTONOSUPPORT
- Access method not supported.
Files
/opt/lcg/include/lcg_util.h- /opt/lcg/lib/liblcg_util.so