testpmd: support user-id attribute
Upon creation of a flow, testpmd assigns it a flow ID. Later, the flow ID is used for flow operations (query, destroy, dump).
The testpmd application allows to manage flow rules with its IDs. The flow ID is known only when the flow is created.
In order to prepare a complete sequence of testpmd commands to copy/paste, the flow IDs must be predictable.
The idea brought here is to allow providing some user-defined ID, chosen in advance of the effective flow creation.
Example:
testpmd> flow create 0 ingress user_id 0x1234 pattern eth / end actions count / drop / end
Flow rule #0 created, user-id 0x1234
testpmd> flow destroy 0 user_id rule 0x1234
Flow rule #0 destroyed, user-id 0x1234
Here, "user_id" is a flag that signifies the "rule" ID is the user-id.
The motivation is from OVS. OVS dumps its "rte_flow_create" calls to the log in testpmd commands syntax. As the flow ID testpmd would assign is unkwon, it cannot log valid "flow destroy" commands.
With the enhancement described above, valid testpmd commands can be created in a log to copy/paste to testpmd.
The application's flows sequence can then be played back in testpmd, to enable enhanced dpdk debug capabilities of the applications's flows in a controlled environment of testpmd rather than a dynamic, more difficult to debug environment of the application.
Signature · 1 line
2.26.2.1730.g385c171
+Cc ethdev and testpmd maintainers
Any feedback about this need and solution?
04/07/2022 10:24, Eli Britstein:
Quoted 32 lines
Upon creation of a flow, testpmd assigns it a flow ID. Later, the flow ID is used for flow operations (query, destroy, dump).
The testpmd application allows to manage flow rules with its IDs. The flow ID is known only when the flow is created.
In order to prepare a complete sequence of testpmd commands to copy/paste, the flow IDs must be predictable.The idea brought here is to allow providing some user-defined ID, chosen in advance of the effective flow creation.
Example:
testpmd> flow create 0 ingress
user_id0x1234pattern eth / end actions count / drop / end
Flow rule #0 created, user-id0x1234testpmd> flow destroy 0
user_idrule0x1234
Flow rule #0 destroyed, user-id0x1234
Here, "user_id" is a flag that signifies the "rule" ID is the user-id.The motivation is from OVS. OVS dumps its "
rte_flow_create" calls to the log in testpmd commands syntax. As the flow ID testpmd would assign is unkwon, it cannot log valid "flow destroy" commands.With the enhancement described above, valid testpmd commands can be created in a log to copy/paste to testpmd.
The application's flows sequence can then be played back in testpmd, to enable enhanced dpdk debug capabilities of the applications's flows in a controlled environment of testpmd rather than a dynamic, more difficult to debug environment of the application.
Hi Eli,
In RTE flow there is support for group_id attribute(u32). Similar to the example you gave-
testpmd> flow create 0 group 0x1234 ingress pattern eth / end actions count / drop / end
Please check if it fits the requirement.
Regards
Aman
Quoted 42 lines · Thomas Monjalon
+Cc ethdev and testpmd maintainers
Any feedback about this need and solution?
04/07/2022 10:24, Eli Britstein:
Quoted 32 lines
Upon creation of a flow, testpmd assigns it a flow ID. Later, the flow ID is used for flow operations (query, destroy, dump).
The testpmd application allows to manage flow rules with its IDs. The flow ID is known only when the flow is created.
In order to prepare a complete sequence of testpmd commands to copy/paste, the flow IDs must be predictable.The idea brought here is to allow providing some user-defined ID, chosen in advance of the effective flow creation.
Example:
testpmd> flow create 0 ingress
user_id0x1234pattern eth / end actions count / drop / end
Flow rule #0 created, user-id0x1234testpmd> flow destroy 0
user_idrule0x1234
Flow rule #0 destroyed, user-id0x1234
Here, "user_id" is a flag that signifies the "rule" ID is the user-id.The motivation is from OVS. OVS dumps its "
rte_flow_create" calls to the log in testpmd commands syntax. As the flow ID testpmd would assign is unkwon, it cannot log valid "flow destroy" commands.With the enhancement described above, valid testpmd commands can be created in a log to copy/paste to testpmd.
The application's flows sequence can then be played back in testpmd, to enable enhanced dpdk debug capabilities of the applications's flows in a controlled environment of testpmd rather than a dynamic, more difficult to debug environment of the application.
Hi Aman,
No, the group attribute has its own meaning, so it cannot be used for this purpose, unless I misunderstood your meaning.
Thanks,
Eli
Quoted 73 lines
-----Original Message-----
From: Singh, Aman Deep <[email protected]>
Sent: Thursday, July 28, 2022 5:07 PM
To: [email protected]; Eli Britstein <[email protected]>
Cc: Slava Ovsiienko <[email protected]>; Ori Kam <[email protected]>; Asaf Penso <[email protected]>; Matan Azrad <[email protected]>; Gaetan Rivet <[email protected]>; Nir Anteby <[email protected]>; Yuying Zhang <[email protected]>; Ferruh Yigit <[email protected]>; Andrew Rybchenko <[email protected]>; NBU-Contact- Thomas Monjalon (EXTERNAL) <[email protected]>
Subject: Re: [dpdk-dev] [RFC] testpmd: support user-id attributeExternal email: Use caution opening links or attachments
Hi Eli,
In RTE flow there is support for
group_idattribute(u32). Similar to the example you gave-testpmd> flow create 0 group
0x1234ingress pattern eth / end actions count / drop / endPlease check if it fits the requirement.
Regards
AmanQuoted 43 lines · Thomas Monjalon
+Cc ethdev and testpmd maintainers
Any feedback about this need and solution?
04/07/2022 10:24, Eli Britstein:
Quoted 33 lines
Upon creation of a flow, testpmd assigns it a flow ID. Later, the flow ID is used for flow operations (query, destroy, dump).
The testpmd application allows to manage flow rules with its IDs. The flow ID is known only when the flow is created.
In order to prepare a complete sequence of testpmd commands to copy/paste, the flow IDs must be predictable.The idea brought here is to allow providing some user-defined ID, chosen in advance of the effective flow creation.
Example:
testpmd> flow create 0 ingress
user_id0x1234pattern eth / end testpmd> actions
count / drop / end
Flow rule #0 created, user-id0x1234testpmd> flow destroy 0
user_idrule0x1234
Flow rule #0 destroyed, user-id0x1234Here, "user_id" is a flag that signifies the "rule" ID is the user-id.The motivation is from OVS. OVS dumps its "
rte_flow_create" calls to the log in testpmd commands syntax. As the flow ID testpmd would assign is unkwon, it cannot log valid "flow destroy" commands.With the enhancement described above, valid testpmd commands can be created in a log to copy/paste to testpmd.
The application's flows sequence can then be played back in testpmd, to enable enhanced dpdk debug capabilities of the applications's flows in a controlled environment of testpmd rather than a dynamic, more difficult to debug environment of the application.
Hello Aman,
Can you clarify your intention? Like Eli mentioned, the group_id is less relevant for that purpose. Even with the same group_id we wish to have several different flows with different user-id.
All,
Do you have any other comments?
We would like to proceed with the process of sending v1, review, and integrate.
Regards,
Asaf Penso
Quoted 94 lines
-----Original Message-----
From: Eli Britstein <[email protected]>
Sent: Sunday, 7 August 2022 10:01
To: Singh, Aman Deep <[email protected]>; [email protected]
Cc: Slava Ovsiienko <[email protected]>; Ori Kam <[email protected]>; Asaf Penso <[email protected]>; Matan Azrad <[email protected]>; Gaetan Rivet <[email protected]>; Nir Anteby <[email protected]>; Yuying Zhang <[email protected]>; Ferruh Yigit <[email protected]>; Andrew Rybchenko <[email protected]>; NBU-Contact- Thomas Monjalon (EXTERNAL) <[email protected]>
Subject: RE: [dpdk-dev] [RFC] testpmd: support user-id attributeHi Aman,
No, the group attribute has its own meaning, so it cannot be used for this purpose, unless I misunderstood your meaning.
Thanks,
EliQuoted 74 lines
-----Original Message-----
From: Singh, Aman Deep <[email protected]>
Sent: Thursday, July 28, 2022 5:07 PM
To: [email protected]; Eli Britstein <[email protected]>
Cc: Slava Ovsiienko <[email protected]>; Ori Kam <[email protected]>; Asaf Penso <[email protected]>; Matan Azrad <[email protected]>; Gaetan Rivet <[email protected]>; Nir Anteby <[email protected]>; Yuying Zhang <[email protected]>; Ferruh Yigit <[email protected]>; Andrew Rybchenko <[email protected]>; NBU-Contact- Thomas Monjalon (EXTERNAL) <[email protected]>
Subject: Re: [dpdk-dev] [RFC] testpmd: support user-id attributeExternal email: Use caution opening links or attachments
Hi Eli,
In RTE flow there is support for
group_idattribute(u32). Similar to the example you gave-testpmd> flow create 0 group
0x1234ingress pattern eth / end actions count / drop / endPlease check if it fits the requirement.
Regards
AmanQuoted 43 lines · Thomas Monjalon
+Cc ethdev and testpmd maintainers
Any feedback about this need and solution?
04/07/2022 10:24, Eli Britstein:
Quoted 33 lines
Upon creation of a flow, testpmd assigns it a flow ID. Later, the flow ID is used for flow operations (query, destroy, dump).
The testpmd application allows to manage flow rules with its IDs. The flow ID is known only when the flow is created.
In order to prepare a complete sequence of testpmd commands to copy/paste, the flow IDs must be predictable.The idea brought here is to allow providing some user-defined ID, chosen in advance of the effective flow creation.
Example:
testpmd> flow create 0 ingress
user_id0x1234pattern eth / end testpmd> actions
count / drop / end
Flow rule #0 created, user-id0x1234testpmd> flow destroy 0
user_idrule0x1234
Flow rule #0 destroyed, user-id0x1234Here, "user_id" is a flag that signifies the "rule" ID is the user-id.The motivation is from OVS. OVS dumps its "
rte_flow_create" calls to the log in testpmd commands syntax. As the flow ID testpmd would assign is unkwon, it cannot log valid "flow destroy" commands.With the enhancement described above, valid testpmd commands can be created in a log to copy/paste to testpmd.
The application's flows sequence can then be played back in testpmd, to enable enhanced dpdk debug capabilities of the applications's flows in a controlled environment of testpmd rather than a dynamic, more difficult to debug environment of the application.
This feature assigns custom IDs to flow rules
so a complete sequence of commands can prepared in a script. As a test application, I think it is really valuable to be able to script a sequence.
Any other opinions?
If you want to see this feature please speak to encourage its development.
30/01/2023 11:03, Asaf Penso:
Quoted 100 lines
Hello Aman,
Can you clarify your intention? Like Eli mentioned, thegroup_idis less relevant for that purpose. Even with the samegroup_idwe wish to have several different flows with different user-id.All,
Do you have any other comments?
We would like to proceed with the process of sending v1, review, and integrate.Regards,
Asaf PensoQuoted 90 lines
-----Original Message-----
From: Eli Britstein <[email protected]>
Sent: Sunday, 7 August 2022 10:01
To: Singh, Aman Deep <[email protected]>; [email protected]
Cc: Slava Ovsiienko <[email protected]>; Ori Kam <[email protected]>; Asaf Penso <[email protected]>; Matan Azrad <[email protected]>; Gaetan Rivet <[email protected]>; Nir Anteby <[email protected]>; Yuying Zhang <[email protected]>; Ferruh Yigit <[email protected]>; Andrew Rybchenko <[email protected]>; NBU-Contact- Thomas Monjalon (EXTERNAL) <[email protected]>
Subject: RE: [dpdk-dev] [RFC] testpmd: support user-id attributeHi Aman,
No, the group attribute has its own meaning, so it cannot be used for this purpose, unless I misunderstood your meaning.
Thanks,
EliQuoted 70 lines
-----Original Message-----
From: Singh, Aman Deep <[email protected]>
Sent: Thursday, July 28, 2022 5:07 PM
To: [email protected]; Eli Britstein <[email protected]>
Cc: Slava Ovsiienko <[email protected]>; Ori Kam <[email protected]>; Asaf Penso <[email protected]>; Matan Azrad <[email protected]>; Gaetan Rivet <[email protected]>; Nir Anteby <[email protected]>; Yuying Zhang <[email protected]>; Ferruh Yigit <[email protected]>; Andrew Rybchenko <[email protected]>; NBU-Contact- Thomas Monjalon (EXTERNAL) <[email protected]>
Subject: Re: [dpdk-dev] [RFC] testpmd: support user-id attributeExternal email: Use caution opening links or attachments
Hi Eli,
In RTE flow there is support for
group_idattribute(u32). Similar to the example you gave-testpmd> flow create 0 group
0x1234ingress pattern eth / end actions count / drop / endPlease check if it fits the requirement.
Regards
AmanQuoted 39 lines · Thomas Monjalon
+Cc ethdev and testpmd maintainers
Any feedback about this need and solution?
04/07/2022 10:24, Eli Britstein:
Quoted 33 lines
Upon creation of a flow, testpmd assigns it a flow ID. Later, the flow ID is used for flow operations (query, destroy, dump).
The testpmd application allows to manage flow rules with its IDs. The flow ID is known only when the flow is created.
In order to prepare a complete sequence of testpmd commands to copy/paste, the flow IDs must be predictable.The idea brought here is to allow providing some user-defined ID, chosen in advance of the effective flow creation.
Example:
testpmd> flow create 0 ingress
user_id0x1234pattern eth / end testpmd> actions
count / drop / end
Flow rule #0 created, user-id0x1234testpmd> flow destroy 0
user_idrule0x1234
Flow rule #0 destroyed, user-id0x1234Here, "user_id" is a flag that signifies the "rule" ID is the user-id.The motivation is from OVS. OVS dumps its "
rte_flow_create" calls to the log in testpmd commands syntax. As the flow ID testpmd would assign is unkwon, it cannot log valid "flow destroy" commands.With the enhancement described above, valid testpmd commands can be created in a log to copy/paste to testpmd.
The application's flows sequence can then be played back in testpmd, to enable enhanced dpdk debug capabilities of the applications's flows in a controlled environment of testpmd rather than a dynamic, more difficult to debug environment of the application.
As per RFC, I guess possible testpmd implementation will have a mapping between user-id(new) <=> rule-id (old/testpmd)
And this mapping will be maintained in testpmd code.
Please check, if that is how it is planned?
Another option I feel that this mapping done outside, by intermediate script OVS_log (with user id) => script => testpmd flow commands
Any other options/comments are welcome.
Thanks
Aman
Quoted 114 lines · Thomas Monjalon
This feature assigns custom IDs to flow rules
so a complete sequence of commands can prepared in a script. As a test application, I think it is really valuable to be able to script a sequence.Any other opinions?
If you want to see this feature please speak to encourage its development.30/01/2023 11:03, Asaf Penso:
Quoted 100 lines
Hello Aman,
Can you clarify your intention? Like Eli mentioned, thegroup_idis less relevant for that purpose. Even with the samegroup_idwe wish to have several different flows with different user-id.All,
Do you have any other comments?
We would like to proceed with the process of sending v1, review, and integrate.Regards,
Asaf PensoQuoted 90 lines
-----Original Message-----
From: Eli Britstein <[email protected]>
Sent: Sunday, 7 August 2022 10:01
To: Singh, Aman Deep <[email protected]>; [email protected]
Cc: Slava Ovsiienko <[email protected]>; Ori Kam <[email protected]>; Asaf Penso <[email protected]>; Matan Azrad <[email protected]>; Gaetan Rivet <[email protected]>; Nir Anteby <[email protected]>; Yuying Zhang <[email protected]>; Ferruh Yigit <[email protected]>; Andrew Rybchenko <[email protected]>; NBU-Contact- Thomas Monjalon (EXTERNAL) <[email protected]>
Subject: RE: [dpdk-dev] [RFC] testpmd: support user-id attributeHi Aman,
No, the group attribute has its own meaning, so it cannot be used for this purpose, unless I misunderstood your meaning.
Thanks,
EliQuoted 70 lines
-----Original Message-----
From: Singh, Aman Deep <[email protected]>
Sent: Thursday, July 28, 2022 5:07 PM
To: [email protected]; Eli Britstein <[email protected]>
Cc: Slava Ovsiienko <[email protected]>; Ori Kam <[email protected]>; Asaf Penso <[email protected]>; Matan Azrad <[email protected]>; Gaetan Rivet <[email protected]>; Nir Anteby <[email protected]>; Yuying Zhang <[email protected]>; Ferruh Yigit <[email protected]>; Andrew Rybchenko <[email protected]>; NBU-Contact- Thomas Monjalon (EXTERNAL) <[email protected]>
Subject: Re: [dpdk-dev] [RFC] testpmd: support user-id attributeExternal email: Use caution opening links or attachments
Hi Eli,
In RTE flow there is support for
group_idattribute(u32). Similar to the example you gave-testpmd> flow create 0 group
0x1234ingress pattern eth / end actions count / drop / endPlease check if it fits the requirement.
Regards
AmanQuoted 39 lines · Thomas Monjalon
+Cc ethdev and testpmd maintainers
Any feedback about this need and solution?
04/07/2022 10:24, Eli Britstein:
Quoted 33 lines
Upon creation of a flow, testpmd assigns it a flow ID. Later, the flow ID is used for flow operations (query, destroy, dump).
The testpmd application allows to manage flow rules with its IDs. The flow ID is known only when the flow is created.
In order to prepare a complete sequence of testpmd commands to copy/paste, the flow IDs must be predictable.The idea brought here is to allow providing some user-defined ID, chosen in advance of the effective flow creation.
Example:
testpmd> flow create 0 ingress
user_id0x1234pattern eth / end testpmd> actions
count / drop / end
Flow rule #0 created, user-id0x1234testpmd> flow destroy 0
user_idrule0x1234
Flow rule #0 destroyed, user-id0x1234Here, "user_id" is a flag that signifies the "rule" ID is the user-id.The motivation is from OVS. OVS dumps its "
rte_flow_create" calls to the log in testpmd commands syntax. As the flow ID testpmd would assign is unkwon, it cannot log valid "flow destroy" commands.With the enhancement described above, valid testpmd commands can be created in a log to copy/paste to testpmd.
The application's flows sequence can then be played back in testpmd, to enable enhanced dpdk debug capabilities of the applications's flows in a controlled environment of testpmd rather than a dynamic, more difficult to debug environment of the application.