[Kernel scoping 5/5] Fix tcp drops PxL script#1688
[Kernel scoping 5/5] Fix tcp drops PxL script#1688JamesMBartlett merged 4 commits intopixie-io:mainfrom
Conversation
…cripts depending on host Signed-off-by: Benjamin Kilimnik <bkilimnik@pixielabs.ai>
Signed-off-by: Benjamin Kilimnik <bkilimnik@pixielabs.ai>
| @@ -20,7 +20,7 @@ import pxtrace | |||
| import px | |||
There was a problem hiding this comment.
Do you know why we have these files duplicated? I wonder if we should symlink them to avoid any potential divergence if they are truly supposed to be identical.
There was a problem hiding this comment.
I'm not sure, it seems like there are a couple PxL scripts which are duplicated in the pxl_scripts/px and pxl_scripts/bpftrace directories. I agree that it would make sense to symlink them or remove a duplicate. It also looks like they were added in separate commits, so it could simply be an oversight.
$ join -j 1 <(find px/ -type f -exec md5sum {} + | sort) <(find bpftrace/ -type f -exec md5sum {} + | sort) | awk '{print $2, $3}'
px/tcp_drops/manifest.yaml bpftrace/tcp_drops/manifest.yaml
px/tcp_drops/data.pxl bpftrace/tcp_drops/data.pxl
px/tcp_drops/vis.json bpftrace/tcp_drops/vis.json
px/tcp_retransmits/manifest.yaml bpftrace/tcp_retransmits/manifest.yaml
px/tcp_retransmits/vis.json bpftrace/tcp_retransmits/vis.json
px/tcp_restransmits/data.pxl bpftrace/tcp_retransmits/data.pxlThere was a problem hiding this comment.
Removed the duplicate tcp_drops script in px in the most recent commit. Going to open a separate PR for tcp_retransmits.
… issues Signed-off-by: Benjamin Kilimnik <bkilimnik@pixielabs.ai>
Signed-off-by: Benjamin Kilimnik <bkilimnik@pixielabs.ai>
|
@benkilimnik It appears that the README contains references to px/tcp_drops that have been deleted. |
|
@RagalahariP thanks for mentioning this. I've updated the README in #1725. |
Summary: Updates the currently broken
tcp_dropsPxL script to use a different BPFtrace program depending on the kernel version of the host it is deployed to.Related issues: Fixes #1582
Type of change: /kind bug
Test Plan: Verified that new script works on kernels >=5.19.
Note: due to backported changes (i.e. the kprobe was removed in older versions of the kernel), the old bpftrace script may not work on some older kernels <5.19. Unfortunately, the new script may also not work on older kernels because of other unsupported features. More testing is required to modify the oldtcp_dropsscript to work on kernels <5.19.