sonic-net / sonic-mgmt

Configuration management examples for SONiC
Other
194 stars 712 forks source link

Snappi: ServerError: SnappiIxnException #13482

Closed rraghav-cisco closed 2 months ago

rraghav-cisco commented 3 months ago

Issue Description

When running snappi_tests, a lot of them gave this error, I need help understanding what is causing this:

            self.config_ixnetwork(config)
        except Exception as err:
>           raise SnappiIxnException(err)
E           snappi_ixnetwork.exceptions.SnappiIxnException:   File "/usr/local/lib/python3.8/dist-packages/snappi_ixnetwork/snappi_api.py", line 214, in set_config
E               self.config_ixnetwork(config)
E             File "/usr/local/lib/python3.8/dist-packages/snappi_ixnetwork/snappi_api.py", line 249, in config_ixnetwork
E               self._connect()
E             File "/usr/local/lib/python3.8/dist-packages/snappi_ixnetwork/snappi_api.py", line 639, in _connect
E               self._assistant = SessionAssistant(
E             File "/usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/assistants/sessions/sessionassistant.py", line 85, in __init__
E               session = testplatform.Sessions.add(ApplicationType, Name=SessionName)
E             File "/usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/testplatform/sessions/sessions.py", line 236, in add
E               self._create(locals())
E             File "/usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/base.py", line 255, in _create
E               properties = self._connection._create(url, payload)
E             File "/usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/connection.py", line 202, in _create
E               return self._send_recv('POST', url, payload)
E             File "/usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/connection.py", line 444, in _send_recv
E               self._process_response_status_code(url, headers, response)
E             File "/usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/connection.py", line 358, in _process_response_status_code
E               raise ServerError(message, response.status_code)

config     = <snappi.snappi.Config object at 0x7f2bfd19a600>
self       = <snappi_ixnetwork.snappi_api.Api object at 0x7f2bffb276a0>

/usr/local/lib/python3.8/dist-packages/snappi_ixnetwork/snappi_api.py:216: SnappiIxnException

Attached the xml file from the script run. @selldinesh , @isgmano : Pls advice.

Results you see

Seeing tracebacks in many scripts.

Results you expected to see

Need to understand this.

Is it platform specific

generic

Relevant log output

No response

Output of show version

No response

Attach files (if any)

rraghav-cisco commented 3 months ago

Further info: For raise ServerError(message, response.status_code) I did a breakpoint and printed the values, got message = "" and response.status_code = 503.

rraghav-cisco commented 2 months ago

@selldinesh: Pls check. @abdosi : for viz.

yxieca commented 2 months ago

@selldinesh can you help triage?

yxieca commented 2 months ago

@rraghav-cisco are you able to rule out network reachability issue between the mgmt docker and the ixia API controller?

rraghav-cisco commented 2 months ago

@yxieca , @selldinesh : After rebooting the ixia server, this problem is gone. Thanks for the help.

@rraghav-cisco are you able to rule out network reachability issue between the mgmt docker and the ixia API controller?

@yxieca :Yes, I had ruled out the connectivity.