All of lore.kernel.org
 help / color / mirror / Atom feed
* is there a way to register for processes state changes from userspace ?
@ 2015-07-09  6:39 Ramon Fried
  2015-07-09  7:08 ` Nikolay Borisov
  0 siblings, 1 reply; 3+ messages in thread
From: Ramon Fried @ 2015-07-09  6:39 UTC (permalink / raw)
  To: kernelnewbies

Hi.

I'm developing an application that needs to know if any of its clients (different processes) terminated or got killed by a signal.

Currently I'm implementing it by looking at the specific PID procfs directory.
Is there a better way to achieve that ? Something like netlink notifications for subscribed processes will be great...
Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20150709/6d957e36/attachment.html 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* is there a way to register for processes state changes from userspace ?
  2015-07-09  6:39 is there a way to register for processes state changes from userspace ? Ramon Fried
@ 2015-07-09  7:08 ` Nikolay Borisov
  2015-07-09  9:19   ` Jason Ball
  0 siblings, 1 reply; 3+ messages in thread
From: Nikolay Borisov @ 2015-07-09  7:08 UTC (permalink / raw)
  To: kernelnewbies



On 07/09/2015 09:39 AM, Ramon Fried wrote:
> at the specific PID procfs directory.
> Is there a better way to achieve that ? Something like netlink notifications for subscribed processes will be great...
> Thanks.

If your process is abruptly killed then there is no way for the process
to tell you that (it's dead after all). Just implement a simple time-out
mechanism in the spirit of ping.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* is there a way to register for processes state changes from userspace ?
  2015-07-09  7:08 ` Nikolay Borisov
@ 2015-07-09  9:19   ` Jason Ball
  0 siblings, 0 replies; 3+ messages in thread
From: Jason Ball @ 2015-07-09  9:19 UTC (permalink / raw)
  To: kernelnewbies

Look at netlink sockets.
On 9 Jul 2015 5:08 pm, "Nikolay Borisov" <n.borisov.lkml@gmail.com> wrote:

>
>
> On 07/09/2015 09:39 AM, Ramon Fried wrote:
> > at the specific PID procfs directory.
> > Is there a better way to achieve that ? Something like netlink
> notifications for subscribed processes will be great...
> > Thanks.
>
> If your process is abruptly killed then there is no way for the process
> to tell you that (it's dead after all). Just implement a simple time-out
> mechanism in the spirit of ping.
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20150709/4ba58dae/attachment.html 

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-07-09  9:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-09  6:39 is there a way to register for processes state changes from userspace ? Ramon Fried
2015-07-09  7:08 ` Nikolay Borisov
2015-07-09  9:19   ` Jason Ball

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.