Automate Runner Jobs Very Slow

Sean Horn -

A common reason this happens is that the first thing a runner jobs does is run Ohai on a runner as part of a as part of the delivery-cmd and then a little later, as part of a chef-client run.

When Ohai plugins are slow, this slows down the operation of the whole runner, and thus the processing of build jobs dispatched by Automate.

A common way that this can happen is that `hostname -f` may not return a result in a timely manner. The Ohai run embedded at the start of a chef-client run runs a bunch of plugins. One of those plugins is the hostname plugin, which just does `hostname -f` to gather that data. A way in which this can happen is if a hostname is not even configured on a box, and `hostname -f` returns no data and does it very slowly. Ohai will take the same amount of time to run its hostname plugin.

To debug a problem with chef-client plugins if you suspect that a certain plugin is very slow, just run `chef-client -l debug` and wait for the hang to happen. Each plugin is recorded in the output, and so if one takes a very long time to finish, like seconds, you will notice.

 

Have more questions? Submit a request

Comments

Powered by Zendesk