* Re: PROBLEM: Hang in selftests/netfilter/nft_trans_stress.sh [not found] <281b5a5e-4b56-ef6f-9896-49b364924662@alu.unizg.hr> @ 2023-01-03 14:28 ` Florian Westphal 2023-01-03 15:35 ` Mirsad Goran Todorovac 0 siblings, 1 reply; 4+ messages in thread From: Florian Westphal @ 2023-01-03 14:28 UTC (permalink / raw) To: Mirsad Goran Todorovac Cc: linux-kselftest, LKML, Shuah Khan, Florian Westphal, Jakub Kicinski Mirsad Goran Todorovac <mirsad.todorovac@alu.unizg.hr> wrote: > Hi all, > > The `make kselftest` hangs in netfilter/nft_trans_stress.sh test when testing 6.2.0-rc2 > (attempted 2 times, waiting half an hour at least): This script completes in 49 seconds for me. > # selftests: netfilter: nft_trans_stress.sh > # PASS: nft add/delete test returned 0 > # PASS: nft reload test returned 0 > > The test script seems to be stuck in ping flood: No, it gets stuck in the sub-test after 'PASS: nft reload test returned 0' Can you send me the output of 'bash -x nft_trans_stress.sh'? It should tell which command/program isn't making progress. ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: PROBLEM: Hang in selftests/netfilter/nft_trans_stress.sh 2023-01-03 14:28 ` PROBLEM: Hang in selftests/netfilter/nft_trans_stress.sh Florian Westphal @ 2023-01-03 15:35 ` Mirsad Goran Todorovac 2023-01-03 16:11 ` Florian Westphal 0 siblings, 1 reply; 4+ messages in thread From: Mirsad Goran Todorovac @ 2023-01-03 15:35 UTC (permalink / raw) To: Florian Westphal; +Cc: linux-kselftest, LKML, Shuah Khan, Jakub Kicinski On 03. 01. 2023. 15:28, Florian Westphal wrote: > Mirsad Goran Todorovac <mirsad.todorovac@alu.unizg.hr> wrote: >> Hi all, >> >> The `make kselftest` hangs in netfilter/nft_trans_stress.sh test when testing 6.2.0-rc2 >> (attempted 2 times, waiting half an hour at least): > > This script completes in 49 seconds for me. > >> # selftests: netfilter: nft_trans_stress.sh >> # PASS: nft add/delete test returned 0 >> # PASS: nft reload test returned 0 >> >> The test script seems to be stuck in ping flood: > > No, it gets stuck in the sub-test after 'PASS: nft reload test returned 0' > > Can you send me the output of 'bash -x nft_trans_stress.sh'? > It should tell which command/program isn't making progress. Hi, Florian! Well, when ran alone, the script ended successfully: root@marvin-IdeaPad-3-15ITL6:/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter# bash nft_trans_stress.sh PASS: nft add/delete test returned 0 PASS: nft reload test returned 0 PASS: nft add/delete with nftrace enabled test returned 0 PASS: nft add/delete with nftrace enabled test returned 0 root@marvin-IdeaPad-3-15ITL6:/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter# There was no stall after "nft reload test" in a standalone superuser run. Hope this helps. Kind regards, Mirsad -- Mirsad Goran Todorovac Sistem inženjer Grafički fakultet | Akademija likovnih umjetnosti Sveučilište u Zagrebu -- System engineer Faculty of Graphic Arts | Academy of Fine Arts University of Zagreb, Republic of Croatia The European Union ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: PROBLEM: Hang in selftests/netfilter/nft_trans_stress.sh 2023-01-03 15:35 ` Mirsad Goran Todorovac @ 2023-01-03 16:11 ` Florian Westphal 2023-01-03 21:17 ` Mirsad Goran Todorovac 0 siblings, 1 reply; 4+ messages in thread From: Florian Westphal @ 2023-01-03 16:11 UTC (permalink / raw) To: Mirsad Goran Todorovac Cc: Florian Westphal, linux-kselftest, LKML, Shuah Khan, Jakub Kicinski Mirsad Goran Todorovac <mirsad.todorovac@alu.unizg.hr> wrote: > > Can you send me the output of 'bash -x nft_trans_stress.sh'? > > It should tell which command/program isn't making progress. > > Hi, Florian! > > Well, when ran alone, the script ended successfully: > > root@marvin-IdeaPad-3-15ITL6:/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter# bash nft_trans_stress.sh > PASS: nft add/delete test returned 0 > PASS: nft reload test returned 0 > PASS: nft add/delete with nftrace enabled test returned 0 > PASS: nft add/delete with nftrace enabled test returned 0 > root@marvin-IdeaPad-3-15ITL6:/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter# > > There was no stall after "nft reload test" in a standalone superuser run. Hmm. Does this patch make it work when running via 'make kselftest'? diff --git a/tools/testing/selftests/netfilter/nft_trans_stress.sh b/tools/testing/selftests/netfilter/nft_trans_stress.sh --- a/tools/testing/selftests/netfilter/nft_trans_stress.sh +++ b/tools/testing/selftests/netfilter/nft_trans_stress.sh @@ -10,12 +10,20 @@ ksft_skip=4 testns=testns-$(mktemp -u "XXXXXXXX") +tmp="" tables="foo bar baz quux" global_ret=0 eret=0 lret=0 +cleanup() { + ip netns pids "$testns" | xargs kill 2>/dev/null + ip netns del "$testns" + + rm -f "$tmp" +} + check_result() { local r=$1 @@ -43,6 +51,7 @@ if [ $? -ne 0 ];then exit $ksft_skip fi +trap cleanup EXIT tmp=$(mktemp) for table in $tables; do @@ -139,11 +148,4 @@ done check_result $lret "add/delete with nftrace enabled" -pkill -9 ping - -wait - -rm -f "$tmp" -ip netns del "$testns" - exit $global_ret ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: PROBLEM: Hang in selftests/netfilter/nft_trans_stress.sh 2023-01-03 16:11 ` Florian Westphal @ 2023-01-03 21:17 ` Mirsad Goran Todorovac 0 siblings, 0 replies; 4+ messages in thread From: Mirsad Goran Todorovac @ 2023-01-03 21:17 UTC (permalink / raw) To: Florian Westphal; +Cc: linux-kselftest, LKML, Shuah Khan, Jakub Kicinski On 03. 01. 2023. 17:11, Florian Westphal wrote: > Mirsad Goran Todorovac <mirsad.todorovac@alu.unizg.hr> wrote: >>> Can you send me the output of 'bash -x nft_trans_stress.sh'? >>> It should tell which command/program isn't making progress. >> >> Hi, Florian! >> >> Well, when ran alone, the script ended successfully: >> >> root@marvin-IdeaPad-3-15ITL6:/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter# bash nft_trans_stress.sh >> PASS: nft add/delete test returned 0 >> PASS: nft reload test returned 0 >> PASS: nft add/delete with nftrace enabled test returned 0 >> PASS: nft add/delete with nftrace enabled test returned 0 >> root@marvin-IdeaPad-3-15ITL6:/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter# >> >> There was no stall after "nft reload test" in a standalone superuser run. > > Hmm. Does this patch make it work when running via 'make kselftest'? > > diff --git a/tools/testing/selftests/netfilter/nft_trans_stress.sh b/tools/testing/selftests/netfilter/nft_trans_stress.sh > --- a/tools/testing/selftests/netfilter/nft_trans_stress.sh > +++ b/tools/testing/selftests/netfilter/nft_trans_stress.sh > @@ -10,12 +10,20 @@ > ksft_skip=4 > > testns=testns-$(mktemp -u "XXXXXXXX") > +tmp="" > > tables="foo bar baz quux" > global_ret=0 > eret=0 > lret=0 > > +cleanup() { > + ip netns pids "$testns" | xargs kill 2>/dev/null > + ip netns del "$testns" > + > + rm -f "$tmp" > +} > + > check_result() > { > local r=$1 > @@ -43,6 +51,7 @@ if [ $? -ne 0 ];then > exit $ksft_skip > fi > > +trap cleanup EXIT > tmp=$(mktemp) > > for table in $tables; do > @@ -139,11 +148,4 @@ done > > check_result $lret "add/delete with nftrace enabled" > > -pkill -9 ping > - > -wait > - > -rm -f "$tmp" > -ip netns del "$testns" > - > exit $global_ret I've got the following output: make[2]: Entering directory '/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter' TAP version 13 1..17 # selftests: netfilter: nft_trans_stress.sh # PASS: nft add/delete test returned 0 # PASS: nft reload test returned 0 # not ok 1 selftests: netfilter: nft_trans_stress.sh # TIMEOUT 45 seconds # selftests: netfilter: nft_fib.sh # PASS: fib expression did not cause unwanted packet drops It did not hang, but still did not finish all 4 tests correctly like when ran standalone: root@marvin-IdeaPad-3-15ITL6:/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter# time ./nft_trans_stress.sh PASS: nft add/delete test returned 0 PASS: nft reload test returned 0 PASS: nft add/delete with nftrace enabled test returned 0 PASS: nft add/delete with nftrace enabled test returned 0 real 1m11.014s user 0m6.470s sys 0m20.344s root@marvin-IdeaPad-3-15ITL6:/home/marvin/linux/kernel/linux_torvalds/tools/testing/selftests/netfilter# I hope we're closer to the solution. Kind regards, Mirsad -- Mirsad Goran Todorovac Sistem inženjer Grafički fakultet | Akademija likovnih umjetnosti Sveučilište u Zagrebu -- System engineer Faculty of Graphic Arts | Academy of Fine Arts University of Zagreb, Republic of Croatia The European Union ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-01-03 21:18 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <281b5a5e-4b56-ef6f-9896-49b364924662@alu.unizg.hr>
2023-01-03 14:28 ` PROBLEM: Hang in selftests/netfilter/nft_trans_stress.sh Florian Westphal
2023-01-03 15:35 ` Mirsad Goran Todorovac
2023-01-03 16:11 ` Florian Westphal
2023-01-03 21:17 ` Mirsad Goran Todorovac
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox