Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Add a ping module#1623

Merged
FelicianoTech merged 2 commits intowtfutil:trunkwtfutil/wtf:trunkfrom
tabell:pingtabell/wtf:pingCopy head branch name to clipboard
Oct 13, 2025
Merged

Add a ping module#1623
FelicianoTech merged 2 commits intowtfutil:trunkwtfutil/wtf:trunkfrom
tabell:pingtabell/wtf:pingCopy head branch name to clipboard

Conversation

@tabell
Copy link
Copy Markdown
Contributor

@tabell tabell commented Jan 15, 2024

This adds a very basic Ping module, for when you need to see if a service is online but you can't / don't want to use a third-party API like updown.io. Sends an ICMP (or UDP) echo request and displays whether a response was received.

Note: sending ICMP is a privileged operation on some versions of Linux, so you either need to grant the wtf binary CAP_NET_RAW capability or allow unprivileged users to send UDP pings https://github.com/prometheus-community/pro-bing#linux

I haven't tested on Windows or anything other than Linux.

This is my first wtf module so there's probably a bunch of stuff that could be better / cleaner. Happy to make changes / improvements based on suggestions.

@stale
Copy link
Copy Markdown

stale bot commented Jul 13, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Jul 13, 2024
@huyz
Copy link
Copy Markdown
Contributor

huyz commented Sep 7, 2024

This would be useful

@stale stale bot removed the wontfix label Sep 7, 2024
@FelicianoTech FelicianoTech added this to the v0.46.0 milestone Jun 23, 2025
@FelicianoTech
Copy link
Copy Markdown
Collaborator

Hey @tabell,

First of all, thank you for the PR. I know it's been over a year since you've submitted it. I'm just taking the reins for this project and I'm doing my best to go through all of the old Issues and PRs.

Do you still use WTF? Are you still interested in this PR? I tested it out, I have some questions/potential changes. I'm curious if you be willing to either 1) Work with me on getting the PR ready or if 2) I can take the PR from here and make the needed changes. If there isn't a response, I'll assume the latter.

@tabell
Copy link
Copy Markdown
Contributor Author

tabell commented Jul 12, 2025 via email

@FelicianoTech
Copy link
Copy Markdown
Collaborator

FelicianoTech commented Jul 28, 2025

So when I tested this PR, I put together an example WTF config. I wasn't sure the config you intended but I got something work. I was curious, how do you intend the config to look like for this module?

The one I made is on my other laptop, which is currently 1,000 miles away. I'll see if I can recover what I did so we can compare.

Lastly, considering the age of this PR, a rebase would help. Current code and it can then run the current test suite. 1 commit instead of the two currently would do.

@FelicianoTech FelicianoTech modified the milestones: v0.46.0, v0.47.0 Aug 7, 2025
@FelicianoTech
Copy link
Copy Markdown
Collaborator

Since there's been no response, I went ahead with some changes of my own. I kept the majority of the code but made this changes to the PR:

  • renamed some terminology: targets -> hosts
  • altered how the config works a little. See below.
  • Added some validation for label and hostname
  • made label optional

This will be in WTF version v0.47.0.

@FelicianoTech
Copy link
Copy Markdown
Collaborator

Docs need to be created for this new module. I made a tracking issue here: wtfutil/wtfdocs#192

@FelicianoTech FelicianoTech merged commit 0c84ca4 into wtfutil:trunk Oct 13, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.