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. ExternalParameterShellExec runs multiple times

ExternalParameterShellExec runs multiple times

Scheduled Pinned Locked Moved Support
6 Posts 2 Posters 60.6k 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.
  • M
    M
    MarcusH
    wrote on last edited by
    #1

    Hi,

    I have set up one node to run a file via ExternalParameterShellExec on the agent but when it executes the file it runs it 3 times, any known related problems to this?
    Searched the bugtracker but could not find any.

    Tested both forced DCI poll and scheduled.

    Agent version 2.0.5
    Windows 2012 R2

    1 Reply Last reply
    0
    • A
      A
      Alex Kirhenshtein
      wrote on last edited by
      #2

      Please increase debug level to 5, reproduce problem and send us agent log

      1 Reply Last reply
      0
      • M
        M
        MarcusH
        wrote on last edited by
        #3

        This is not the real file, i tested different scenarios and this test.exe is only a while loop so it stays active

        [10-Oct-2016 11:01:16.251] [DEBUG] [session:0] Requesting parameter "test"
        [10-Oct-2016 11:01:16.251] [DEBUG] H_ExternalParameter called for "test" "Sc:\test.exe"
        [10-Oct-2016 11:01:16.251] [DEBUG] RunExternal called for "test" "Sc:\test.exe"
        [10-Oct-2016 11:01:16.251] [DEBUG] RunExternal: command line is "c:\test.exe"
        [10-Oct-2016 11:01:16.251] [DEBUG] RunExternal (shell exec): worker thread created
        [10-Oct-2016 11:01:18.266] [DEBUG] RunExternal (shell exec): execution timeout
        [10-Oct-2016 11:01:18.266] [DEBUG] RunExternal (shell exec): execution status 2
        [10-Oct-2016 11:01:18.266] [DEBUG] [session:0] Requesting parameter "test"
        [10-Oct-2016 11:01:18.266] [DEBUG] H_ExternalParameter called for "test" "Sc:\test.exe"
        [10-Oct-2016 11:01:18.266] [DEBUG] RunExternal called for "test" "Sc:\test.exe"
        [10-Oct-2016 11:01:18.266] [DEBUG] RunExternal: command line is "c:\test.exe"
        [10-Oct-2016 11:01:18.266] [DEBUG] RunExternal (shell exec): worker thread created
        [10-Oct-2016 11:01:20.266] [DEBUG] RunExternal (shell exec): execution timeout
        [10-Oct-2016 11:01:20.266] [DEBUG] RunExternal (shell exec): execution status 2
        [10-Oct-2016 11:01:20.266] [DEBUG] [session:0] Requesting parameter "test"
        [10-Oct-2016 11:01:20.266] [DEBUG] H_ExternalParameter called for "test" "Sc:\test.exe"
        [10-Oct-2016 11:01:20.266] [DEBUG] RunExternal called for "test" "Sc:\test.exe"
        [10-Oct-2016 11:01:20.266] [DEBUG] RunExternal: command line is "c:\test.exe"
        [10-Oct-2016 11:01:20.266] [DEBUG] RunExternal (shell exec): worker thread created
        [10-Oct-2016 11:01:22.282] [DEBUG] RunExternal (shell exec): execution timeout
        [10-Oct-2016 11:01:22.282] [DEBUG] RunExternal (shell exec): execution status 2
        
        1 Reply Last reply
        0
        • A
          A
          Alex Kirhenshtein
          wrote on last edited by
          #4

          Well, it behaves as expected.
          If you need to handle long-running command - use ExternalParameterProvider (https://wiki.netxms.org/wiki/ExternalParametersProvider)

          1 Reply Last reply
          0
          • M
            M
            MarcusH
            wrote on last edited by
            #5

            That seems logical, though this external does not return data by itself it consolidates data in an external sql db for faster queries.
            Can run it in windows schedule but felt more right to run it from the agent that uses it on set schedule.

            The answer though solved a few other data collection dilemmas i had so thanks for that, time to rethink my data providers 🙂

            1 Reply Last reply
            0
            • A
              A
              Alex Kirhenshtein
              wrote on last edited by
              #6

              Problem with slow external parameters is that server retrieve values in a single thread (per agent) and it can block data collection from the agent

              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