[PATCH rhel7-branch] Fix hang at reboot with VNC installs (#1036572)

Vratislav Podzimek vpodzime at redhat.com
Tue Sep 9 08:48:19 UTC 2014


On Mon, 2014-09-08 at 19:22 -0400, Will Woods wrote:
> Calling vnc.shutdownServer() causes the window manager to terminate
> (naturally), which makes startMetacityWM() call os._exit(0).
> 
> Obviously, if that happens before we've initiated reboot, the system
> won't reboot. So don't do that until after initiating reboot.
> 
> (In fact, we probably don't *need* to shut down VNC when we're doing
> reboot/halt/etc, since that process will kill the server for us.. but
> for other use-cases we should still clean up after ourselves.)
> ---
>  anaconda | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/anaconda b/anaconda
> index ae88954..f00415d 100755
> --- a/anaconda
> +++ b/anaconda
> @@ -54,9 +54,6 @@ def exitHandler(rebootData, storage, exitCode=None):
>          if os.path.isdir('/mnt/sysimage/root'):
>              cov.save()
>  
> -    if flags.usevnc:
> -        vnc.shutdownServer()
> -
>      if exitCode:
>          anaconda.intf.shutdown()
>  
> @@ -94,6 +91,11 @@ def exitHandler(rebootData, storage, exitCode=None):
>          else: # reboot action is KS_REBOOT or None
>              subprocess.Popen(["systemctl", "--no-wall", "reboot"])
>  
> +    # Shutting down the server makes the window manager terminate, which makes
> +    # us do os._exit(0) (see below). So this needs to happen at the very end.
I'm sorry, but I don't see the os._exit(0) call the window manager
termination leads to. Is there any thread watching the window manager
process and calling it when it terminates?

-- 
Vratislav Podzimek

Anaconda Rider | RHCE | Red Hat, Inc. | Brno - Czech Republic




More information about the anaconda-patches mailing list