Ask Your Question
0

Amending Service Provider attributes with collector

asked 2018-06-26 07:59:31 -0500

aleita gravatar image

updated 2018-06-27 02:10:36 -0500

Hi

I'm migrating my puppet infrastructure from puppet 3 to 5 [at the moment only a puppet master at puppet 5].

I have not compilation error [puppet master 5]. The error appears ad the application catalog time.

Error: /Stage[main]/Nova::Compute::Libvirt/Service[libvirt]: Provider upstart is not functional on this host

I'm trying to change the provider in the following way:

Service <| title == 'libvirt' |> { enable => false, provider => 'systemd' }

but, I'm able to change all the Service attributes except the provider one.

FROM the catalog on the agent node [still puppet 3]: ..... ], "enable": false, "ensure": "running", "name": "libvirt-bin", "provider": "upstart", "require": "Package[libvirt]" }, "tags": [ "service",

I'm wonder whether is it possible to overwrite Service Provider attributes.

thanks in advance Ale

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-07-14 02:40:13 -0500

Geoff gravatar image

Your trick works fine, I just tried:

service { "crond":
  provider => upstart,
}
Service <| title == 'crond' |> { enable => false, provider => 'systemd' }

and got

Notice: Compiled catalog for pe-puppet.localdomain in environment production in 0.02 seconds
Notice: /Stage[main]/Main/Service[crond]/enable: enable changed 'true' to 'false'
Notice: Applied catalog in 0.35 seconds

Running on Centos.

I bet your collecting the wrong thing - what if you tried something like

Service <| name == 'libvirt' |> { enable => false, provider => 'systemd' }

or

Service <| title == 'libvirt-bin' |> { enable => false, provider => 'systemd' }
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2018-06-26 07:59:31 -0500

Seen: 62 times

Last updated: Jun 27