Help Center/ Database and Application Migration UGO/ FAQs/ Database Connections/ SQL Server Connection Test Failed (Error Code=0, SQLState=08S01)
Updated on 2025-02-22 GMT+08:00

SQL Server Connection Test Failed (Error Code=0, SQLState=08S01)

Symptom

When the source database type was Microsoft SQL Server and SSL was disabled, the connection test failed and message "ErrorCode=0, SQLState=08S01" was displayed. In addition, error message " Caused by: The server selected protocol version TLS10 is not accepted by client preferences [TLS13, TLS12]" was displayed in the log.

Causes

Even if SSL is disabled, a certificate can be generated over an underlying protocol of SQL Server to encrypt a login data packet. TLS 1.0 may be used in earlier versions but is disabled by default for security purposes in the current JRE.

Solution

Modifying JVM Configurations

  1. Log in to a UGO server as the root user.
  2. Confirm the JRE path (JAVA_HOME).
  3. Modify the <JAVA_HOME>/lib/security/java.security file.

    vi <JAVA_HOME>/lib/security/java.security

  4. Delete TLS v1 from the jdk.tls.disabledAlgorithms configuration item and save the modification.

    Figure 1 Deleting TLS v1

  5. Restart UGO (<UGO_HOME> indicates the UGO installation directory).

    python3 <UGO_HOME>/bin/ugoserver.py restart