How to set puppet on the agent to start on reboots?

I'm on ubuntu, is this the correct way to get puppet to start on reboots?

update-rc.d puppet default

If yes, where can I see the result of that command? Does it update a file that gets called on reboots?

Is this the same process for both the puppet master server and the puppet agent servers?

Update Just in case the puppet agent already runs after reboots using the default installs on ubuntu using:

sudo apt-get puppet facter

How can I know if is already setup to start on reboots?


Solution 1:

The puppet agent package doesn't set itself to start at boot by default, so that you have a chance to configure it as needed before it starts doing its thing (and potentially making massive changes to the system). It warns about this when you try to start the service.

Modify /etc/default/puppet, changing START=no to START=yes, then start the service with service puppet start.

The puppetmaster package should be starting at boot automatically as soon as it's installed.

Solution 2:

The puppet way, once you have puppet installed you can use puppet resource (or ralsh on 0.25):

puppet resource service puppet ensure=running enable=true

Solution 3:

That should set the service to start on boot. You can do a ls of /etc/rcX.d/*puppet (where X is the default runlevel of your system) to make sure it is set to come up on boot. If there is a puppet file with a capital S, it is set (for example, S85puppet). The "S" at the beginning tells the system to execute the script at startup.