Glad to hear you figured it out.
On Fri, Jun 19, 2020 at 11:11:03AM +0000, Luca Mancini wrote: > Hi Ben, > So by some stroke of genius (luck) I figured out a way to send the extracted > packets back to the flow table, where I added in flows that simply check the > destination IP and outputs them to the correct port without having to rely on > the internal routing table using “normal”. > So basically when a switch receives the buffered packets on a switch I > extract the single pkts, use them to modify the flow through the flow_extract > method and then use the method ofproto_dpif_execute_actions__() to resubmit > the single extracted packets with the modified flow, to the flow table. > > Hopefully this makes a little sense, but when I’ll be done with this whole > project I’ll make a blog and explain it all more thoroughly. > Thanks for the help! > Luca > > From: Luca Mancini<mailto:luca.manc...@outlook.com> > Sent: Thursday, June 18, 2020 00:39 > To: ovs-discuss@openvswitch.org<mailto:ovs-discuss@openvswitch.org> > Subject: Re: [ovs-discuss] Storing xlate_ctx CTX > > Me too haha, I won’t lose hope though and I can’t really. > Thanks for the suggestions, I’ll keep working on it and update if I manage to > come up with something > > From: Ben Pfaff<mailto:b...@ovn.org> > Sent: Thursday, June 18, 2020 00:29 > To: Luca Mancini<mailto:luca.manc...@outlook.com> > Cc: ovs-discuss@openvswitch.org<mailto:ovs-discuss@openvswitch.org> > Subject: Re: [ovs-discuss] Storing xlate_ctx CTX > > I don't know. I find your use case baffling. > > On Wed, Jun 17, 2020 at 10:15:00PM +0000, Luca Mancini wrote: > > So if I understand this correctly, in this case on another switch where I > > receive the bufferred packet I’ll have it’s actions in ctx set to "normal”, > > but won’t I still have the problem of sending the packets stored inside the > > buffered packet (once extracted) to “normal”? > > > > > > From: Ben Pfaff<mailto:b...@ovn.org> > > Sent: Wednesday, June 17, 2020 23:54 > > To: Luca Mancini<mailto:luca.manc...@outlook.com> > > Cc: ovs-discuss@openvswitch.org<mailto:ovs-discuss@openvswitch.org> > > Subject: Re: [ovs-discuss] Storing xlate_ctx CTX > > > > When you need to send the buffered packet, translate it first with > > xlate_actions(), passing "normal" as the set of actions. > > > > On Wed, Jun 17, 2020 at 09:41:19PM +0000, Luca Mancini wrote: > > > Sorry, what do you mean exactly by “translate the packets using the > > > xlate_ctx struct”? Do you mean passing "normal” to the set of actions > > > before buffering the packet? > > > > > > > > > From: Ben Pfaff<mailto:b...@ovn.org> > > > Sent: Wednesday, June 17, 2020 23:17 > > > To: Luca Mancini<mailto:luca.manc...@outlook.com> > > > Cc: ovs-discuss@openvswitch.org<mailto:ovs-discuss@openvswitch.org> > > > Subject: Re: [ovs-discuss] Storing xlate_ctx CTX > > > > > > Why not just translate the packets using an xlate_ctx and passing > > > "normal" as the set of actions? > > > > > > On Wed, Jun 17, 2020 at 08:57:07PM +0000, Luca Mancini wrote: > > > > It’s quite the pickle then. > > > > Basically it’s a new action I’m trying to implement for OVS , I’ve > > > > talked about it before here: > > > > https://mail.openvswitch.org/pipermail/ovs-discuss/2020-June/050196.html > > > > I need a way to send the single packets to the appropriate ports, I was > > > > using ofproto_dpif_send_packet since I can store dp_packet pointers, > > > > however it doesn’t seem to work on non-physical ports (OFPP_NORMAL > > > > etc.) , and the only function I found that does is obviously the output > > > > function, so I’m attempting to hack my way through it to use it in my > > > > favor given that I can’t store the original ctx pointer. > > > > The only temporary solution I have in place is iterating through the > > > > switch’s available ports and flooding the single packets, but this is > > > > very ugly let alone inefficient in bigger topologies. > > > > > > > > > > > > From: Ben Pfaff<mailto:b...@ovn.org> > > > > Sent: Wednesday, June 17, 2020 22:45 > > > > To: Luca Mancini<mailto:luca.manc...@outlook.com> > > > > Cc: ovs-discuss@openvswitch.org<mailto:ovs-discuss@openvswitch.org> > > > > Subject: Re: [ovs-discuss] Storing xlate_ctx CTX > > > > > > > > This is probably not a good solution to your problem. I don't > > > > understand your overall problem, so I can't suggest a good solution. > > > > > > > > On Wed, Jun 17, 2020 at 08:08:40PM +0000, Luca Mancini wrote: > > > > > I thought so, what about hard coding a ctx struct, i need this > > > > > particular struct since I'd like to send the single packets received > > > > > by a switch (after storing them) to the NORMAL logical port, or even > > > > > just resubmit them to the flow tables so they can match another flow, > > > > > and all the functions that do these things necess struct xlate_ctx. > > > > > > > > > > Thanks! > > > > > > > > > > > > > > > From: Ben Pfaff<mailto:b...@ovn.org> > > > > > Sent: Wednesday, June 17, 2020 21:50 > > > > > To: Luca Mancini<mailto:luca.manc...@outlook.com> > > > > > Cc: ovs-discuss@openvswitch.org<mailto:ovs-discuss@openvswitch.org> > > > > > Subject: Re: [ovs-discuss] Storing xlate_ctx CTX > > > > > > > > > > On Wed, Jun 17, 2020 at 03:13:27PM +0000, Luca Mancini wrote: > > > > > > Are there ways in OVS store a struct xlate_ctx *ctx so that I can > > > > > > use > > > > > > it even after another packet is received by the switch? > > > > > > > > > > No. > > > > > > > > > > > > > > > > _______________________________________________ discuss mailing list disc...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-discuss