User Process Management CLI
Generally, it's common to have a cli tool to manage the user processes, with respective commands to help start
, stop
, restart
processes like systemctl
. This blog records some experience building a CLI tool in Go to manage processes. Moreover, it lists some sceneries to make it work well as a PID 1 process.
Here are some summary items in this blog:
- signal handling,
wait
system calls and process management - processes reaping as the init process
- start, restart and exit handling