Bulk editing of Hosts

Dear Community,

i’ve configured the dynamic host configuration with the vmware vCenter.

All hosts show up as they should, but i don’t need the most of the upcoming services.

Is it possible to remove services (or just disable them) on a bunch of hosts?

All the created services were produced through the special agent “Check state of VMWare ESX via vSphere”

Just use the rule Disabled Services at the section Monitoring Configuration for this.

3 Likes

thanks for the fast reply.

I’ve got a service for each host which is named like the hostname.

Have you an idea how do i remove this one too?

Just create a new rule in Disabled Services and under Services use the hostname variable $HOSTNAME$.

1 Like

i thought that too, but CheckMK uses the $ as regex and cuts the last dollar.
Writing the expression like ‘$HOSTNAME$’ doesn’t work too.

image

Do i do something wrong?

You can’t use the variables in field which accept RegEx. The best way would be to have a RegEx as close as possible on your service name. Maybe you can provide some examples and we see how we can get this rule working for your services you like to disable.

If your have a dedicated number of hosts you can also use host tags to specialize your new rule.

1 Like

Thank you for your suggestion. The only fitting rule i can use is "VM .* " because all servicenames start with a “VM”.

But this would be too unspecific i think, because there can be more serviceses in the future that starts like that.

I reduced the ~450 services down to ~40 services that don’t fit a more specific rule.

If your servers have a specific naming concept you could use this maybe for RegEx too.

I would also try to work with host tags to be more specific where to disable the service.

1 Like

If all of the Hosts would follow our naming concept, i could disable the service.
Using tags doesn’t help, because the service uses the hostname of the server.
But thank you for the first idea with the regex, it looks like the only solution.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.