Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

我获取到的ipv6不能ping通 #25

Open
wxy1343 opened this issue Jul 3, 2020 · 0 comments
Open

我获取到的ipv6不能ping通 #25

wxy1343 opened this issue Jul 3, 2020 · 0 comments

Comments

@wxy1343
Copy link

wxy1343 commented Jul 3, 2020

get_lan_ipv46
p6=$(echo "$($IP2 -6 neigh show dev $e)" | set_lowercase | grep -w $m | grep -v '^fe80' | awk '{print $1}' | tail -n1 | awk '{print $NF}')
我获取到的ipv6列表有的ping不通
建议可以先ping一下
p6=$(echo "$($IP2 -6 neigh show dev $e)" | set_lowercase | grep -w $m | grep -v '^fe80' | awk '{print $1}')
for i in $p6; do ping -6 -c 1 -W 1 $i>/dev/zero;if [ $? == 0 ]; then echo $i ping success; p6=$i; break; else echo $i ping fail; fi; done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant