Closed Officeyutong closed 4 months ago
I think we might need some further discussion on this design.
For example, what happens if the agent or server is running a fork()?
I think we might need some further discussion on this design.
For example, what happens if the agent or server is running a fork()?
The new process will only contain the thread that executed fork()
I think we might need some further discussion on this design.
For example, what happens if the agent or server is running a fork()?
We may need to discuss about how we should handle forked processes
Can we reopen this?
Closes #178
Adds a watchdog for agents. If syscall server was dead, agents will exit automacitally.
When starting up, both agent and server will start a separate thread. The thread at server side will keep updating a time stamp stored in shared memory every 50ms, indicating that server is still alive till this time. At the agent side, the thread will keep reading this time stamp from shared memory, and check if the time stamp hasn't been updated for over 150ms. If succeeded, it will regard server as dead, and start to detach.
Demo
Term1
Term2
Then, stop syscall server (Ctrl+C) and have a look at agent