in-ATP / ATP

MIT License
80 stars 26 forks source link

Fail to run ptf test #8

Closed VoidStardust closed 1 year ago

VoidStardust commented 1 year ago

Hello,

When I run $SDE/run_p4_tests.sh -t $ATP_REPO/ptf/ -p p4ml as describe in Enable Ports and Install Entries, I encountered the following error message:


root@localhost:~/Projects/git/ATP# $SDE/run_p4_tests.sh -t `pwd`/ptf -p p4ml
Using SDE /root/Software/bf-sde
Using SDE_INSTALL /root/Software/bf-sde/install
Using TEST_DIR /root/Projects/git/ATP/ptf
Using PATH /root/Software/bf-sde/install/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/lib/platform-config/current/onl/bin:/lib/platform-config/current/onl/sbin:/lib/platform-config/current/onl/lib/bin:/lib/platform-config/current/onl/lib/sbin:/root/Software/bf-sde/install/bin
Arch is tofino
Target is asic-model
Setting up veth interfaces
No of Veths is 64
Adding CPU veth
Connecting to localhost port 7777 to check status on these devices: [0]
Waiting for device 0 to be ready
Started port clean script
ptfTest.L2Test ... ERROR

======================================================================
ERROR: ptfTest.L2Test
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/root/Projects/git/ATP/ptf/ptfTest.py", line 57, in setUp
    if re.search("0x0234|0x1234|0x4234|0x5234", hex(board_type)):
NameError: global name 're' is not defined

----------------------------------------------------------------------
Ran 1 test in 0.006s

FAILED (errors=1)

******************************************
ATTENTION: SOME TESTS DID NOT PASS!!!

The following tests errored:
L2Test

******************************************

I am testing ATP using SDE-8.9.1 on a physical P4 switch, and I install the SDE with profile p4-14-programs-tofino. Looking forward to your reply.

Alex

laochonlam commented 1 year ago

Hi Alex,

Try import re in the script?

Thanks, Lam

VoidStardust commented 1 year ago

Thank you! That's a quick fix!

VoidStardust commented 1 year ago

Hello,

By the way, may I ask what version of verbs drivers do you use?

Thanks, Alex

laochonlam commented 1 year ago

Hi Alex,

We use MLNX_OFED 4.9-4.1.7.0 LTS. I hope that addresses your problem.

https://docs.nvidia.com/networking/display/MLNXOFEDv494170/General+Support+in+MLNX_OFED#GeneralSupportinMLNX_OFED-MLNX_OFEDSupportedOperatingSystems

Lam

VoidStardust commented 1 year ago

Hello,

Our servers are current using OFED-5.3-1.0.0. So it seems to be incompatible with your server and client implementation. Could you please provide some suggestions on how to modify the code to adapt to the newer driver version?

Thanks again, Alex

laochonlam commented 1 year ago

Hi Alex,

Unfortunately, we don't have the guidelines for other versions yet.

Thanks, Lam