How the puppet client cancels the active update
Runinterval
How often puppet agent applies the client configuration, in seconds. Note that a runinterval of 0 means "run continuously" rather than "never run." If you want puppet agent to Never run, you should start it with the--no-client option. Can be specified as a duration.
default:30m
roughly means that the puppet client has a default synchronization time of 30 minutes with the server, and if Runinterval is 0, it represents a time synchronization, and if we want the client to remain actively synchronized with the server, it can be added in the puppet client startup script-- No-client, then restart the puppet client service.
The specific modifications are as follows:
Vi/etc/init.d/puppet
Find[-N "${puppet_server}"] && puppet_opts= "--server=${puppet_server}"this line, and then add the--no-client at the end
the effect after adding:
[-N "${puppet_server}"] && puppet_opts= "--server=${puppet_server}--no-client"
then restart the client Puppet,/etc/init.d/puppet restart, so that the client does not actively synchronize with the server (remember to/etc/puppet/puppet.conf runinterval comments (⊙o⊙) OH).
then go to the server execution puppet kick-d--host client hostname can be implemented just want to push the function.
I modified vi/lib/systemd/system/puppet.service in Centos7.
650) this.width=650; "Src=" Http://s5.51cto.com/wyfs02/M00/87/3F/wKioL1fY71WzTfbxAABSPMIGOOc428.png-wh_500x0-wm_3 -wmp_4-s_3811177600.png "title=" qq picture 20160914143320.png "alt=" Wkiol1fy71wztfbxaabspmigooc428.png-wh_50 "/>
After adding--no-client, restart Puppet will prompt to run
650) this.width=650; "Src=" Http://s2.51cto.com/wyfs02/M00/87/41/wKiom1fY8B-hI27hAAARsFFyNgw774.png-wh_500x0-wm_3 -wmp_4-s_743511856.png "title=" qq picture 20160914143608.png "alt=" Wkiom1fy8b-hi27haaarsffyngw774.png-wh_50 "/>
Follow the prompts to run.
Restarting the puppet client, the puppet client is no longer actively updating the
This article is from the "Dream to Reality" blog, please be sure to keep this source http://lookingdream.blog.51cto.com/5177800/1852719
Puppet Client cancels active update