On Wed, Mar 7, 2012 at 2:58 PM, Matt Mencel <m...@techminer.net> wrote:

> I recently noticed that the Windows host where I installed the Puppet
> agent for testing was thrashing the CPU.
>
> The culprit ended up being Ruby.exe *32 - "Ruby interpreter (CUI)
> 1.8.7.334 [i386-mingw32]".  This is actually being launched by the
> puppet-agent service in Windows.  The CPU on the host was pegged around 50%
> all day long.  When I shut down the puppet-agent it went down to a
> reasonable level...hovering in the low single digits most of the time.
>
> Start puppet-agent and CPU Usage (on both CPUs in a 2vCPU host)
> immediately pegs to 40%-60%....stop puppet-agent and it drops to near zero.
>
> Is this a known issue?  Puppet-agent eating up tons of CPU time (via the
> ruby interpreter)?
>

It's new information to me, so I don't think we've started tracking this
specific issue.

I notice you mention it's ruby.exe that's spinning.  The service actually
starts rubyw.exe (Note the w) which invokes a very small ruby program that
runs the windows service event loop [1].

The daemon.rb event loop will then use Process.create to spawn the actual
Puppet agent process using INSTALLDIR\bin\puppet.bat agent --onetime.  The
Puppet agent is run inside of ruby.exe instead of rubyw.exe.

Could you use SysInternals Process Explorer to see if it's actually the
puppet agent process that's spinning, of if it's the service daemon?

[1]
https://github.com/puppetlabs/puppet_for_the_win/blob/master/conf/windows/service/daemon.rb

Thanks,
-Jeff

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to