Puppet agents and primary servers communicate over HTTPS, exchanging structured data in JSON, or PSON which allows binary data.
Msgpack is an efficient serialization protocol that behaves similarly to JSON. It provides faster and more robust serialization for agent-server communications, without requiring many changes in our code.
Enabling Msgpack serialization
Enabling msgpack is easy, but first, it must be installed because the gem is not included in the puppet-agent or puppetserver packages.
Install the msgpack gem on your primary server and all
If you are using the Puppet Enterprise test environment, make sure to use PE gem command instead of the system gem command.On *nix nodes, run the following command:
/opt/puppetlabs/puppet/bin/gem install msgpackOn Windows nodes, run the following command:
"C:\Program Files\Puppet Labs\Puppet\sys\ruby\bin\gem" install msgpackOn Puppet Server, run the following command and then restart the Puppet Server service:
puppetserver gem install msgpack
puppet.confon any number of agent nodes, set the preferred_serialization_format setting to
After this is configured, the primary Puppet server uses msgpack
when serving any agents that have
preferred_serialization_format set to
msgpack. Any agents without that setting continue to receive PSON as