Hello everyone.
I'm trying to get a list of currently logged in users for a Windows machine. I know that I can use CMD's "query user", "WMIC /NODE: workstation_name COMPUTERSYSTEM GET USERNAME" or some PowerShell cmdlets to do that, but you'll need to allow this specific command in AllowKey parameter for each agent. Yes, I can create separate config file with that string and copy to every machine's "zabbix_agentd.conf.d" directory, but I want to know if I can reach this goal by using agent's "wmi.get" key (I guess you won't need to allow keys to perform these queries). I wasn't able to find a lot of info about which namespace I should use and how the query syntax will look like.
I'm trying to get a list of currently logged in users for a Windows machine. I know that I can use CMD's "query user", "WMIC /NODE: workstation_name COMPUTERSYSTEM GET USERNAME" or some PowerShell cmdlets to do that, but you'll need to allow this specific command in AllowKey parameter for each agent. Yes, I can create separate config file with that string and copy to every machine's "zabbix_agentd.conf.d" directory, but I want to know if I can reach this goal by using agent's "wmi.get" key (I guess you won't need to allow keys to perform these queries). I wasn't able to find a lot of info about which namespace I should use and how the query syntax will look like.
Comment