Bug #106843 Can't create any connection to MySQL servers
Submitted: 26 Mar 2022 3:31 Modified: 27 May 2022 18:39
Reporter: Tsutomu Kawamura Email Updates:
Status: Closed Impact on me:
None 
Category:Shell VSCode Extension Severity:S1 (Critical)
Version:1.1.2, 1.1.8, 1.7.0, 1.8.0 OS:Windows (Ubuntu / WSL2 / Windows 11)
Assigned to: CPU Architecture:Any (AMD Ryzen 5 4500U)

[26 Mar 2022 3:31] Tsutomu Kawamura
Description:
I got an error in Welcome Wizard:

ERROR: core.installShellWebCertificate: User-defined function threw an exception: Traceback (most recent call last): File "/home/cognitom/.vscode-server/extensions/oracle.mysql-shell-for-vs-code-1.1.2/shell/lib/mysqlsh/plugins/gui_plugin/core/Certificates.py", line 159, in install_shell_web_certificate raise SystemError("UNABLE to find terminal!") SystemError: UNABLE to find terminal!

Also, I run install.sh manually, and it said "Certificate has been installed successfully!", then I restarted VS Code. But still I couldn't make any connection. Just black screen...

See also:
https://github.com/mysql/mysql-shell-plugins/issues/1

How to repeat:
Environments:
- Windows 11
- WSL2 installed
- Ubuntu (from Microsoft Store) installed
- VS Code installed
- default shell (bash)

1. install MySQL Shell extension into VS Code
2. follow instructions in Welcome Wizard
3. get the error above
4. run `.mysqlsh-gui/plugin_data/gui_plugin/web_certs/install.sh` through Terminal (Ubuntu)
5. get the message: "Certificate has been installed successfully!"
6. restart VS Code
7. open "MySQL Shell for VSCode" tab
8. click "+" icon on DATABASE section
9. get a blank page
[29 Mar 2022 6:59] MySQL Verification Team
Hello Tsutomu Kawamura,

Thank you for the bug report and feedback.

Regards,
Ashwini Patil
[29 Mar 2022 11:58] MySQL Verification Team
Bug #106846 marked as duplicate of this one.
[31 Mar 2022 18:14] Juan Rene Ramirez Monarrez
Posted by developer:
 
Hi Ashwini

Thanks for submitting this report, after some investigation there's some feedback:

Long story short: the missing piece to make the puzzle complete in WSL2 is to get the certificate also installed in Windows.

Manual Procedure:

- Copy ~/.mysqlsh-gui/plugin_data/gui_plugin/web_certs/rootCA.crt into a location visible in the Windows explorer
- Then right click -> Install Certificate
- Select "Current User" and Next
- Select "Place all certificates in the following store" and browse to "Trusted Root Certification Authorities"
- Restart VSCode and try the extension.

We will work on making this as automated as possible.
[31 Mar 2022 18:15] Juan Rene Ramirez Monarrez
Posted by developer:
 
Hi Ashwini

Thanks for submitting this report, after some investigation there's some feedback:

Long story short: the missing piece to make the puzzle complete in WSL2 is to get the certificate also installed in Windows.

Manual Procedure:

- Copy ~/.mysqlsh-gui/plugin_data/gui_plugin/web_certs/rootCA.crt into a location visible in the Windows explorer
- Then right click -> Install Certificate
- Select "Current User" and Next
- Select "Place all certificates in the following store" and browse to "Trusted Root Certification Authorities"
- Restart VSCode and try the extension.

We will work on making this as automated as possible.
[31 Mar 2022 18:15] Juan Rene Ramirez Monarrez
Posted by developer:
 
Hi Ashwini

Thanks for submitting this report, after some investigation there's some feedback:

Long story short: the missing piece to make the puzzle complete in WSL2 is to get the certificate also installed in Windows.

Manual Procedure:

- Copy ~/.mysqlsh-gui/plugin_data/gui_plugin/web_certs/rootCA.crt into a location visible in the Windows explorer
- Then right click -> Install Certificate
- Select "Current User" and Next
- Select "Place all certificates in the following store" and browse to "Trusted Root Certification Authorities"
- Restart VSCode and try the extension.

We will work on making this as automated as possible.
[19 Apr 2022 13:56] MySQL Verification Team
Bug #107031 marked as duplicate of this one.
[20 Apr 2022 12:32] MySQL Verification Team
Bug #107060 marked as duplicate of this one.
[10 May 2022 12:43] MySQL Verification Team
Bug #107253 marked as duplicate of this one.
[27 May 2022 18:39] Christine Cole
Posted by developer:
 
This issue was fixed in version 1.1.5. No changelog entry added.

Thank you for the bug report.
[1 Feb 2023 12:42] MySQL Verification Team
Bug #109856 marked as duplicate of this one
[27 Feb 2023 12:37] MySQL Verification Team
Bug #110199 marked as duplicate of this one