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

[xdp] Add XDP plugin #2079

Closed
wants to merge 1 commit into from
Closed

[xdp] Add XDP plugin #2079

wants to merge 1 commit into from

Conversation

tohojo
Copy link
Contributor

@tohojo tohojo commented May 20, 2020

This adds a plugin for gathering information about the loaded XDP programs
on a system, using the xdp-loader tool in the xdp-tools package. This is
complementary with the existing eBPF plugin, because this plugin supports
getting status for multiple XDP programs on each interface as supported by
libxdp.

For now, this just prints the output of 'xdp-loader status' which will list
any XDP programs attached. We don't currently support structured
output (such as JSON) from xdp-tools, but should we add that in the future
we can of course update this plugin.


Please place an 'X' inside each '[]' to confirm you adhere to our Contributor Guidelines

  • Is the commit message split over multiple lines and hard-wrapped at 72 characters?
  • Is the subject and message clear and concise?
  • Does the subject start with [plugin_name] if submitting a plugin patch or a [section_name] if part of the core sosreport code?
  • Does the commit contain a Signed-off-by: First Lastname email@example.com?
  • If this commit closes an existing issue, is the line Closes: #ISSUENUMBER included in an independent line?
  • If this commit resolves an existing pull request, is the line Resolves: #PRNUMBER included in an independent line?

#
# See the LICENSE file in the source distribution for further information.

from sos.report.plugins import Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin
Copy link
Member

Choose a reason for hiding this comment

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

Looks like Travis didn't run, but this seems to be over 79 characters, so we'll need to wrap it for PEP8.

Copy link
Member

Choose a reason for hiding this comment

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

Perhaps it's time we added an __all__ member to sos.report.plugins? It's not everyone's stylistic cup-of-tea but I use it heavily in other projects that are designed to use * imports and shared namespaces.

@tohojo
Copy link
Contributor Author

tohojo commented May 20, 2020 via email

This adds a plugin for gathering information about the loaded XDP programs
on a system, using the xdp-loader tool in the xdp-tools package. This is
complementary with the existing eBPF plugin, because this plugin supports
getting status for multiple XDP programs on each interface as supported by
libxdp.

For now, this just prints the output of 'xdp-loader status' which will list
any XDP programs attached. We don't currently support structured
output (such as JSON) from xdp-tools, but should we add that in the future
we can of course update this plugin.

Signed-off-by: Toke Høiland-Jørgensen <toke@redhat.com>
@TurboTurtle
Copy link
Member

Merged in af5597b

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.

None yet

4 participants