How to Publish Space Tokens with dCache

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.

Author: Ron Trompert - SARA

-- Flavia Donno - 25 Sep 2007

Edit | Attach | Watch | Print version | History: r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r1 - 2007-09-25 - FlaviaDonno
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    LCG All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback