Pim Jeursen
2017-11-09 08:31:49 UTC
Hi there,
So I recently got to play with Saltstack again, and ran into an annoying
issue.
I have a Jinja file that serves as a check_mk config file, so Saltstack
minions are automatically added to Check_mk and monitored. Works great
except for the following:
{% if ip == '127.0.0.1' or '0.0.0.0' in ip or '10.20.118' in ip or
'172.16.' in ip or '169.254' in ip or '10.220.10' in ip -%}
This rule is in the file 3 times, first the variable is set using the
default ip address([ipv4][0]).
If the above rule matches a ip it sets the ip variable to: ([ipv4][1]).
Then it checks again, and if a match is found i goes to ([ipv4][2])
Now there is a host which has one of the matching ip's on nic1 and nic2,
but doesn't have a nic3 configured. So Salt doesn't generate the config
file and exits with a error.
Is there a way to generate extra logging to see what hosts causes the
issue. Or do i need to manually search vmware for the troubling vm?
Thanks in advance.
So I recently got to play with Saltstack again, and ran into an annoying
issue.
I have a Jinja file that serves as a check_mk config file, so Saltstack
minions are automatically added to Check_mk and monitored. Works great
except for the following:
{% if ip == '127.0.0.1' or '0.0.0.0' in ip or '10.20.118' in ip or
'172.16.' in ip or '169.254' in ip or '10.220.10' in ip -%}
This rule is in the file 3 times, first the variable is set using the
default ip address([ipv4][0]).
If the above rule matches a ip it sets the ip variable to: ([ipv4][1]).
Then it checks again, and if a match is found i goes to ([ipv4][2])
Now there is a host which has one of the matching ip's on nic1 and nic2,
but doesn't have a nic3 configured. So Salt doesn't generate the config
file and exits with a error.
Is there a way to generate extra logging to see what hosts causes the
issue. Or do i need to manually search vmware for the troubling vm?
Thanks in advance.
--
You received this message because you are subscribed to the Google Groups "Salt-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/salt-users/0b649755-3e62-4a0f-a0dd-97960846d4b7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "Salt-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/salt-users/0b649755-3e62-4a0f-a0dd-97960846d4b7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.