Ad Widget

Collapse

Zabbix remote command -> start application with logged in user

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sjka
    Junior Member
    • Feb 2022
    • 5

    #1

    Zabbix remote command -> start application with logged in user

    Hi,

    we are running Zabbix 6.0.7

    I don't think it's a Zabbix bug per se. I have a host running a program, this program creates two processes with the same name when run. So I check these two processes and the trigger responds if less than two and starts an action that executes a script.

    This script is a Powershell one-liner and starts the above program, according to the logs the command arrived at the Zabbix Agent but the program is not visible.

    If I change the script and create a folder instead, that folder is created. So Zabbix -> Remote Command works.

    My guess is that the Zabbix Agent is not running the program as the logged in user but as System etc.

    How can I tell the Zabbix agent to start the program with the registered user so that I can also use it?​
    Last edited by sjka; 08-09-2022, 15:36.
  • dimir
    Zabbix developer
    • Apr 2011
    • 1080

    #2
    Whould that be of any help? https://support.zabbix.com/browse/ZBXNEXT-7459

    Comment

    • cyber
      Senior Member
      Zabbix Certified SpecialistZabbix Certified Professional
      • Dec 2006
      • 4807

      #3
      EIther you need to run agent as that user, who starts the program or you need to replace your oneliner with a more complex script, which will start your program as another user.
      https://docs.microsoft.com/en-us/pow...powershell-7.2 Example 8 I think covers your case.
      As usual, any access elevation may be considered as security threat etc ..

      Comment

      Working...