01
Jul

Open a DOS box and run:

sfc /scannow

Next, open the Control Panel/Fonts, right click Install New Font, select all fonts in C:\Windows\Fonts and click Install.

Fonts are repaired now.

01
Jul

Go get a DOS or Win95 ISO image, such like from here, then go get HP’s USB disk storage format tool and, using HP’s format tool, build a bootable USB key.

HP USB Disk Storage Format Tool

25
Jun

Useful for setting loglevels with a higher degree of granulatity than just the “info”, “debug” and “error” options coming with the default logger.

def debugPrint(*debugStrings):
    try:
        logLevel = 1
        logMessage = '[LogHelper] '
        if type(debugStrings[0]) == type(DEBUGLEVEL):
            logLevel = debugStrings[0]
            for index in range(1, len(debugStrings)):
                logMessage = logMessage + str(debugStrings[index])
        else:
            logMessage = logMessage + ''.join(map(str, debugStrings))
        if DEBUGLEVEL >= logLevel:
            logger.debug(logMessage)
        if DEBUGLEVEL > logLevel:
            print logMessage
    except:
        excInfo = logger.prepareJythonStackTrace('')
        logger.debug('[debugPrint] Exception: <%s>' % excInfo)
        pass

25
Jun
  • @stittel Is die oppo van T K bij Rabo dat joppie voor 4 weken? #

,

25
Jun

This here is a way to read registry settings from uCMDB/DDM on remote Windows hosts using WMI. WMI exposes various classes, among which the stdRegistryProvider class which can be used to read in the remote registry, especially handy when remote registry access nor remote command execution are permitted. Using something like this it becomes possible to inventory things like policies, perhaps even SCOM objects. But that`s something for another day.

import re
import string
import sys
import logger
 
# Java imports
from java.lang import Boolean
from java.util import Properties
 
# MAM specific imports
from appilog.common.system.types import ObjectStateHolder
from appilog.common.system.types.vectors import ObjectStateHolderVector
from com.hp.ucmdb.discovery.library.clients.agents import AgentConstants
 
# This function queries the registry by a defined filter, using the given credentials
def getRegValues(wmiClient, keypath, filter):
  result = {}
  table = wmiClient.getRegistryKeyValues(keypath, 1, filter)
  keys = table.get(0)
  values = table.get(1)
  for i in range(keys.size()):
    key = keys.get(i)
    end = key.find('\\' + filter)
    key = key[0:end]
    logger.debug('[getRegValues] end is: ', end, ', key is: ', key, ', value is: ', values.get(i))
  result.update({key : values.get(i)})
  return result
 
def DiscoveryMain(Framework):
  OSHVResult = ObjectStateHolderVector()
  props = Properties()
  props.setProperty(AgentConstants.PROP_WMI_NAMESPACE, 'root\\DEFAULT')
  wmiClient = None
  wmiClient = Framework.createClient(props)
  regObject = getRegValues(wmiClient, 'SOFTWARE\\Microsoft\\Windows', Run')
  wmiClient.close()
  myKeys = regObject.keys()
  if len(myKeys) &gt; 0:
    for name in myKeys:
      value = regObject.get(name)
      logger.debug('------- Name is', name, '----- Value is: ', value)
  if wmiClient != None:
    wmiClient.close()
  return OSHVResult

, , , ,

22
Jun
  • Back from my brother`s 40th birthday party in Copenhagen. Great people, great food, great atmosphere, #
  • Never realized Windows Movie Maker was such a satisfactory movie editing tool for small presentations #

,

21
Jun

,

  • Search:
  • Random Quote

    “Believe me, I'm not going to try to get into testing.”
    by John Engler
  • My Friends Cloud

    WWWs from Friends