From: Richard Palethorpe <rpalethorpe@suse.de>
To: Petr Vorel <pvorel@suse.cz>
Cc: ltp@lists.linux.it, Xu Senmiao <xusenmiao@huawei.com>
Subject: Re: [LTP] [PATCH v2 1/1] ipneigh01.sh: Add workaround for ARP timeout
Date: Thu, 23 Nov 2023 10:59:45 +0000 [thread overview]
Message-ID: <878r6o913t.fsf@suse.de> (raw)
In-Reply-To: <20230922155507.604020-1-pvorel@suse.cz>
Hello
Petr Vorel <pvorel@suse.cz> writes:
> From: Xu Senmiao <xusenmiao@huawei.com>
>
> When the ARP status of the rhost is stale,
> lhost ping rhost and the lhost deletes the ARP record,
> the record in the rhost changes from stale to delay.
>
> Then, the probe request is sent to the lhost, and the lhost ARP
> information is updated.
>
> rhost(10.0.0.1) lhost(10.0.0.2)
> t1 10.0.0.2 STALE ping 10.0.0.1
> 10.0.0.1 REACHABLE
> arp -d 10.0.0.1
> t2 10.0.0.2 DELAY
> t3 probe 10.0.0.2
> t4 10.0.0.1 REACHABLE
>
> Clear the ARP entries of rhost before each round of test.
> This fixes an issue where ipneigh01_arp fail due to ARP timeout.
>
> Signed-off-by: Xu Senmiao <xusenmiao@huawei.com>
> [ pvorel: use $DEL_CMD ]
> Signed-off-by: Petr Vorel <pvorel@suse.cz>
> ---
> Changes v1->v2:
> * Using DEL_CMD to fix working on system without arp installed.
>
> Xu, can you confirm that it fixes your problem?
> Also, do you have this problem also on IPv6?
> Could you test both arp and ip?
> Also, do you have any idea why rhost get stale?
We need an answer to why the rhost is stale before merging this. It's
not clear that there is a test bug.
I will set this to changes requested in patchwork.
>
> Kind regards,
> Petr
>
> testcases/network/tcp_cmds/ipneigh/ipneigh01.sh | 7 ++++---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/testcases/network/tcp_cmds/ipneigh/ipneigh01.sh b/testcases/network/tcp_cmds/ipneigh/ipneigh01.sh
> index e67ff5cc8..f37241d49 100755
> --- a/testcases/network/tcp_cmds/ipneigh/ipneigh01.sh
> +++ b/testcases/network/tcp_cmds/ipneigh/ipneigh01.sh
> @@ -19,14 +19,14 @@ do_setup()
> case $CMD in
> ip)
> SHOW_CMD="ip neigh show"
> - DEL_CMD="ROD ip neigh del $(tst_ipaddr rhost) dev $(tst_iface)"
> + DEL_CMD="ip neigh del $(tst_ipaddr rhost) dev $(tst_iface)"
> ;;
> arp)
> if [ -n "$TST_IPV6" ]; then
> tst_brk TCONF "'arp' doesn't support IPv6"
> fi
> SHOW_CMD="arp -an"
> - DEL_CMD="ROD arp -d $(tst_ipaddr rhost) -i $(tst_iface)"
> + DEL_CMD="arp -d $(tst_ipaddr rhost) -i $(tst_iface)"
> ;;
> *)
> tst_brk TBROK "unknown or missing command, use -c [ arp | ip ]"
> @@ -56,6 +56,7 @@ do_test()
> tst_res TINFO "stress auto-creation $entry_name cache entry deleted with '$CMD' $NUMLOOPS times"
>
> for i in $(seq 1 $NUMLOOPS); do
> + $DEL_CMD
>
> ping$TST_IPV6 -q -c1 $(tst_ipaddr rhost) -I $(tst_iface) > /dev/null || \
> tst_brk TFAIL "cannot ping $(tst_ipaddr rhost)"
> @@ -74,7 +75,7 @@ do_test()
> [ "$ret" -ne 0 ] && \
> tst_brk TFAIL "$entry_name entry '$(tst_ipaddr rhost)' not listed"
>
> - $DEL_CMD
> + ROD $DEL_CMD
>
> $SHOW_CMD | grep -q "$(tst_ipaddr rhost).*$(tst_hwaddr rhost)" && \
> tst_brk TFAIL "'$DEL_CMD' failed, entry has " \
> --
> 2.40.1
--
Thank you,
Richard.
--
Mailing list info: https://lists.linux.it/listinfo/ltp
prev parent reply other threads:[~2023-11-23 15:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-22 15:55 [LTP] [PATCH v2 1/1] ipneigh01.sh: Add workaround for ARP timeout Petr Vorel
2023-11-23 10:59 ` Richard Palethorpe [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878r6o913t.fsf@suse.de \
--to=rpalethorpe@suse.de \
--cc=ltp@lists.linux.it \
--cc=pvorel@suse.cz \
--cc=xusenmiao@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.