/build/static/layout/Breadcrumb_cap_w.png

Systems Management Question


SQL query based smart label

01/14/2020 365 views

I have used the SQL query from the report called "Devices Needing Reboot" to create a smart label for the devices which are stuck on reboot pending in the patch cycle, so I can create automatic alerts for the users to reboot.

The query in the report is working fine so as from the MySQL workbench tool but it doesn't work properly for the smart label, it attaches the labels to the machines which don't have reboot pending status, I see all the devices in label with and without reboot pending status. 

Is anyone came across with this type of issue?

I am running Version: 10.1.99 on the server and 10.0.113 for the agents.

The query:

select DISTINCT NAME, IP, LAST_SYNC, UPTIME from MACHINE join KBSYS.KONDUCTOR_TASK KT on KT.KUID = MACHINE.KUID and KT.TYPE like 'kpatch%' and KT.PHASE ='reboot pending' order by MACHINE.NAME


4 Comments   [ + ] Show comments

Comments

  • The query looks fine to me. The issue could be due to the device labels only updating when the machine inventories while the patching runs on a different schedule.
  • I have already mentioned, query worked fine on the report and SQL Workbench, it's the label. Almost all devices [300+] are attached to this label however, in reality, there are only 24 devices pending for the reboot.
  • im in the same boat, did you ever find a fix for this?
  • im in the same boat, did you ever find a fix for this?
    • Unfortunately, No, I couldn't find a fix for it and I gave up. :(

All Answers

0

If you create a smart label using the wizard it selects these columns:

MACHINE.NAME AS SYSTEM_NAME, SYSTEM_DESCRIPTION, MACHINE.IP, MACHINE.MAC, MACHINE.ID as TOPIC_ID 

I'm pretty sure that last MACHINE.ID as TOPIC_ID is the most important bit, but I always set my SQL smart labels to return those columns.

Answered 01/15/2020 by: chucksteel
Red Belt

 
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