-
Notifications
You must be signed in to change notification settings - Fork 68
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
Error: P4Runtime RPC error (INTERNAL): 'bf_pal_device_add(dev_id, &device_profile)' failed with error message: Internal error. #400
Comments
It might be possible that some recent fixes to I have tried the latest version as of 2023-Sep-14 of Note: I chose to compile the latest version of |
Thank you for your reply! But I still got the same error after trying Does this mean that P4-DPDK soft switch is not compatible with three vhost-user ports? Or what changes should I make to the Thank you! |
By the way, here were the error details in
Any suggestions of how to solve this? Thank you very much. |
I have learned that there is a restriction that things do not work unless you create a number of ports that is a power of 2. So 3 will fail, but 4 should work again. |
@5abeel @ffoulkes Do either of you know if it is straightforward to change the code so that it could show a very clear error message when this occurs, preferably both to stdout/stderr, and in the infrap4d log? Perhaps a message that included a sentence like "Failing to start with 3 interfaces. P4-DPDK requires that the number of interfaces be a power of 2, e.g. use 4 interfaces instead of 3." Without such a clear message, it is a complete mystery why such failures occur right now. |
Wow! As you said, it worked! Thanks a lot. |
I have heard that the error occurs because there is some part of the P4-DPDK implementation that checks whether the number of ports is a power of 2, and if it is not, it returns with an error. It makes this check because it does not support non-power-of-2 number of ports, because of some part of the implementation where it needs to calculate some load balance roughly equally over each port, and wants to simplify the calculations involved to simple bit masking, rather than doing a modulo by a non-power-of-2 number. But this is hearsay -- I have not seen the lines of code involved. |
Since this is a limitation from DPDK, perhaps it makes more sense to add an error response from SDE layer? I can start an offline discussion with you and someone from SDE team to find the right spot for this improvement. |
We need to remove this limitation and take the small performance hit. I will put it on my to-do list. |
@satish153 to check into this issue |
I tried to locate the error message in the source code and failed. I don't know where it's coming from. Ideally, we should detect the error when the number of interfaces is defined. It's an invalid input. |
https://github.com/DPDK/dpdk/blob/main/lib/pipeline/rte_swx_pipeline.c#L342 |
Ouch. No wonder I didn't find it. |
I created 3 vhost-users and VMs, and I tried to add p4 pipeline binary package to the running IPDK container infrap4d switch. But it failed.
how I created three vhost-user-x ports in ipdk container
how I created three VMs in host
my p4 program was simple_l3.p4
any idea? thank you very much guys!
The text was updated successfully, but these errors were encountered: