Re: proc_flush_task oops

From: Dave Jones
Date: Tue Dec 19 2017 - 14:30:28 EST


On Tue, Dec 19, 2017 at 12:27:30PM -0600, Eric W. Biederman wrote:
> Dave Jones <davej@xxxxxxxxxxxxxxxxx> writes:
>
> > On Mon, Dec 18, 2017 at 03:50:52PM -0800, Linus Torvalds wrote:
> >
> > > But I don't see what would have changed in this area recently.
> > >
> > > Do you end up saving the seeds that cause crashes? Is this
> > > reproducible? (Other than seeing it twoce, of course)
> >
> > Only clue so far, is every time I'm able to trigger it, the last thing
> > the child process that triggers it did, was an execveat.
>
> Is there any chance the excveat might be called from a child thread?

If trinity choose one of the exec syscalls, it forks off an extra child
to do it in, on the off-chance that it succeeds, and we never return.
https://github.com/kernelslacker/trinity/blob/master/syscall.c#L139

> That switching pids between tasks of a process during exec can get a
> little bit tricky.
>
> > Telling it to just fuzz execveat doesn't instantly trigger it, so it
> > must be a combination of some other syscall. I'll leave a script running
> > overnight to see if I can binary search the other syscalls in
> > combination with it.
>
> Could we have a buggy syscall that is stomping something?

Not totally impossible I guess, though I would expect that would
manifest in additional random failures, whereas this seems remarkably
consistent.

Dave