Grid¶
The Grid module contains several utilities for grid operations
- DIRAC.Core.Utilities.Grid.executeGridCommand(proxy, cmd, gridEnvScript=None)¶
Execute cmd tuple after sourcing GridEnv
- DIRAC.Core.Utilities.Grid.getBdiiCEInfo(vo, host=None, glue2=False)¶
Get information for all the CEs/queues for a given VO
- DIRAC.Core.Utilities.Grid.ldapCE(ce, attr=None, host=None)¶
CE (really SubCluster in definition of bdii) information from bdii. It contains by the way host information for ce.
- Parameters
ce – ce or part of it with globing, for example, “ce0?.tier2.hep.manchester*”
- Returns
standard DIRAC answer with Value equals to list of clusters.
Each cluster is dictionary which contains attributes of ce. For example result[‘Value’][0][‘GlueHostBenchmarkSI00’]
- DIRAC.Core.Utilities.Grid.ldapCEState(ce, vo, attr=None, host=None)¶
CEState information from bdii. Only CE with CEAccessControlBaseRule=VO:lhcb are selected.
- Parameters
ce – ce or part of it with globing, for example, “ce0?.tier2.hep.manchester*”
- Returns
standard DIRAC answer with Value equals to list of ceStates.
Each ceState is dictionary which contains attributes of ce. For example result[‘Value’][0][‘GlueCEStateStatus’]
- DIRAC.Core.Utilities.Grid.ldapCEVOView(ce, vo, attr=None, host=None)¶
CEVOView information from bdii. Only CE with CEAccessControlBaseRule=VO:lhcb are selected.
- Parameters
ce – ce or part of it with globing, for example, “ce0?.tier2.hep.manchester*”
- Returns
standard DIRAC answer with Value equals to list of ceVOViews.
Each ceVOView is dictionary which contains attributes of ce. For example result[‘Value’][0][‘GlueCEStateRunningJobs’]
- DIRAC.Core.Utilities.Grid.ldapCluster(ce, attr=None, host=None)¶
CE (really SubCluster in definition of bdii) information from bdii. It contains by the way host information for ce.
- Parameters
ce – ce or part of it with globing, for example, “ce0?.tier2.hep.manchester*”
- Returns
standard DIRAC answer with Value equals to list of clusters.
Each cluster is dictionary which contains attributes of ce. For example result[‘Value’][0][‘GlueHostBenchmarkSI00’]
- DIRAC.Core.Utilities.Grid.ldapService(serviceID='*', serviceType='*', vo='*', attr=None, host=None)¶
Service BDII info for a given VO
- Parameters
service – service type, e.g. SRM
- Returns
standard DIRAC answer with Value equals to list of services
- DIRAC.Core.Utilities.Grid.ldapSite(site, attr=None, host=None)¶
Site information from bdii.
- Parameters
site – Site as it defined in GOCDB or part of it with globing, for example: UKI-*
- Returns
standard DIRAC answer with Value equals to list of sites.
Each site is dictionary which contains attributes of site. For example result[‘Value’][0][‘GlueSiteLocation’]
- DIRAC.Core.Utilities.Grid.ldapsearchBDII(filt=None, attr=None, host=None, base=None, selectionString='Glue')¶
Python wrapper for ldapserch at bdii.
- Parameters
filt – Filter used to search ldap, default = ‘’, means select all
attr – Attributes returned by ldapsearch, default = ‘*’, means return all
host – Host used for ldapsearch, default = ‘cclcgtopbdii01.in2p3.fr:2170’, can be changed by $LCG_GFAL_INFOSYS
- Returns
standard DIRAC answer with Value equals to list of ldapsearch responses
Each element of list is dictionary with keys:
‘dn’: Distinguished name of ldapsearch response ‘objectClass’: List of classes in response ‘attr’: Dictionary of attributes