The Opsview Monitor agent comes with a set of default plugins to be able to monitor many aspects of your devices
## Linux: Adding a custom plugin
Log in to the Linux host that will run the plugin.
Place the plugin in the `
/opt/opsview/agent/plugins_local
` directory. You may need to create this directory if it doesn't already exist.
Make sure the script is executable by the `
opsview
` user
Test the plugin works as expected and there are no missing supplimentary files (note: always change to the root directory to ensure relative paths are not assumed within the plugin) - the `
-h
` option should be included in all plugins to provide help output
Edit the file `
/opt/opsview/agent/etc/nrpe_local/custom.cfg
` (you may need to create it if it does not exist), adding a line like the below.
/opt/opsview/agent/etc/nrpe_local
Any files in this directory with the .cfg suffix will be read by Opsview. We use custom.cfg as an example.
Restart the Opsview agent
From your Opsview Monitor Orchestrator or Collector server you should now be able to use your custom servicecheck with the `-c
` flag of the check_nrpe plugin. For example:
** UI Configuration
Add a new Servicecheckwith the following configuration:
Name: Custom Check
Plugin: `check_nrpe
`
Parameters: `-H $HOSTADDRESS$ -c check_customer -a '<plugin arguements>'
`
Now add this Servicecheck to the Host you wish to monitor and `Apply Changes
` to bring the configuration into use