bin/pvl.hosts-snmp
changeset 407 3197d049f345
parent 403 9bae04e1780c
equal deleted inserted replaced
406:92a4de88b86f 407:3197d049f345
   276         else :
   276         else :
   277             raise Exception("No value for [%s] %s" % (host, attr))
   277             raise Exception("No value for [%s] %s" % (host, attr))
   278 
   278 
   279     # output
   279     # output
   280     for host, attrs in sorted(data.items()) :
   280     for host, attrs in sorted(data.items()) :
   281         print "{host}".format(host=host)
   281         print "{host}@{domain}".format(host=host, domain=host.domain)
   282 
   282 
   283         for attr, value in sorted(attrs.items()) :
   283         for attr, value in sorted(attrs.items()) :
   284             print "\t{attr}".format(attr=' '.join(str(a) for a in attr))
   284             print "\t{attr}".format(attr=' '.join(str(a) for a in attr))
   285 
   285 
   286             if isinstance(value, set) :
   286             if isinstance(value, set) :