On Tue, Apr 21, 2015 at 01:28:02PM -0700, Gurucharan Shetty wrote: > On Tue, Apr 14, 2015 at 9:02 PM, Ben Pfaff <b...@nicira.com> wrote: > > On Tue, Apr 07, 2015 at 06:06:40PM -0700, Gurucharan Shetty wrote: > >> It has been observed that sometimes Windows unit tests hang. > >> This happens when a daemon is started but does not get terminated > >> when the test ends. > >> > >> In one particular case, OVS_VSWITCHD_STOP is called which inturn > >> calls 'ovs-appctl exit'. This causes ovs-vswitchd's atexit handler > >> to cleanup the pidfiles. After this, the pthread destructurs get > >> called and a deadlock happens in there. This results in the > >> daemons not getting force killed resulting in the tests hanging. > >> > >> This commit stores the contents of pidfiles in different files. > >> This way, even if the pidfiles get deleted for any reason, we > >> can still kill the daemons. > >> > >> This commit also changes the way daemons are force killed in > >> Windows. It was observed that 'taskkill //F ' failed to kill > >> a deadlocked daemon running its pthread destructor. But > >> tskill succeeds. > >> > >> Signed-off-by: Gurucharan Shetty <gshe...@nicira.com> > > > > This seems reasonable to me. > > > > I think that we might be able to implement it a little more nicely. > > What if we introduce an ON_EXIT_UNQUOTED, analogous to > > AT_CHECK_UNQUOTED, and use it here in OVS_VSWITCHD_START instead of > > making a on-disk file copy? > > I am sorry for the delayed response. I somehow completely missed your > feedback. > The change that you suggest is very clever (I did not know the > difference between quoted and unquoted word after the HERE document > till today.) . I will incorporate it as part of v2.
Great! (The Bourne shell is full of weird and useful things like this.) _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev