Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Properly handle suspend from terminal (SIGTSTP) to support resume (SIGCONT) #6033

Open
zalberico opened this issue Oct 25, 2022 · 0 comments

Comments

@zalberico
Copy link
Collaborator

Summary: Currently when you suspend the urbit process from the terminal (via control-z) it gets treated as if it was sent a SIGTERM, the urbit is killed and the process exits and cannot be resumed. The correct way to treat a SIGTSTP is to get the urbit process into a good state and then send ourselves a SIGSTOP which suspends it. The user is then dropped back to a standard unix prompt. Then when the user attempts to resume the process (SIGCONT) the user gets the previously suspended process back.

Why: Handling this allows a user to quickly drop into the unix prompt without needing to wait for shutdown, it also allows the user to quickly resume the same process. There are alternatives (using tmux, screen, etc.) but we should properly support the signals received (which is what the user should expect).

Links

@zalberico zalberico changed the title Properly handle suspend from terminal (SIGTSTP) to support SIGCONT Properly handle suspend from terminal (SIGTSTP) to support resume (SIGCONT) Oct 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant