[chef] Re: RE: Simultaneous chef run handling on linux/windows


Chronological Thread 
  • From: Brian Anderson < >
  • To:
  • Subject: [chef] Re: RE: Simultaneous chef run handling on linux/windows
  • Date: Tue, 20 Aug 2013 15:06:07 -0400

I'm glad to see that it was reproducible! 

I'll have to add some additional handling in our scripts to do the stop/start of the client when the target is windows.




Brian


On Fri, Aug 16, 2013 at 5:04 PM, Serdar Sutay < " target="_blank"> > wrote:
Thanks for reporting this one as well Brian... 


My suspicion is that here (https://github.com/opscode/chef/blob/master/lib/chef/run_lock.rb#L61FD_CLOEXEC is creating some issues on windows. 

You can work around this by setting splay to 0 and instead of running "chef-client" during deployment you can run "net stop chef-client && net start chef-client". 

Thanks,
Serdar

From: Brian Anderson < " target="_blank"> >
Sent: Friday, August 16, 2013 9:32 PM
To: " target="_blank">
Subject: [chef] Simultaneous chef run handling on linux/windows
 
Here I am, back with more windows questions...

We have just started to run chef in daemon mode. Previously we had only been running it on demand.

Our deployment scripts trigger chef runs, and can be fired off at any time.

On Linux, if the chef-client daemon is running, you get a warning message:
[2013-08-16T14:28:27-04:00] WARN: Chef client  is running, will wait for it to finish and then run.

And things go along happily from there.

On Windows, you get:
[2013-08-16T14:23:44-04:00] FATAL: Errno::EACCES: Permission denied - C:/chef/cache/chef-client-running.pid

Is there a setting in client.rb / something I can do to prevent these errors on Windows? 




Brian
--
Brian Anderson | Operations Engineer
Phone 781.696.1304
 


www.affectiva.com

     



--
Brian Anderson | Operations Engineer
Phone 781.696.1304
 


www.affectiva.com

     



Archive powered by MHonArc 2.6.16.

§