Kaseya Community

Detect DRAC card

  • Procedure Detect DRAC Card.xml

    Here's a script I use to detect if a DRAC card is installed on a server, and set a custom field with the results.  First, add the custom field 'DRAC Present', then run this procedure.  I tested it against about 30 different servers and got correct output.  Basically, it runs the command racadm getsysinfo and parses the output.  It actually runs it twice, first looking for the string 'IP Address' which will be present in the output if a DRAC card is installed.  The second time, it looks for the string UNKNOWN and if found, assumes there is NOT a DRAC card installed.  I added this second step because I had one server that was generating this output - it had a BMC controller installed, but not a DRAC card.  Your mileage may vary depending on they type of server, and the firmware revision of your DRAC card(s).




    [edited by: benny_pdx at 9:26 AM (GMT -7) on 7-11-2011] ** edited ** - added the XML as an attachment instead of inline.
  • Thanks!  We'll try it

  • Great script!!

    Do you know how to parse through the results so i can populate another custom field with the DRAC IP? its in the command output but dont know how to go about that....

  • I'm not 100% sure the best way to do this.  one way that comes to mind would be to output the results to a log file, and then build a log parser to parse the results.  I've only played with log parsers a little bit, but if i recall, the documentation is pretty good and can probably get you headed down the right direction.  

  • Hi, Greetings from mercy,

    My name is miss mercy,  l saw your profile today and after going through it

    then l made up my mind to contact you as my friend. so l want you to write back

    to me through my email address (mercysoumah81 @yahoo.com)

    so that l will give

    you my picture and for you to know more about me. l hope to see your mail soon.

    lt is from me,


  • Benny. Which documentation are you referring to?

  • Sorry, i was talking about the Kaseya documentation related to building log parsers.

  • Procedure Detect DRAC Card.xml

    Lovely script - thanks very much for posting.

    I've added functionality to log the IP address that's found. It now uses a custom field called "DRAC". It puts nothing in that field if there's no IP address found.

    I've only tested it on a couple of machines, so please do your own testing...


  • Tick the "Continue on fail" box for the line that creates the "IPAddress" variable, otherwise you'll get script failures for servers with no DRAC card, but other than that, it seems to work beautifully.

    Of topic, but if you want to use a log parser for anything, "Microsoft Log Parser 2.2" is VERY powerful, and not all that difficult to use because it uses a very SQL-like syntax. There are lots of examples online. Overkill for this example, but great in other situations.

  • Thanks for the script!

  • Cool, thanks for improving the script!