microsoft / azuredatastudio

Azure Data Studio is a data management and development tool with connectivity to popular cloud and on-premises databases. Azure Data Studio supports Windows, macOS, and Linux, with immediate capability to connect to Azure SQL and SQL Server. Browse the extension library for more database support options including MySQL, PostgreSQL, and MongoDB.
https://learn.microsoft.com/sql/azure-data-studio
MIT License
7.5k stars 882 forks source link

Notebook Deployment Feature does not terminate CMD.EXE,MSSQLCTL.EXE,PYTHON.EXE post Deployment/ADS Closure. #4799

Closed pradm closed 5 years ago

pradm commented 5 years ago

Issue Type: Bug

Version: 1.5.2 (user setup) Commit: f74080c96310354bc92211f1826c0fdce78ca2f6 Date: 2019-03-22T06:25:26.627Z VS Code 1.30.1 Electron: 2.0.12 Chrome: 61.0.3163.100 Node.js: 8.9.3 V8: 6.1.534.41 OS: Windows_NT x64 10.0.14393

I am noticing that ADS post application closure doesn’t terminate the respective child applications which it had launched for Notebook cluster deployment feature. Ideally once the execution is complete the process should terminate itself and should not be resident in memory. It looks like due to some reason the process never got terminated.

  1. On 28th March I was using ADS Notebook Deployment feature to deploy an Aris Cluster.
  2. It looks like ADS initiates a CMD.EXE and posts a MSSQLCTL.exe command for cluster deployments and administration.
  3. Today Morning I had closed the ADS application, but it looks like the child CMD.EXE -> MSSQLCTL.EXE -> PYTHON.EXE never gets terminated.
  4. The Python.exe is holding a lock on C:\Users\pradm.mssqlctl\logs\mssqlctl.log & against the MSSQLCTL.LOG which it had generated
  5. Why I am so sure that the CMD.EXE could be launched by ADS -> The command line for CMD.EXE launch is the complete Cluster Creation command that by default doesn’t happen some application has called CMD.EXE with these input parameters.

Is this a Known issue which is getting fixed in future ADS builds. Attaching the ADS logs for your further review.

C:\Users\pradm\AppData\Roaming\azuredatastudio\logs\20190330T024928 C:\Users\pradm\AppData\Roaming\azuredatastudio\logs\20190330T024928\exthost1\ C:\Users\pradm\AppData\Roaming\azuredatastudio\logs\20190330T024928\exthost1\output_logging_20190330T024932

• main.log does not show any indications of application closure exceptions • sharedprocess.log does not show any indications of application closure exceptions • exthost.log does not show any indications of application closure exceptions • 3-Jupyter Notebooks.log does not show any indications of application closure exceptions

adsbdc1 adsbdc2 png

20190330T024928.zip

Azure Data Studio version: azuredatastudio 1.5.2 (f74080c96310354bc92211f1826c0fdce78ca2f6, 2019-03-22T06:25:26.627Z) OS version: Windows_NT x64 10.0.14393

System Info |Item|Value| |---|---| |CPUs|Intel(R) Xeon(R) CPU E5-2620 v3 @ 2.40GHz (12 x 2394)| |GPU Status|2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: disabled_software
rasterization: enabled
video_decode: enabled
video_encode: enabled
webgl: enabled
webgl2: enabled| |Memory (System)|31.92GB (4.91GB free)| |Process Argv|| |Screen Reader|no| |VM|0%|
Extensions (6) Extension|Author (truncated)|Version ---|---|--- agent|Mic|0.37.0 import|Mic|0.7.0 profiler|Mic|0.7.0 server-report|Mic|0.1.5 sql-dw|Mic|0.0.1 sql-vnext|Mic|0.11.0
chlafreniere commented 5 years ago

This is a dupe of #3477.