Ad Widget

Collapse

Run custom script on a host without trigger

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mantasant
    Junior Member
    • Mar 2019
    • 2

    #1

    Run custom script on a host without trigger

    Hello,

    I want to run a script that is in user home directory through Zabbix without a trigger. The script changes specified user's password to a value that is already defined inside a script. It works fine when I'm connected through ssh.

    So the script lays inside a monitored device, I need Zabbix server to connect to my device through SSH and run that script (/var/services/homes/user/change-password), whenever I need.

    Is there a way to run this script in similar way how global scripts work (you select a host and press on a script name to run a script)?

    Any help is appreciated!

    Thanks.
  • Atsushi
    Senior Member
    • Aug 2013
    • 2028

    #2
    You can do it just by running the script.
    However, you can not execute things that require interactive input.

    Manual: 7 Scripts

    Comment

    • mantasant
      Junior Member
      • Mar 2019
      • 2

      #3
      Originally posted by Atsushi
      You can do it just by running the script.
      However, you can not execute things that require interactive input.

      Manual: 7 Scripts
      https://www.zabbix.com/documentation...tration/script
      Thank you for your answer. So all I need is to install Zabbix agent on my device and then create a global script with an option "Execute on Zabbix Agent"?

      Comment

      Working...