You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am writing a wrapper over xhyve in swift, where I have given setuid to the xhyve binary (!!) and run the Ubuntu VM on a button click. Now I want to shut down the VM. Options -
Make a root user and set its ssh shell to poweroff. But this can be exploited by any other applications.
Run kill - nope, because I don't want to give setuid to a binary that can kill
SIGINT - Not graceful
Simulating Ctrl + SysRq + o - how do I do this?
I want to do a safe shutdown - what should be the best way?
The text was updated successfully, but these errors were encountered:
I'm also wondering how to do this. I usually use halt when I was successful in booting the machine. But for machines that are broken, I always have to shut down the process manually somehow.
Inside a VM I use halt. Outside the VM, you can use SIGTERM. That gets translated into a "power button" press, and that typically triggers an OS shutdown.
I am writing a wrapper over xhyve in swift, where I have given
setuid
to the xhyve binary (!!) and run the Ubuntu VM on a button click. Now I want to shut down the VM. Options -poweroff
. But this can be exploited by any other applications.kill
- nope, because I don't want to give setuid to a binary that can killI want to do a safe shutdown - what should be the best way?
The text was updated successfully, but these errors were encountered: