Re: [Tracker] Killing run-away child processes



Edward Duffy wrote:
Text filtering, metadata extraction, and thumbnail generation are all
handled out of process so they can't crash trackerd.  However these
processes are called with g_spawn_sync and there's no gaurentee they
will come back.

Here's a patch that will set SIGALRM for these external processes, it
uses the child_setup callback function, so there's no need for every
possible child process to set its own alarm.



so we get back a SIGALRM signal which we dont currently handle after 30 secs?

dont we need a way to kill these external processes if they timeout?

(kinda tricky without the pids although we could execute "killall -9 tracker-extract" though that wont do for the other types and is a bit hacky!)

Another way to do this is within tracker-extract with the extraction performed in another thread with the main thread being a timer that kills itself if it timeouts. We could also have a tracker-filter program to do likewise with text filters ( and tracker-thumb too) - it would be cleaner but do you fancy doing the work?


--
Mr Jamie McCracken
http://jamiemcc.livejournal.com/




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]