summaryrefslogtreecommitdiffstats
path: root/collectors/ioping.plugin
diff options
context:
space:
mode:
Diffstat (limited to 'collectors/ioping.plugin')
-rw-r--r--collectors/ioping.plugin/README.md2
-rwxr-xr-xcollectors/ioping.plugin/ioping.plugin.in18
2 files changed, 9 insertions, 11 deletions
diff --git a/collectors/ioping.plugin/README.md b/collectors/ioping.plugin/README.md
index 08b0ce8b1..c4c3695c5 100644
--- a/collectors/ioping.plugin/README.md
+++ b/collectors/ioping.plugin/README.md
@@ -83,4 +83,4 @@ That's it. Netdata will detect the new plugin and start it.
You can name the new plugin any name you like.
Just make sure the plugin and the configuration file have the same name.
-[![analytics](https://www.google-analytics.com/collect?v=1&aip=1&t=pageview&_s=1&ds=github&dr=https%3A%2F%2Fgithub.com%2Fnetdata%2Fnetdata&dl=https%3A%2F%2Fmy-netdata.io%2Fgithub%2Fcollectors%2Fioping.plugin%2FREADME&_u=MAC~&cid=5792dfd7-8dc4-476b-af31-da2fdb9f93d2&tid=UA-64295674-3)](<>)
+
diff --git a/collectors/ioping.plugin/ioping.plugin.in b/collectors/ioping.plugin/ioping.plugin.in
index 1a82ef6d0..1d79eb706 100755
--- a/collectors/ioping.plugin/ioping.plugin.in
+++ b/collectors/ioping.plugin/ioping.plugin.in
@@ -174,16 +174,14 @@ ioping_opts="-T 1000000"
# -----------------------------------------------------------------------------
# load the configuration files
-for CONFIG in "${NETDATA_STOCK_CONFIG_DIR}/${plugin}.conf" "${NETDATA_USER_CONFIG_DIR}/${plugin}.conf"
-do
- if [ -f "${CONFIG}" ]
- then
- info "Loading config file '${CONFIG}'..."
- source "${CONFIG}"
- [ $? -ne 0 ] && error "Failed to load config file '${CONFIG}'."
- else
- warning "Cannot find file '${CONFIG}'."
- fi
+for CONFIG in "${NETDATA_STOCK_CONFIG_DIR}/${plugin}.conf" "${NETDATA_USER_CONFIG_DIR}/${plugin}.conf"; do
+ if [ -f "${CONFIG}" ]; then
+ info "Loading config file '${CONFIG}'..."
+ source "${CONFIG}"
+ [ $? -ne 0 ] && error "Failed to load config file '${CONFIG}'."
+ elif [[ $CONFIG =~ ^$NETDATA_USER_CONFIG_DIR ]]; then
+ warning "Cannot find file '${CONFIG}'."
+ fi
done
if [ -z "${destination}" ]