<div dir="ltr">Thanks for your responses Sylvain. I've tried with a new query using your suggestion and it works really good.<div><br></div><div><span style="color:rgb(255,255,255);font-family:monospace;font-size:11px;background-color:rgb(51,51,51)">G.V().Has('Name', Regex('_openshift-infra_')).Out().Has("Type", "veth")</span></div><div><font color="#ffffff" face="monospace"><span style="font-size:11px"><br></span></font></div><div><span style="background-color:rgb(51,51,51)"></span>I'm not using IRC anymore as we always have issues to connect to Red Hat VPN from Customers. Are you guys in RocketChat or Slack?</div><div><br></div><div>Regarding "sensibility" what I mean is that every time we have tried to enable agents on each Cluster Node, we were not able to see them in Skydive and we got errors like the one I shared with you last week:</div><div><br></div><div><span style="font-size:12.8px">wsserver.go:194 http (*WSClient).readPump > ERRO 015 Error while reading websocket from : websocket: close 1001</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">We have also noticed that if we disabled the agent for a particular Node and we enabled again later, the Node doesn't appear anymore and we have to restart the analyzer and elasticsearch containers. These are ephemeral yet, so restarting them basically removes every collected data and we can start again.</span></div><div><span style="font-size:12.8px"><br></span></div><div><span style="font-size:12.8px">Thanks,</span></div><div><span style="font-size:12.8px">Mak<br></span><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Mar 1, 2017 at 11:19 AM, Sylvain Afchain <span dir="ltr"><<a href="mailto:safchain@redhat.com" target="_blank">safchain@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Marcos,<br>
<br>
According to your screenshots, you wrote a gremlin expression that matches namespaces. Skydive can't start a capture on such object. If you want to start a capture on all the interfaces(eth0) within a namespaces you need to add the "Out()" step. Ex: G.V().Has('Name', Regex('_test123_')).Out().Has(<wbr>"Name", "eth0")<br>
<br>
Another option is to add captures on ovs bridges so that you will capture all the traffic. Once started you should be able to filter the traffic<br>
for the namespace interfaces like this.<br>
<span class=""><br>
G.V().Has('Name', Regex('_test123_')).Out().<wbr>Flows()<br>
<br>
</span>Meaning:<br>
<br>
G.V().Has('Name', Regex('_test123_')).Out() will return you the interfaces belonging to namespaces. Adding the Flows() step will return flows of the namespace interfaces.<br>
<br>
<br>
What do you mean by "sensible" and "sync" ? There is an heartbeat mechanism between agents and analyzers which can be adapted in the conf: ws_pong_timeout. The default value is 5 sec which is usually enough but can be increased.<br>
<br>
We did some scaling test and we never add such issue between agents and analyzers.<br>
<br>
Feel free to join the skydive-project chan on IRC.<br>
<br>
Thanks<br>
<div class="HOEnZb"><div class="h5"><br>
Sylvain<br>
<br>
----- Mail original -----<br>
> Hi Sylvain,<br>
><br>
> What I mean is that if I use the Regex method for the capture, Skydive<br>
> filter the objects which belong to that Namespace correctly as you can see<br>
> in [skydive01.png] and [skydive02.png], but no interfaces are included so<br>
> there are no flows as you can see in [skydive03.png]. But if I select one<br>
> of the 'veth' interfaces corresponding to these containers I can see the<br>
> flow [skydive04.png]<br>
><br>
> From the tests I have been performed and from some Customers feedback, we<br>
> also have the feeling that the communication between the agents and the<br>
> analyser is quite "sensible", and we got many warnings when the sync<br>
> duration exceeds 1s. Is this something configurable to be more "permissive"?<br>
><br>
> Thanks,<br>
> Mak<br>
><br>
><br>
> On Tue, Feb 28, 2017 at 3:33 PM, Sylvain Afchain <<a href="mailto:safchain@redhat.com">safchain@redhat.com</a>><br>
> wrote:<br>
><br>
> > Hi Marcos,<br>
> ><br>
> > Where did you start your capture ? Do you have flows ? I mean just doing<br>
> > "G.Flows()", if so can you check that ANodeTID or BNodeTID match a node TID<br>
> > of the namespaces ?<br>
> ><br>
> > Thanks,<br>
> ><br>
> > Sylvain<br>
> ><br>
> > ----- Mail original -----<br>
> > > Hi Sylvain,<br>
> > ><br>
> > > It works almost perfect, thanks. I can see the pods for the namespace,<br>
> > but<br>
> > > I can't see any flows...<br>
> > ><br>
> > > Regards,<br>
> > > Mak<br>
> > ><br>
> > > On Thu, Feb 23, 2017 at 3:05 PM, Sylvain Afchain <<a href="mailto:safchain@redhat.com">safchain@redhat.com</a>><br>
> > > wrote:<br>
> > ><br>
> > > > Hi Marcos,<br>
> > > ><br>
> > > > From what I understand, in OCP there is one network namespace per Pod,<br>
> > > > each Pod belongs to a project. The name of the project is contained in<br>
> > the<br>
> > > > "Name" of the Skydive nodes. Let's say we have a project called<br>
> > "test123",<br>
> > > > we will have<br>
> > > > nodes(network namespaces) with names like "k8s_..._test123_...". So if<br>
> > you<br>
> > > > do the following request, you should be able to get all the network<br>
> > > > namespaces (meaning pods) for a project.<br>
> > > ><br>
> > > > G.V().Has('Name', Regex('_test123_'))<br>
> > > ><br>
> > > > Then if you want to get flows for these pods, just add<br>
> > > ><br>
> > > > G.V().Has('Name', Regex('_test123_')).Out().<wbr>Flows()<br>
> > > ><br>
> > > > The regex stuff is not ideal, we are working to add the project name to<br>
> > > > the node metadata (<a href="https://softwarefactory-project.io/r/6673" rel="noreferrer" target="_blank">https://softwarefactory-<wbr>project.io/r/6673</a>).<br>
> > > ><br>
> > > > Tell me if it helps a bit :)<br>
> > > ><br>
> > > > Thanks,<br>
> > > ><br>
> > > > Sylvain<br>
> > > ><br>
> > > > ----- Mail original -----<br>
> > > > > Hi Marcos,<br>
> > > > ><br>
> > > > > Great that you fixed the issue, feel free to open an issue if you<br>
> > think<br>
> > > > it's<br>
> > > > > needed.<br>
> > > > ><br>
> > > > > For the topology I will inject it tomorrow and I will send you a<br>
> > bunch of<br>
> > > > > questions accordingly :)<br>
> > > > ><br>
> > > > > Regards,<br>
> > > > ><br>
> > > > > Sylvain<br>
> > > > ><br>
> > > > > ----- Mail original -----<br>
> > > > > > Hi Sylvain,<br>
> > > > > ><br>
> > > > > > The problem has been solved ussing the kubernetes yaml file [1]<br>
> > > > (adding the<br>
> > > > > > ovs plugin) for the DaemonSet definition instead the openshift one<br>
> > [2].<br>
> > > > > ><br>
> > > > > > [1]<br>
> > > > > > <a href="https://github.com/skydive-project/skydive/blob/master/" rel="noreferrer" target="_blank">https://github.com/skydive-<wbr>project/skydive/blob/master/</a><br>
> > > > contrib/kubernetes/skydive.<wbr>yaml<br>
> > > > > > [2]<br>
> > > > > > <a href="https://github.com/skydive-project/skydive/blob/master/" rel="noreferrer" target="_blank">https://github.com/skydive-<wbr>project/skydive/blob/master/</a><br>
> > > > contrib/openshift/skydive-<wbr>template.yaml<br>
> > > > > ><br>
> > > > > > I've also enclosed the topology file.<br>
> > > > > ><br>
> > > > > > Thanks,<br>
> > > > > > Mak<br>
> > > > > ><br>
> > > > > > On Wed, Feb 22, 2017 at 12:14 PM, Marcos Entenza Garcia <<br>
> > > > <a href="mailto:mak@redhat.com">mak@redhat.com</a>><br>
> > > > > > wrote:<br>
> > > > > ><br>
> > > > > > > Hi Sylvain,<br>
> > > > > > ><br>
> > > > > > > Yes, it's blocking now as we don't see the topology. As you said,<br>
> > > > this<br>
> > > > > > > error appears every time we try to view the topology through the<br>
> > web<br>
> > > > ui,<br>
> > > > > > > and also the API is retunring just null values.<br>
> > > > > > ><br>
> > > > > > > {"Nodes":[],"Edges":[]}<br>
> > > > > > ><br>
> > > > > > > Thanks,<br>
> > > > > > ><br>
> > > > > > > Mak<br>
> > > > > > ><br>
> > > > > > ><br>
> > > > > > > On Wed, Feb 22, 2017 at 11:26 AM, Sylvain Afchain <<br>
> > > > <a href="mailto:safchain@redhat.com">safchain@redhat.com</a>><br>
> > > > > > > wrote:<br>
> > > > > > ><br>
> > > > > > >> About the error, is it blocking ? because this kind of message<br>
> > > > appears<br>
> > > > > > >> when there is a websocket disconnection which can be between<br>
> > > > > > >> analyzer/agent<br>
> > > > > > >> or just between analyzer/webui following a browser refresh.<br>
> > > > > > >><br>
> > > > > > >> For the VNID, to be sure to understand your deployment can you<br>
> > send<br>
> > > > us<br>
> > > > > > >> the topology "dump" so that we could re-inject it to an<br>
> > analyzer on<br>
> > > > our<br>
> > > > > > >> side.<br>
> > > > > > >><br>
> > > > > > >> A "curl" to http://<analyzer>/api/topology will give you the<br>
> > > > "dump".<br>
> > > > > > >><br>
> > > > > > >> Thanks,<br>
> > > > > > >><br>
> > > > > > >> Sylvain<br>
> > > > > > >><br>
> > > > > > >> ----- Mail original -----<br>
> > > > > > >> > Hi guys,<br>
> > > > > > >> ><br>
> > > > > > >> > Thanks for your responses.<br>
> > > > > > >> ><br>
> > > > > > >> > @Sylvain, I understand your approach but normally Nodes are<br>
> > shared<br>
> > > > > > >> between<br>
> > > > > > >> > different projects in OCP, so the only way to identify the<br>
> > > > specific<br>
> > > > > > >> traffic<br>
> > > > > > >> > for a Namespace is filtering but the VNID, but correct me if<br>
> > I'm<br>
> > > > > > >> > wrong.<br>
> > > > > > >> ><br>
> > > > > > >> > We are now getting the same error on different deployments<br>
> > for the<br>
> > > > > > >> > skydive-analyzer image:<br>
> > > > > > >> ><br>
> > > > > > >> > wsserver.go:194 http (*WSClient).readPump > ERRO 015 Error<br>
> > while<br>
> > > > > > >> > reading<br>
> > > > > > >> > websocket from : websocket: close 1001<br>
> > > > > > >> ><br>
> > > > > > >> > Have you guys git an idea what can cause this?<br>
> > > > > > >> ><br>
> > > > > > >> > Thanks,<br>
> > > > > > >> > Mak<br>
> > > > > > >> ><br>
> > > > > > >> ><br>
> > > > > > >> ><br>
> > > > > > >> ><br>
> > > > > > >> > On Wed, Feb 22, 2017 at 8:47 AM, Sylvain Afchain <<br>
> > > > <a href="mailto:safchain@redhat.com">safchain@redhat.com</a>><br>
> > > > > > >> > wrote:<br>
> > > > > > >> ><br>
> > > > > > >> > > Hi Marcos,<br>
> > > > > > >> > ><br>
> > > > > > >> > > Beyond the VNI support that Nicolas explained, there is a<br>
> > way<br>
> > > > to get<br>
> > > > > > >> flows<br>
> > > > > > >> > > for a given namespace. I guess you started a capture at the<br>
> > ovs<br>
> > > > > > >> bridge, if<br>
> > > > > > >> > > so you can do the following gremlin request:<br>
> > > > > > >> > ><br>
> > > > > > >> > > G.V().Has('Name', 'ns1').Out().Flows()<br>
> > > > > > >> > ><br>
> > > > > > >> > > which has to be read like this: get all the nodes with the<br>
> > name<br>
> > > > > > >> > > 'ns1'<br>
> > > > > > >> > > (your namespace), then returns the nodes belonging to this<br>
> > > > > > >> > > namespace,<br>
> > > > > > >> > > finally returns the flows for those interfaces.<br>
> > > > > > >> > ><br>
> > > > > > >> > > Regards,<br>
> > > > > > >> > ><br>
> > > > > > >> > > Sylvain<br>
> > > > > > >> > ><br>
> > > > > > >> > > ----- Mail original -----<br>
> > > > > > >> > > > Hi Marcos,<br>
> > > > > > >> > > ><br>
> > > > > > >> > > ><br>
> > > > > > >> > > > For the moment it's not possible to filter out the Flows<br>
> > with<br>
> > > > a<br>
> > > > > > >> specific<br>
> > > > > > >> > > VNI,<br>
> > > > > > >> > > > but a patch [1] is underway to support that by adding a<br>
> > > > network.ID<br>
> > > > > > >> on<br>
> > > > > > >> > > each<br>
> > > > > > >> > > > UUID where ID is GRE.key or Geneve.ID or VXLAN.VNI and<br>
> > > > Link.ID for<br>
> > > > > > >> > > <a href="http://VLAN.ID" rel="noreferrer" target="_blank">VLAN.ID</a><br>
> > > > > > >> > > ><br>
> > > > > > >> > > > So it would be possible to filter out all flows with a<br>
> > kind of<br>
> > > > > > >> query like<br>
> > > > > > >> > > > that :<br>
> > > > > > >> > > > G.V().Flows().Has(parentUUID, Within(<br>
> > > > > > >> > > > G.V().Flows().Has(application,<br>
> > > > > > >> > > 'VXLAN',<br>
> > > > > > >> > > > network.ID,<target_VNI>).<wbr>Dedup() ))<br>
> > > > > > >> > > ><br>
> > > > > > >> > > > But keep it mind it's better practice to start only<br>
> > capture<br>
> > > > > > >> interfaces<br>
> > > > > > >> > > of a<br>
> > > > > > >> > > > specific namespace, for example :<br>
> > > > > > >> > > > G.V().Has('Type', 'netns', 'Name',<br>
> > 'vm1').Out().Has('State',<br>
> > > > 'UP')<br>
> > > > > > >> > > ><br>
> > > > > > >> > > ><br>
> > > > > > >> > > > Regards,<br>
> > > > > > >> > > ><br>
> > > > > > >> > > > Nicolas<br>
> > > > > > >> > > ><br>
> > > > > > >> > > > [1] <a href="https://softwarefactory-project.io/r/#/c/6206/" rel="noreferrer" target="_blank">https://softwarefactory-<wbr>project.io/r/#/c/6206/</a><br>
> > > > > > >> > > ><br>
> > > > > > >> > > ><br>
> > > > > > >> > > > On Wed, Feb 22, 2017 at 3:22 AM, Marcos Entenza Garcia <<br>
> > > > > > >> <a href="mailto:mak@redhat.com">mak@redhat.com</a><br>
> > > > > > >> > > ><br>
> > > > > > >> > > > wrote:<br>
> > > > > > >> > > ><br>
> > > > > > >> > > ><br>
> > > > > > >> > > ><br>
> > > > > > >> > > > All,<br>
> > > > > > >> > > ><br>
> > > > > > >> > > > I've got a Skydive deployment in an OCP ovs-multitenat<br>
> > > > Cluster and<br>
> > > > > > >> I was<br>
> > > > > > >> > > > wondering if there is any method I could use to filter the<br>
> > > > traffic<br>
> > > > > > >> for<br>
> > > > > > >> > > just<br>
> > > > > > >> > > > one of the namespaces as all of them has different VNID.<br>
> > The<br>
> > > > flow<br>
> > > > > > >> schema<br>
> > > > > > >> > > > doesn't seem to support that and can't find that filter<br>
> > to be<br>
> > > > > > >> > > > added<br>
> > > > > > >> to a<br>
> > > > > > >> > > > Gremlin query.<br>
> > > > > > >> > > ><br>
> > > > > > >> > > > Any ideas?<br>
> > > > > > >> > > ><br>
> > > > > > >> > > > Thanks,<br>
> > > > > > >> > > > Mak<br>
> > > > > > >> > > ><br>
> > > > > > >> > > > ______________________________<wbr>_________________<br>
> > > > > > >> > > > Skydive-dev mailing list<br>
> > > > > > >> > > > <a href="mailto:Skydive-dev@redhat.com">Skydive-dev@redhat.com</a><br>
> > > > > > >> > > > <a href="https://www.redhat.com/mailman/listinfo/skydive-dev" rel="noreferrer" target="_blank">https://www.redhat.com/<wbr>mailman/listinfo/skydive-dev</a><br>
> > > > > > >> > > ><br>
> > > > > > >> > > ><br>
> > > > > > >> > > ><br>
> > > > > > >> > > > ______________________________<wbr>_________________<br>
> > > > > > >> > > > Skydive-dev mailing list<br>
> > > > > > >> > > > <a href="mailto:Skydive-dev@redhat.com">Skydive-dev@redhat.com</a><br>
> > > > > > >> > > > <a href="https://www.redhat.com/mailman/listinfo/skydive-dev" rel="noreferrer" target="_blank">https://www.redhat.com/<wbr>mailman/listinfo/skydive-dev</a><br>
> > > > > > >> > > ><br>
> > > > > > >> > ><br>
> > > > > > >> ><br>
> > > > > > >><br>
> > > > > > ><br>
> > > > > > ><br>
> > > > > ><br>
> > > > ><br>
> > > > > ______________________________<wbr>_________________<br>
> > > > > Skydive-dev mailing list<br>
> > > > > <a href="mailto:Skydive-dev@redhat.com">Skydive-dev@redhat.com</a><br>
> > > > > <a href="https://www.redhat.com/mailman/listinfo/skydive-dev" rel="noreferrer" target="_blank">https://www.redhat.com/<wbr>mailman/listinfo/skydive-dev</a><br>
> > > > ><br>
> > > ><br>
> > ><br>
> ><br>
><br>
</div></div></blockquote></div><br></div>