Skip to content

Output: Add json output#285

Merged
brb merged 1 commit intocilium:mainfrom
darox:add-json-output-rev2
Mar 17, 2024
Merged

Output: Add json output#285
brb merged 1 commit intocilium:mainfrom
darox:add-json-output-rev2

Conversation

@darox
Copy link
Contributor

@darox darox commented Nov 2, 2023

This commit adds a command line flag that enables
outputting pwru events in json format.

Copy link
Member

@brb brb left a comment

Choose a reason for hiding this comment

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

Thanks! And sorry for taking so long to review.

@darox darox force-pushed the add-json-output-rev2 branch from e989b66 to a295a85 Compare December 20, 2023 15:43
@darox darox force-pushed the add-json-output-rev2 branch 3 times, most recently from 67fc0d9 to 64d20c8 Compare January 8, 2024 15:39
@darox darox force-pushed the add-json-output-rev2 branch from 64d20c8 to 12d6de2 Compare February 26, 2024 09:53
@darox darox requested a review from a team as a code owner February 26, 2024 09:53
@darox darox requested review from brb and removed request for a team February 26, 2024 09:53
@brb
Copy link
Member

brb commented Feb 29, 2024

Thanks! Could you drop the second commit (git fetch -u origin && git rebase origin/main should do the job instead).

@darox darox force-pushed the add-json-output-rev2 branch 4 times, most recently from e80048a to e08299e Compare February 29, 2024 15:17
@darox
Copy link
Contributor Author

darox commented Feb 29, 2024

Thanks! Could you drop the second commit (git fetch -u origin && git rebase origin/main should do the job instead).

done

@brb
Copy link
Member

brb commented Mar 1, 2024

@darox Thanks. The PR got into a funky state (it's undoing some changes in some previous PRs). Could you rebase against the latest main (git fetch -u origin && git rebase origin/main && git push --force-with-lease)?

@darox darox force-pushed the add-json-output-rev2 branch from e08299e to 4640367 Compare March 1, 2024 10:30
@darox
Copy link
Contributor Author

darox commented Mar 1, 2024

@darox Thanks. The PR got into a funky state (it's undoing some changes in some previous PRs). Could you rebase against the latest main (git fetch -u origin && git rebase origin/main && git push --force-with-lease)?

I'm sorry. I had a merge conflict then fixed it, which merged main into this branch. Then I reset to my commit and pushed. I now executed your command.

@brb
Copy link
Member

brb commented Mar 4, 2024

@darox The CI failures look legit. With --backend=kprobe, the file content:

               SKB    CPU          PROCESS                     FUNC
               SKB    CPU          PROCESS                     FUNC
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]             ip_local_out192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]           __ip_local_out192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]             nf_hook_slow192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522] kfree_skb_reason(SKB_DROP_REASON_NETFILTER_DROP)192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]   skb_release_head_state192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]                tcp_wfree192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]         skb_release_data192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]             kfree_skbmem192.168.18.185:41624->1.0.0.1:8080(tcp)

There is no space between "kfree_skbmem" and "192.168.18.185:41624".

@darox
Copy link
Contributor Author

darox commented Mar 4, 2024

@darox The CI failures look legit. With --backend=kprobe, the file content:

               SKB    CPU          PROCESS                     FUNC
               SKB    CPU          PROCESS                     FUNC
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]             ip_local_out192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]           __ip_local_out192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]             nf_hook_slow192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522] kfree_skb_reason(SKB_DROP_REASON_NETFILTER_DROP)192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]   skb_release_head_state192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]                tcp_wfree192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]         skb_release_data192.168.18.185:41624->1.0.0.1:8080(tcp)
0xffff91a34c09cae8      8 [/usr/bin/curl:230522]             kfree_skbmem192.168.18.185:41624->1.0.0.1:8080(tcp)

There is no space between "kfree_skbmem" and "192.168.18.185:41624".

I will take a look tomorrow.

This commit adds a command line flag that enables
outputting pwru events in json format.

Signed-off-by: darox <maderdario@gmail.com>
@darox darox force-pushed the add-json-output-rev2 branch from 4640367 to 0d8a474 Compare March 5, 2024 15:07
@darox
Copy link
Contributor Author

darox commented Mar 5, 2024

@brb all checks passed now.

Copy link
Member

@brb brb left a comment

Choose a reason for hiding this comment

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

Thanks!

@brb brb merged commit d10f9c4 into cilium:main Mar 17, 2024
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