Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (Flatly)
  • No Skin
Collapse
Brand Logo

NetXMS Forum

  1. Home
  2. Support
  3. How can I restart remote process automatically?

How can I restart remote process automatically?

Scheduled Pinned Locked Moved Support
6 Posts 3 Posters 34.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S
    S
    sushizang
    wrote on last edited by
    #1

    I want to restart my remote process(linux) when that process goes down, using NetXMS console.

    How can I do?

    Thanks.
    Regards.

    1 Reply Last reply
    0
    • V
      V
      Victor Kirhenshtein
      wrote on last edited by
      #2

      You should define action on agent, and than define tool to execute that action in console via Control Panel -> Object Tools.

      To define custom action, add to agent's config:

      Action = ActionName:command

      Best regards,
      Victor

      1 Reply Last reply
      0
      • S
        S
        sushizang
        wrote on last edited by
        #3
        1. Add action to agent's config & restart agent
          Action = Test:ls > /ls.txt

        2. Define action on console's object tools.
          name: Test
          description: ls
          command: ls > /ls.txt
          access: everyone

        And then?

        Before,  I have define the action on "control panel -> Actions".

        And add it to event processing policy editor.

        And add that event on "Data collection -> threshold".

        But, not work.

        What is the difference between action and object tools on control panel?

        Sorry, but I can not find the details of define action on user manual.

        Thanks.
        Regards.

        1 Reply Last reply
        0
        • V
          V
          Victor Kirhenshtein
          wrote on last edited by
          #4

          Hello!

          Looks like some of the system functions has misleading names. We have:

          1. Actions on server (configurable under Control Panel -> Actions): it's an actions server can perform as a result of event processing. These actions can only be used in event processing policy.

          2. Actions on agent (configurable in agent's configuration file via Action or ActionShellExec parameters): it's a predefined commands agent can execute upon request.

          3. Object tools (configurable via Control Panel -> Object Tools): something which can be executed by operator on currently selected node in console. Object tools can be:

          a) Command - local command execution (executed on same machine where netXMS console is running);
          b) Action - predefined action execution on agent
          c) SNMP table - get data from SNMP
          d) Agent table - get data from agent
          e) Open URL - open given URL in embedded browser

          If you wish to run something on remote machine via agent, you should:

          1. Define action on agent (using Action or ActionShellExec - if you wish to use shell functionality like output redirection, you should use ActionShellExec).

          2. Depending on your need: if you wish to run something automatically, as a reaction to event, then:
            2a. Define server action (Control Panel -> Actions) of type "execute action on remote agent", enter name of agent's action into "Action" field;
            2b. Add your server action to event processing policy.

          If you wish to be able to run something on remote machine manually, via "Tools" menu:
          2a. Create new object tool (Control Panel -> Object Tools) of type "Action", enter name of agent's action into "Action" field.

          Hope this helps!

          Best regards,
          Victor

          1 Reply Last reply
          0
          • R
            R
            rnr
            wrote on last edited by
            #5

            Another question. I can run shell command on agent. So how can i get the result of command and show on Windows console.
            Ex: i defined in nxagentd.conf
            ActionShellExec = FWStatus:iptables -L

            How can i get the result of this command?

            1 Reply Last reply
            0
            • V
              V
              Victor Kirhenshtein
              wrote on last edited by
              #6

              Currently it is not possible. Most likely such feature will be added in one of the next versions.

              Best regards,
              Victor

              1 Reply Last reply
              0

              Hello! It looks like you're interested in this conversation, but you don't have an account yet.

              Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

              With your input, this post could be even better 💗

              Register Login
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              Powered by NodeBB Contributors
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups