Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1698571

Re: Fwd: trinity test fanotify cause hungtasks on kernel 4.13

From Jan Kara <jack@suse.cz>
Newsgroups linux.kernel
Subject Re: Fwd: trinity test fanotify cause hungtasks on kernel 4.13
Date 2017-07-28 09:50 +0200
Message-ID <u88c2-N3-11@gated-at.bofh.it> (permalink)
References <u7NKj-4sL-25@gated-at.bofh.it> <u84Br-6TA-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri 28-07-17 11:52:13, Gu Zheng wrote:
> 
> hi,ALL:
> when we used the trinity test the fanotify interfaces, it cause many hungtasks.
> CONFIG_FANOTIFY_ACCESS_PERMISSIONS=y
> the shell is  simple:
>   1 #!/bin/bash
>   2
>   3 while true
>   4 do
>   5 ./trinity -c fanotify_init -l off -C 2 -X > /dev/null 2>&1 &
>   6 sleep 1
>   7 ./trinity -c fanotify_mark -l off -C 2 -X > /dev/null 2>&1 &
>   8 sleep 10
>   9 done
> we found the trinity enter the D state fastly.
> we check the pids'stack

<snip>

> all progresses are waiting for the response in fanotify_handle_event->fanotify_get_response,
> becauseof non-response or killed monitor,so the waitqueue is  in blocked state,
> then the others will be stucked which use the  fanotify_get_response.

Yes, this all works as expected.

> if we use wait_event_timeout , the responed time can not be guaranteed.
> 
> do you have any ideas?

So if your target is sensible trinity testing of fanotify, what you could
do is that you would gather all descriptors where fanotify_init()
succeeded, watch them and reply to all fanotify events. Alternatively you
could just close these descriptors - that would tear down fanotify instance
and all events will be auto-accepted.

								Honza
-- 
Jan Kara <jack@suse.com>
SUSE Labs, CR

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

trinity test fanotify cause hungtasks on kernel 4.13 Gu Zheng <guzheng1@huawei.com> - 2017-07-27 12:00 +0200
  Re: trinity test fanotify cause hungtasks on kernel 4.13 Gu Zheng <guzheng1@huawei.com> - 2017-07-28 03:30 +0200
  Fwd: trinity test fanotify cause hungtasks on kernel 4.13 Gu Zheng <guzheng1@huawei.com> - 2017-07-28 06:00 +0200
    Re: Fwd: trinity test fanotify cause hungtasks on kernel 4.13 Jan Kara <jack@suse.cz> - 2017-07-28 09:50 +0200

csiph-web