I am trying to setup the ms-sql server in my linux by following the documentation https://learn.microsoft.com/pl-pl/sql/linux/quickstart-install-connect-ubuntu?view=sql-server-2017
The SQL server status is Active (Running).
I am getting the following error while executing the command
sqlcmd -S localhost -U SA -P '<YourPassword>'
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.
I also tried by giving the command
sqlcmd -S 127.0.0.1 -U SA -P '<YourPassword>'
But the same error is displayed. When I tried the wrong password it also displays the same error.