Skip to content
  • Thayumanavar S's avatar
    b0072f02
    BUG#23744004 - KEVENT()/CLOSE() DEADLOCK ON MAC 10.12 · b0072f02
    Thayumanavar S authored
    MAC OS 10.12 beta (build 16A201w) causes mysqld to hang on exit.
    This happens during the deinitialization of statement timer subsystem.
    During the deinitialization, the timer notify thread is signalled to exit
    via USER kevent and then race on to close the kqueue fd. If the timer notifier
    user kevent doesn't fire before the close of kqueue, it shall cause the close
    to hang. In the new release of MACOS, close can't interrupt a kevent syscall.
    
    The fix is to move the close of kqueue fd to timer notifier thread. This kqueue
    fd is closed once we exit of the timer event handling loop thereby preventing
    the hang.
    b0072f02
    BUG#23744004 - KEVENT()/CLOSE() DEADLOCK ON MAC 10.12
    Thayumanavar S authored
    MAC OS 10.12 beta (build 16A201w) causes mysqld to hang on exit.
    This happens during the deinitialization of statement timer subsystem.
    During the deinitialization, the timer notify thread is signalled to exit
    via USER kevent and then race on to close the kqueue fd. If the timer notifier
    user kevent doesn't fire before the close of kqueue, it shall cause the close
    to hang. In the new release of MACOS, close can't interrupt a kevent syscall.
    
    The fix is to move the close of kqueue fd to timer notifier thread. This kqueue
    fd is closed once we exit of the timer event handling loop thereby preventing
    the hang.
Loading