Last modified 13 years ago Last modified on 09/25/07 15:05:07

This is a Space Token Information Provider for dCache provided by Ron

SVN archive of Ron Space Token Info Provider

Here is the space token information provider for dCache for those who are interested. It needs psycopg2 which is a python wrapper for postgres. It can be installed anywhere but you need to symlink it to /opt/lcg/var/gip/provider/token_info_provider.

It collects the information from the srmspace table of the dcache database on the srm node. It selects reservations with state=0 (of which I think it means "reserved") and a creationtime+lifetime that is greater that the present time, or a lifetime that is -1, a vogroup that is not null and a description that is not null and not equal to srm2_t?d?. So you are basically left with the static reservations by the site admin.

The information that needs to be provided to the script is the information needed to access the srm door's postgres database. You could create a special user for this having only permission to do "select" on the srmspace table. Further, you need to provide the host name of the machine running the srm door and the generic path like /pnfs/<domainname>/data/.

By the way, according to the SrmSpaceManager cell, lifetime is in milliseconds. Further, it appears that the creationtime is local time instead of UTC which can give interesting effects when doing a space reservation when clocks are adjusted.

Provided by Ron Trompert : ron at sara dot nl