Custom Inventory rule only working CentOS but not Ubuntu
I have the a CIF that outputs the list of local linux accounts using this command:
getent passwd {500..10000} | awk -F: '{ print $1}'
From a shell on both CentOS and Ubuntu it outputs the correct info. However when from a custom Inventory rule it only works on CentOS (5.x and up) but not on any Ubuntu system (12 and up)
I'm using this: ShellCommandTextReturn(getent passwd {500..10000} | awk -F: '{ print $1}')
I have also tried with this version: ShellCommandTextReturn(getent passwd {500..10000} | cut -d: -f1)
This is what I see in the Ubuntu KAgent.log file:
[2019-06-14.19:20:16][KDeploy:ExecuteCustomInventoryRu] rule ID [22158] : issuing rule [ShellCommandTextReturn(getent passwd {500..10000} | awk -F: '{ print $1}');]
[2019-06-14.19:20:16][KDeploy:ExecuteCustomInventoryRu] rule [22158] statement result: "", FALSE
[2019-06-14.19:20:16][KDeploy:RunCustomInventory ] KDeploy finished processing 3 custominventory rules, sending response
I have other custom inventory items that work fine on both CentOS and Ubuntu.
Any ideas?
Answers (0)
Be the first to answer this question
https://support.quest.com/create-service-request - Channeler 5 years ago