/build/static/layout/Breadcrumb_cap_w.png

KACE Product Support Question


Creating groups of servers based on whether network card is DHCP or static.

02/17/2015 2140 views
Hello,

    In my current environment of servers some are Static and others are DHCP. I am looking to create a groups based on whether a server's network card is using a static IP address or DHCP. I noticed in the inventory section of Kace that the detail page for every machine has a NIC section that shows you whether or not your NIC is DHCP or Static. But when I go to create a smart label, there is no filter that includes the NIC as a parameter. Has anyone been able to write a script that can query each machine for its NIC details?
Answer Summary:
3 Comments   [ + ] Show comments

Comments

  • Thank You flip1001. This query worked great. I ran it under the reporting portion of my Kace appliance as a SQL command. Thanks Again!
  • Well, actually I created a smart label and then replaced the SQL in the smart label with the answer I posted.
  • OK that works too and gives me real time results. Thank You!

All Answers

1
Change DHCP Enabled to True or False and also change the IP to what your network uses. I put an IP otherwise you might pickup on virtual nics.

SELECT MACHINE.NAME AS SYSTEM_NAME, SYSTEM_DESCRIPTION, MACHINE.IP, MACHINE.MAC, MACHINE.ID as TOPIC_ID FROM MACHINE
WHERE (1 in (SELECT 1 FROM MACHINE_NICS WHERE MACHINE.ID = MACHINE_NICS.ID AND MACHINE_NICS.DHCP_ENABLED = 'False' AND MACHINE_NICS.IP LIKE '172.16.%'))
AND MACHINE.OS_NAME LIKE '%SERVER%'

Answered 02/17/2015 by: flip1001
Black Belt

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ