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

mwan3: fix grep order for nping track method #24859

Merged
merged 1 commit into from
Sep 5, 2024
Merged

Conversation

ealdaz-seesai
Copy link
Contributor

@ealdaz-seesai ealdaz-seesai commented Aug 21, 2024

The grep parameters in the nping test appear to be in the wrong order. grep expects pattern and then filename.

Run tested:

DISTRIB_ID='OpenWrt'
DISTRIB_RELEASE='21.02.0'
DISTRIB_REVISION='r16279-5cc0535800'
DISTRIB_TARGET='ipq40xx/generic'
DISTRIB_ARCH='arm_cortex-a7_neon-vfpv4'
DISTRIB_DESCRIPTION='OpenWrt 21.02.0 r16279-5cc0535800'
DISTRIB_TAINTS='no-all busybox'

Description:
Setting nping as a track_method option in /etc/config/mwan3 would always result in the interface failing all checks and becoming offline.

config condition
	option interface 'mob2s1a1'
	option reliability '1'
	option count '1'
	option timeout '1'
	option down '3'
	option up '3'
	option track_method 'nping'
	list track_ip 'www.google.co.uk'
	option interval '2'

Changing the line in mwan3track
result=$(grep $TRACK_OUTPUT Lost | awk '{print $12}')
to
result=$(grep Lost $TRACK_OUTPUT | awk '{print $12}')
results in mwan3tracking behaving as expected, and the interface is correctly identified as being online.

@BKPepe BKPepe requested a review from feckert August 22, 2024 06:26
Copy link
Member

@feckert feckert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have the following commits to this PR:

  • Please change the commit message of your commit in this PR from Update mwan3track to mwan3: fix grep order for nping track methode
  • Add a valid Signed-off-by to this commit so we have your realname and a valid email address.
  • Also update the PKG_VERSION from 2.11.13 to 2.11.14.

@ealdaz-seesai ealdaz-seesai changed the title Update mwan3track mwan3: fix grep order for nping track method Aug 27, 2024
@feckert
Copy link
Member

feckert commented Sep 2, 2024

CI/CD is still not happy! I think the name in your git config (your commit name) and your name in the Signed-off-by line is not the same.
Can you please also rebase again and bump the PKG_RELEASE by one. I have recently merged a commit with the same PKG_RELEASE number.

@feckert
Copy link
Member

feckert commented Sep 4, 2024

@ealdaz-seesai I think something has gone wrong during rebase!

Copy link
Member

@feckert feckert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have now 4 commits! And the PKG_RELEASE is still not updated.
Please look at this again.

@ealdaz-seesai
Copy link
Contributor Author

ealdaz-seesai commented Sep 4, 2024 via email

@ealdaz-seesai
Copy link
Contributor Author

Bumped up versions and changed author.
Hope it's all OK now.

@feckert feckert merged commit 6b2e5c7 into openwrt:master Sep 5, 2024
13 checks passed
@feckert
Copy link
Member

feckert commented Sep 5, 2024

Thanks merged!

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

Successfully merging this pull request may close these issues.

2 participants