The following query will request all information from the top-level BDII at CERN.
[user@ui-node] $
ldapsearch -LLL -x -H ldap://lcg-bdii.cern.ch:2170 -b "o=grid"
dn: o=grid
objectClass: GlueTop
dn: Mds-Vo-name=local,o=grid
objectClass: GlueTop
dn: GlueLocationLocalID=VO-cms-CMSSW_1_2_2,GlueSubClusterUniqueID=hg.ihepa.ufl
.edu,GlueClusterUniqueID=hg.ihepa.ufl.edu,Mds-Vo-name=UFlorida-IHEPA,Mds-Vo-n
ame=local,o=grid
objectClass: GlueClusterTop
objectClass: GlueLocation
objectClass: GlueKey
objectClass: GlueSchemaVersion
GlueLocationLocalID: VO-cms-CMSSW_1_2_2
GlueLocationName: VO-cms-CMSSW_1_2_2
GlueLocationVersion: CMSSW_1_2_2
GlueLocationPath: /raid/raid4/grid01/app/cmssoft/cms
GlueChunkKey: GlueSubClusterUniqueID=hg.ihepa.ufl.edu
GlueSchemaVersionMajor: 1
GlueSchemaVersionMinor: 3
Please note that this query will generate a large amount of date.
Querying a MDS system is much the same, only the port 2170 is replace by port 2135.