Open helvete opened 3 years ago
I have run into the same problem after upgrading from Ubuntu 18.04 to 20.04. I have the same behavior of high CPU and a "hung" state.
I too can connect to this remote database using dbeaver-ce client with no issue. So there is no other connectivity issue happening. Even if I don't put in any credentials, just to expect to see a message saying so, it still just hangs.
I have tried uninstalling and re-installing mssql-cli via pip. I even tried to install it on another ubuntu 20.04 machine, where this was not previously installed, and I got the same behavior.
When I ctrl+C out of the hung state it shows similar to @helvete
File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "~/.local/lib/python3.8/site-packages/mssqlcli/main.py", line 122, in <module>
main()
File "~/.local/lib/python3.8/site-packages/mssqlcli/main.py", line 115, in main
run_cli_with(mssqlcli_options)
File "~/.local/lib/python3.8/site-packages/mssqlcli/main.py", line 52, in run_cli_with
mssqlcli.connect_to_database()
File "~/.local/lib/python3.8/site-packages/mssqlcli/mssql_cli.py", line 278, in connect_to_database
owner_uri, error_messages = self.mssqlcliclient_main.connect_to_database()
File "~/.local/lib/python3.8/site-packages/mssqlcli/mssqlcliclient.py", line 91, in connect_to_database
owner_uri, error_messages = self._execute_connection_request_with(connection_params)
File "~/.local/lib/python3.8/site-packages/mssqlcli/mssqlcliclient.py", line 188, in _execute_connection_request_with
time.sleep(time_wait_if_no_response)
KeyboardInterrupt
^C
Since I reinstalled my system to Debian 10 I can no longer connect to a remote
mssql
server.When I try to connect to a remote server the process never ends (and utilizes 100% of one CPU thread). It produces following trace if killed by
^C
:It seems infinite loop is in progress here.
I tried mutliple versions of both
python3
andpython 2.7
, all with the same result. Current versions:1.0.0
10.9
(but the same occurred for10.8
and10.7
as well)3.7.3
or2.7.16
(again, the same occurred on all previously installed versions as well)Microsoft SQL Server 2014 (SP2-GDR) (KB4019093) - 12.0.5207.0 (X64)
I tried to install
mssql-cli
on the remote server and then I can connect normally. The same applies for local connections - these work OK as well.The only specific I know of is that the remote server is only accessible via
PPTP
VPN. But this posed no problem before I reinstalled my system (it was Ubuntu 18.04).Similarly I can connect to the remote database using all other means. For example, this simple script connects there OK as well:
(This hints that neither the VPN nor particular OS or python versions are the cause of the problem IMHO)
I have searched the issues here (and using search engines) thoroughly but at no avail.
Please let me know if more debugging data have to be provided.
It is no april's fools joke :smiley: