[ZBX-18499] Zabbix Agent2 (V5) UserParameters on Windows 2016 Server Created: 2020 Oct 14  Updated: 2020 Dec 22  Resolved: 2020 Dec 22

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Agent2 plugin (G)
Affects Version/s: 5.0.4
Fix Version/s: None

Type: Incident report Priority: Trivial
Reporter: RobertG Assignee: Arturs Lontons
Resolution: Incomplete Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows Server 2016
Zabbix Agent 2 (V 5.0.4)



 Description   

I am setting up a new server template using (moving from Win Server 2012 R2 to Server 2016) and using the latest zabbix agent2 client (5.0.4). When porting over some UserParameter's I get an access denied error in the zabbix logs.

Here is an example of the UserParameter:
UserParameter=sockstat.tcp.inuse.count, netstat -ano | find /C "ESTABLISHED"

This is what I see in the zabbix log (debug level 4)
2020/10/14 11:47:25.494277 [1] processing update request (1 requests)
2020/10/14 11:47:25.494277 [1] registering new client
2020/10/14 11:47:25.494277 [1] adding new request for key: 'sockstat.tcp.inuse.count'
2020/10/14 11:47:25.494277 [1] created direct exporter task for plugin 'UserParameter' itemid:0 key 'sockstat.tcp.inuse.count'
2020/10/14 11:47:25.509905 executing direct exporter task for key 'sockstat.tcp.inuse.count'
2020/10/14 11:47:25.509905 [UserParameter] executing command:' netstat -ano | find /C "ESTABLISHED"'
2020/10/14 11:47:25.664326 [UserParameter] command:' netstat -ano | find /C "ESTABLISHED"' length:17 output:'Access denied - \'
2020/10/14 11:47:25.664326 executed direct exporter task for key 'sockstat.tcp.inuse.count'
2020/10/14 11:47:25.664326 sending passive check response: 'Access denied - \' to 'Proxy-Server-IP x.x.x.x'

I have changed the user account that the zabbix agent runs as to verify if it were a user permissions issue (new account had admin rights) but that didnt resolve the issue.

Running the command via dos on the server works with out issue.



 Comments   
Comment by Arturs Lontons [ 2020 Nov 05 ]

Could you please test this on the C agent? We need to figure out if this is only agent2 error, or something that also happens on the C agent. Though it does look like a permission issue at a glance.

Comment by RobertG [ 2020 Nov 05 ]

Yes. I'll switch the agent and will let you know after testing. I should have results for you tomorrow. Thanks.

Comment by Arturs Lontons [ 2020 Dec 22 ]

Closing the issue due to lack of activity.

Generated at Sun May 11 07:48:17 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.