On Fri, Jan 13, 2012 at 09:46:46AM -0800, Daniel Pittman wrote:
> G'day.
> 
> At the moment we have some parts of the Puppet code that have a
> lurking bug around ActiveRecord: when we fork, if an AR database
> connection is open, we will break that connection in the parent when
> the child exits.
> 

Is there a way to identify the database handles? I just found an
interesting article about the difference of fork and popen and how to
set the close_on_exec flag:

http://cmdrclueless.com/blog/2009/07/06/activerecord-fork-exec-boom/


The article just sets the flag for all IO objects. Can we just execute
the code snippet once or would it be necessary to execute it before
every fork call?

-Stefan

Attachment: pgpe1oYU2TlWh.pgp
Description: PGP signature

Reply via email to