Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to start MySQL tools service #225

Open
hjrb opened this issue Sep 22, 2023 · 11 comments
Open

Failed to start MySQL tools service #225

hjrb opened this issue Sep 22, 2023 · 11 comments

Comments

@hjrb
Copy link

hjrb commented Sep 22, 2023

Steps to Reproduce:

  1. Start Azure Data Studio
    Version: 1.44.1 (system setup)
    Commit: 8f53a316fa00a98264f1ab119641cd540b5af25c
    Date: 2023-06-01T02:12:48.765Z
    VS Code: 1.70.0
    Electron: 19.1.8
    Chromium: 102.0.5005.167
    Node.js: 16.14.2
    V8: 10.2.154.15-electron.0
    OS: Windows_NT x64 10.0.19045
    with version v1.0.0 of the MySQL extension
    2.) Error message occurs
@hjrb
Copy link
Author

hjrb commented Sep 22, 2023

Note: i'm behind a corperate proxy with authentication. I have not set the environment variables http_proxy or https_proxy

@rishky-msft
Copy link
Contributor

rishky-msft commented Sep 22, 2023 via email

@hjrb
Copy link
Author

hjrb commented Sep 22, 2023

Version: 1.46.0 (system setup)
Commit: 39449bbe88a0bc4092c9b205cad10d0a556beffd
Date: 2023-09-16T01:40:10.706Z
VS Code: 1.79.2
Electron: 22.3.14
Chromium: 108.0.5359.215
Node.js: 16.17.1
V8: 10.8.168.25-electron.0
OS: Windows_NT x64 10.0.19045

Same error messages.

@hjrb
Copy link
Author

hjrb commented Sep 22, 2023

also occur when running as Administrator

@rishky-msft
Copy link
Contributor

Can you share the screenshot of exact error message?

@rishky-msft
Copy link
Contributor

rishky-msft commented Sep 22, 2023

Also please check if the path exists: (Replace the your-user-name)

C:\Users<your-user-name>.azuredatastudio\extensions\microsoft.azuredatastudio-mysql-1.0.0\out\bin\Windows\v0.1.2\mysqltoolsservice

The content of the path should look like below:

image

@hjrb
Copy link
Author

hjrb commented Sep 22, 2023

No it does not exist
Screenshot 2023-09-22 140012

@hjrb
Copy link
Author

hjrb commented Sep 22, 2023

Tree /A output of folder C:\Users\xxxxx.azuredatastudio\extensions\microsoft.azuredatastudio-mysql-1.0.0

Folder PATH listing for volume Windows
Volume serial number is 4E30-5906
C:.
+---.pipelines
+---documentation
+---i18n
| +---chs
| | ---out
| +---cht
| | ---out
| +---deu
| | ---out
| +---esn
| | ---out
| +---fra
| | ---out
| +---ita
| | ---out
| +---jpn
| | ---out
| +---kor
| | ---out
| +---ptb
| | ---out
| ---rus
| ---out
+---images
| +---dark
| ---light
+---node_modules
| +---@microsoft
| | +---ads-extension-telemetry
| | | ---lib
| | ---ads-service-downloader
| | +---node_modules
| | | ---tmp
| | | ---lib
| | ---out
| +---@TooTallNate
| | ---once
| | ---dist
| +---@VScode
| | ---extension-telemetry
| | ---lib
| +---agent-base
| | ---dist
| | ---src
| +---async-retry
| | ---lib
| +---balanced-match
| | ---.github
| +---brace-expansion
| +---buffer-crc32
| +---chownr
| +---concat-map
| | +---example
| | ---test
| +---dataprotocol-client
| | +---.github
| | | ---workflows
| | +---lib
| | ---src
| +---debug
| | ---src
| +---eventemitter2
| | ---lib
| +---fd-slicer
| | ---test
| +---fs-minipass
| +---fs.realpath
| +---glob
| +---http-proxy-agent
| | ---dist
| +---https-proxy-agent
| | ---dist
| +---inflight
| +---inherits
| +---minimatch
| +---minipass
| +---minizlib
| +---mkdirp
| | +---bin
| | ---lib
| +---ms
| +---once
| +---os-tmpdir
| +---path-is-absolute
| +---pend
| +---retry
| | +---example
| | ---lib
| +---rimraf
| +---semver
| +---tar
| | +---lib
| | ---node_modules
| | ---minipass
| +---tmp
| | ---lib
| +---vscode-jsonrpc
| | ---lib
| +---vscode-languageclient
| | ---lib
| | ---utils
| +---vscode-languageserver-protocol
| | ---lib
| | ---utils
| +---vscode-languageserver-types
| | ---lib
| | +---esm
| | ---umd
| +---vscode-nls
| | ---lib
| | +---browser
| | +---common
| | ---node
| | ---test
| +---wrappy
| +---yallist
| ---yauzl
+---out
| +---bin
| | ---Windows
| | ---v0.1.2
| +---contracts
| +---dialogs
| +---features
| +---models
| ---utils
+---snippets
---syntaxes

@hjrb
Copy link
Author

hjrb commented Sep 22, 2023

We also have MS AppLocker running. Maybe that is blocking something.

@johnbdenton
Copy link

Any updates on this?
I have been seeing this same issue (as submitter @hjrb) on my system for a while now after an update to ADS at some point this broke (was working in preview). I've tried completely wiping and reinstalling ADS & MySQL extension (even locating where they are installed and deleting directories and cache, etc.) and that still hasn't solved the problem. One thing this post mentioned I didn't know to check was the extension bin directory - it doesn't exist. I have:

C:\Users\<user_name>\.azuredatastudio\extensions\microsoft.azuredatastudio-mysql-1.0.0\out\bin\Windows\v0.1.2\

But nothing else in that last version folder. Seems it did not build the extension, which makes sense why it's "failing to start MySQL tools service".
I tried adding http_proxy and https_proxy to my environment variables (because corporate firewall here as well). Usually that fixes download issues (like nuget), but that didn't seem to help here either.

@johnbdenton
Copy link

johnbdenton commented Feb 29, 2024

I have found the issue. I took my laptop home with me, logged off the VPN and network and reinstalled the extension to discover this:
Downloading https://github.com/microsoft/mysqltoolsservice/releases/download/v0.1.2/mysqltoolsservice-win-x64.zip (34,117 KB)....................Done!
Installing MySQL Tools Service to c:\Users\<user_name>\.azuredatastudio\extensions\microsoft.azuredatastudio-mysql-1.0.0\out\bin\Windows\v0.1.2
Installed MySQL Tools Service
This is the reason it is failing to install while on a corporate network: they block downloading zip files from the internet. This is downloading without permission and without validation to extract and install another application. This is highly suspect for an installer to go out to the internet, download a zip file, then extract it and run installer in that. This is how viruses are spread. This package cannot be checked for correct sha hash, virus programs, etc... Any corporation is going to block this for security reasons.

The suggested fix for this is: the code is already downloading all of the source code material into the extension directory - just fire off a script command to build/compile the code fresh and new into the out folder. No point in downloading a separate installer for bin libraries.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants