When trying to use the SQL server linux command-line clients, mssql-cli in a continuous loop without connecting to the SQL server succesfully without any output and sqlcmd returned this error:

Sqlcmd: Error: Microsoft ODBC Driver 17 for SQL Server : TCP Provider: Error code 0x2746.
Sqlcmd: Error: Microsoft ODBC Driver 17 for SQL Server : Client unable to establish connection.

Network traces showed that the server returned a FYN packet on both cases:

14:09:49.913302 IP 10.98.13.2.55743 > 10.100.10.40.60725: Flags [S], seq 1942944609, win 64240, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
14:09:49.913731 IP 10.100.10.40.60725 > 10.98.13.2.55743: Flags [S.], seq 3664072506, ack 1942944610, win 8192, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
14:09:49.914092 IP 10.98.13.2.55743 > 10.100.10.40.60725: Flags [.], ack 1, win 1026, length 0
14:09:49.914501 IP 10.98.13.2.55743 > 10.100.10.40.60725: Flags [P.], seq 1:89, ack 1, win 1026, length 88
14:09:49.914813 IP 10.100.10.40.60725 > 10.98.13.2.55743: Flags [P.], seq 1:49, ack 89, win 513, length 48
14:09:49.926536 IP 10.98.13.2.55743 > 10.100.10.40.60725: Flags [P.], seq 89:397, ack 49, win 1026, length 308
14:09:49.927209 IP 10.100.10.40.60725 > 10.98.13.2.55743: Flags [F.], seq 49, ack 397, win 512, length 0
14:09:49.927379 IP 10.98.13.2.55743 > 10.100.10.40.60725: Flags [.], ack 50, win 1026, length 0
14:09:49.927610 IP 10.98.13.2.55743 > 10.100.10.40.60725: Flags [F.], seq 397, ack 50, win 1026, length 0
14:09:49.927868 IP 10.100.10.40.60725 > 10.98.13.2.55743: Flags [.], ack 398, win 512, length 0

After some research, i found a forum in someone suffered this problem commenting it was related to the configuration of openssl.

This was my configuration:

[default_conf]
ssl_conf = ssl_sect

[ssl_sect]
system_default = system_default_sect

[system_default_sect]
MinProtocol = TLSv1.2
CipherString = DEFAULT@SECLEVEL=2

After changing the CipherString...

CipherString = DEFAULT@SECLEVEL=0

... both clients started to work.