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

NETOBSERV-2045: Create packets xlation blog for netobserv #3

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

msherif1234
Copy link

Adding Packets translation blog

Copy link

@skrthomas skrthomas left a comment

Choose a reason for hiding this comment

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

Thanks for the blog. Looks really good and easy to use/read. Left you a few style/consistency comments per my usual copy editing. :)


## How eBPF Can Help

eBPF allows you to execute custom programs in the Linux kernel, making it an ideal tool for network observability.

Choose a reason for hiding this comment

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

Suggested change
eBPF allows you to execute custom programs in the Linux kernel, making it an ideal tool for network observability.
You can execute custom programs using/with eBPF in the Linux kernel, making it an ideal tool for network observability. Notable benefits of using eBPF include the following:
- Granular Observability: Directly see which pod served a request.
- Low Overhead: Operates in the kernel with minimal impact on performance.
- Dynamic Updates: Respond to changes in Kubernetes without requiring application restarts.
- Simplified Architecture: No need for sidecars or intrusive network plugins.

Choose a reason for hiding this comment

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

Suggest rephrasing like this to keep this centered on what the user can do and less technology-centric.

Also suggest incorporating that list from the end of this section to here because I think its more valuable up front with the intro than as a summary item, but I leave that up to you.

Comment on lines 42 to 45
Attach eBPF Programs:
Use eBPF programs to hook into kernel networking events, such as kprobe on functions like `nf_nat_manip_pkt`.

Enrich Flow Logs:

Choose a reason for hiding this comment

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

Should these be numbered 🤔 it seems to me like they're sequential steps in the process. Also, I think all these words don't need to be capitalized.

Suggested change
Attach eBPF Programs:
Use eBPF programs to hook into kernel networking events, such as kprobe on functions like `nf_nat_manip_pkt`.
Enrich Flow Logs:
1. Attach the eBPF programs:
Use the eBPF programs to hook into kernel networking events, such as kprobe on functions like `nf_nat_manip_pkt`.
2. Enrich flow logs:

Use eBPF programs to hook into kernel networking events, such as kprobe on functions like `nf_nat_manip_pkt`.

Enrich Flow Logs:
As network packets are processed, augment flow logs with metadata about the translated endpoint. This can include:

Choose a reason for hiding this comment

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

Question, does the augmentation happen as the network packets are processed? Or is it something the user manually has to refresh. The wording here makes it seem like the user needs to augment the flow logs with metadata, and if that's the case, maybe a "you can" before the augment would be a good clarification.

Copy link
Author

Choose a reason for hiding this comment

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

that is what ebpf code will do user doesn't need to do anything

Comment on lines 60 to 68
Benefits of Using eBPF

Granular Observability: Directly see which pod served a request.

Low Overhead: Operates in the kernel with minimal impact on performance.

Dynamic Updates: Respond to changes in Kubernetes without requiring application restarts.

Simplified Architecture: No need for sidecars or intrusive network plugins.

Choose a reason for hiding this comment

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

Hmmmm....I wonder about relocating this to the introduction of the How ePBF Helps section. I'll make another comment with this suggestion and see what you think.


## How to enable Packet Translation enrichment feature

To enable packet translation enrichment feature, need to create a flow collector with the following feature enabled

Choose a reason for hiding this comment

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

Suggested change
To enable packet translation enrichment feature, need to create a flow collector with the following feature enabled
To enable packet translation enrichment feature, create a `FlowCollector` resource with the following feature enabled

Choose a reason for hiding this comment

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

You can have "create" as an imperative without saying "need to". Additionally, FlowCollector should be in backticks since its the API


## Example

To demonstrate this feature, let's configure a `CluesterIP` kubernetes service using the following example yaml

Choose a reason for hiding this comment

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

Suggested change
To demonstrate this feature, let's configure a `CluesterIP` kubernetes service using the following example yaml
Let's configure a `CluesterIP` Kubernetes service to try this feature!
1. Configure a `CluesterIP` Kubernetes service using the following example yaml:

Choose a reason for hiding this comment

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

I think there was an extra whitespace here and also Kubernetes needs a capital K

Choose a reason for hiding this comment

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

Additionally, add a colon to introduce the yaml sample, and I'm wondering what you think about numbering here? I think it helps, especially further down the example, to emphasize the steps.

type: ClusterIP
```

check the created service to find the `CluterIP` and `Port`

Choose a reason for hiding this comment

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

Suggested change
check the created service to find the `CluterIP` and `Port`
2. Check the created service to find the `CluterIP` and `Port`:

Choose a reason for hiding this comment

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

Furthering my numbering suggestion from the previous comment and also adding a colon to introduce the code.


```

Then we can send traffic to this service IP and check the enriched flows on the netobserv console

Choose a reason for hiding this comment

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

Suggested change
Then we can send traffic to this service IP and check the enriched flows on the netobserv console
3. Next, you can send traffic to this service IP and check the enriched flows on the network observability console:

Choose a reason for hiding this comment

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

  • suggest you vs we to make it more customer-centric.
  • I think since we refer to the console here, best to call it network observability since that whole name will be spelled out in the console.
  • add a colon to introduce the code.

$ while true; do oc exec -i -n xlat-test client -- curl 172.30.165.151:80 ; sleep 1; done
```

from Netobserv console let's filter on Traffic destination `Kind` is `Service` in `xlat-test` namespace

Choose a reason for hiding this comment

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

Suggested change
from Netobserv console let's filter on Traffic destination `Kind` is `Service` in `xlat-test` namespace
4. From the network observability console **Network Traffic** page, click the *Taffic flows* tab and filter on Traffic destination `Kind` is `Service` in the `xlat-test` namespace:

Choose a reason for hiding this comment

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

I suggest clarifying the exact area of the console where they'll need to be working.


<img src="{page.image('packets-xlation-enrichment/pkt-xlat-ip-port.png')}" alt="Service Traffic's Packet Translation enrichment using POD's IP and Port">

The following shows possible packet translation columns options, currently `zoneid` is the only visible column by default

Choose a reason for hiding this comment

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

Suggested change
The following shows possible packet translation columns options, currently `zoneid` is the only visible column by default
The following shows possible packet translation columns options. Currently `zoneid` is the only visible column by default:


## Example

To demonstrate this feature, let's configure a `CluesterIP` kubernetes service using the following example yaml
Copy link

Choose a reason for hiding this comment

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

extra e in ClusterIP

type: ClusterIP
```

check the created service to find the `CluterIP` and `Port`
Copy link

Choose a reason for hiding this comment

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

missing s in CluterIP

Events: <none>

$oc get pods -n xlat-test
oc get pods -n xlat-test
Copy link

Choose a reason for hiding this comment

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

Duplicate line not needed I think

@Amoghrd
Copy link

Amoghrd commented Jan 3, 2025

LGTM

@msherif1234 msherif1234 changed the title Create packets xlation blog for netobserv NETOBSERV-2040: Create packets xlation blog for netobserv Jan 8, 2025
@msherif1234 msherif1234 changed the title NETOBSERV-2040: Create packets xlation blog for netobserv NETOBSERV-2045: Create packets xlation blog for netobserv Jan 8, 2025

- Destination Port

- Conntrack Zone ID
Copy link

Choose a reason for hiding this comment

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

what is zone id?

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.

4 participants