Pandora FMS Community

Server plugin module - pass agent IP as variable

jwthomson · 17 ene 2019, 3:53 · 4 mensajes · 66 visitas

  1. Inicio del debate

    Hi When using plugin modules most require that the IP of the remote host be passed to the plugin script via one of the _fieldX_ parameters. When assigning a plugin to an agent the IP has to be entered separately, even though the agent typically has an IP address assigned to it anyway. Can the IP address of the agent be inserted into the plugin default value of a _field_ as a variable? e.g. Plugin  Description (_field1_): IP Address     Default value (_field1_): $var_IP_of_agent My rational for this is so plugin modules could be added to Module Templates and assigned directly to an agent, without the additional steps of then editing the module to add the IP If it is possible what is the variable name? If not possible where can I add a feature request? Cheers Jodi Pandora FMS v7.0NG.730 - Build PC181217 - MR 23

  2. Hi When using plugin modules most require that the IP of the remote host be passed to the plugin script via one of the _fieldX_ parameters. When assigning a plugin to an agent the IP has to be entered separately, even though the agent typically has an IP address assigned to it anyway. Can the IP address of the agent be inserted into the plugin default value of a _field_ as a variable? e.g. Plugin  Description (_field1_): IP Address     Default value (_field1_): $var_IP_of_agent My rational for this is so plugin modules could be added to Module Templates and assigned directly to an agent, without the additional steps of then editing the module to add the IP If it is possible what is the variable name? If not possible where can I add a feature request? Cheers Jodi Pandora FMS v7.0NG.730 - Build PC181217 - MR 23

    Good morning jwthomson, Please try to do the following steps and let us know if this solution works: 1- You must register correctly the plugins into the server. 2- Once registered, you must create a Component with the plugin type, where you can use the macro _address_ in the URL filed. 3- Introduce this component into a Module Template that you want to use. Alberto

  3. Good morning jwthomson, Please try to do the following steps and let us know if this solution works: 1- You must register correctly the plugins into the server. 2- Once registered, you must create a Component with the plugin type, where you can use the macro _address_ in the URL filed. 3- Introduce this component into a Module Template that you want to use. Alberto

    _address_ worked I added it to the Packet Loss plugin (default value for Target IP _field2_) and then added the plugin to the Basic Checks template - quick easy way of adding monitoring for upstreams peers Many thanks :) Is there a definitive list of build in macros somewhere? I come across the occasional mention of various ones in the documentation, but are only useful in that context Cheers Jodi

  4. Good morning jwthomson, Please try to do the following steps and let us know if this solution works: 1- You must register correctly the plugins into the server. 2- Once registered, you must create a Component with the plugin type, where you can use the macro _address_ in the URL filed. 3- Introduce this component into a Module Template that you want to use. Alberto

    _address_ worked I added it to the Packet Loss plugin (default value for Target IP _field2_) and then added the plugin to the Basic Checks template - quick easy way of adding monitoring for upstreams peers Many thanks :) Is there a definitive list of build in macros somewhere? I come across the occasional mention of various ones in the documentation, but are only useful in that context Cheers Jodi

    Good morning Jodi, The list of macros depends in where do you want to use them. For example, when creating a plugin module, in the "?" simbol on the plugins you can see all the macros you can use with plugins. Same happens for example when creating an alert. Alberto

Entra en tu cuenta para publicar.