SAP Knowledge Base Article - Public

3585535 - Error "WebSocket server session aborted" when validate S/4HANA On-Premise connection in SAP Datasphere

Symptom

Cloud Connector is selected for Data Provisioning Option under Remote Tables section of S/4HANA On-Premise connection to use the ABAP SQL service to federate data with remote tables.

When validate the S/4HANA On-Premise connection in Datasphere, you may receive one of the messages below.:

Remote Tables: Unable to connect remote source: [SAP][ODBCforABAP] (08001) Open backend connection: WebSocket Close frame : TH: WebSocket server session aborted, Code: 5921, SQL State: HY000

Or

Remote Tables: Unable to connect remote source: [SAP][ODBCforABAP] (08001) Open backend connection: WebSocket Close frame : TH: WebSocket server session aborted (Error code 6). Please check your configuration according to SAP Note 3076454 and ensure that the backend system is available. (adapter type: abapodbc, source name: <source name>, Code: 5921, SQL State: HY000 

"Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental." 

Environment

SAP Datasphere

Reproducing the Issue

  1. Select the checkbox in front of the connection to S/4HANA On-Premise.
  2. Click Validate button.

Cause

Cause 1:

The WebSocket connectivity and privileged mode for SQL is not enabled on the ABAP system.

Cause 2:

Source S/4HANA On-Premise version is lower than 2022.

Cause 3:

Incorrect protocol (for example HTTP) is used in SCC mapping

Resolution

Resolution for Cause 1:

Enabled the WebSocket connectivity and privileged mode for SQL on the ABAP system:

  1. Run transaction code RZ11.
  2. Input parameter wssql/active.
  3. Click "Display" button.
  4. Click "Change Value" button.
  5. Input 1 into New Value field.
  6. Select "Switch on all Servers".
  7. Click "Save change" button.
  8. Use the same steps above to change the value of another parameter wssql/privileged/active to 1.

Note that: the change is not permanent, and will be lost at server restart. Change it in profile file to make it permanent if necessary.

Resolution for Cause 2:

Make sure the SAP S/4HANA system you want to connect meets the version requirements:

  • For data federation using the SQL service, ABAP platform 2022 FPS00 or higher is required.

See Using ABAP SQL Services for Accessing Data from SAP S/4HANA | SAP Help Portal.

Resolution for Cause 3:

In SCC, when adding the system mapping to the SAP S/4HANA system, select HTTPS protocol, according to Using ABAP SQL Services for Accessing Data from SAP S/4HANA | SAP Help Portal.

See Also

Keywords

Remote Table, Connection, Datasphere, Cloud Connector , KBA , DS-DI-CON , Connections , BC-DB-DBI , DB Independent Database Interface , Problem

Product

SAP Datasphere all versions