Oh-oh! Unable to start site. error: 'Can't connect to MySQL server on '127.0.0.1' (10061)'

What issue or error are you experiencing?

After clicking [Add Site], an error message appears and building the WordPress environment fails.
I have checked the following by referring to the following topics.

  1. I have uninstalled the security software (Norton).
  2. I have checked “C:\Windows\System32\drivers\etc” and confirmed that the read-only setting for the “hosts” file is OFF.

What steps can be taken to replicate the issue? Feel free to include screenshots, videos, etc

  1. Click [Create a new site].
  2. Select [Create a new site] and click [Continue].
  3. Enter the site name in [Site name] and click [Continue].
  4. Click [Custom].
  5. Select [PHP version], [Web server], and [Database] as follows and click [Continue].
  • PHP version: 7.4.30
  • Web server: Apache 2.4.43
  • Database: MariaDB 10.4.10
  1. Set [WordPress username], [WordPress password], [WordPress e-mail] and click [Add Site].

  2. The error message “Oh-oh! Unable to start site.” will be displayed twice.


  3. The deletion process will start.

  4. The error message “Uh-oh! Could not update hosts file” will be displayed.
    image (4)


System Details

  • Local Version:
    Version 9.0.5+6706

  • Operating System (OS) and OS version:
    Windows 11 Business 22631.4169


Local Logs

Attach your Local Logs here (Help Doc - Retrieving Local’s Log)
local-logs.zip (32.0 KB)
local-lightning.log (92.7 KB)


Security Reminder
Local does a pretty good job of scrubbing private info from the logs and the errors it produces, however there’s always the possibility that something private can come through. Because these are public forums, always review the screenshots you are sharing to make sure there isn’t private info like passwords being displayed.

Hi @Kent-up

It looks like this error may be due to a special character in your Windows username.

Can you try creating and using a user directory without extended characters?

Thanks!

Hi, @Nick-B

Thank you for your reply.

It seems that the part with special characters is garbled text representing my username, which is written in Japanese (kanji). Since the PC where Local is installed is managed by my company, I cannot create a new user directory.

As a test, I tried installing it on my personal PC using the “Guest” user directory, and this error message did not appear, and it worked fine.

Would it be difficult to modify Local to support Japanese user directories?

I will also report this to my company’s system administrator and suggest creating the user directory in English.

Best regards,

Hi @Kent-up

We do have bugs filed to try and address this eventually but the problem is a bit more layered so we haven’t been able to give it priority over more urgent items. The easiest workaround for now will be to create a user without the special characters which hopefully your company’s IT will be able to help you with.

Hi, @Nick-B

Thank you for submitting the bug report!

I used Local to conduct a PHP version upgrade test. This test was completed on my personal PC, which does not have special characters in the username.

Therefore, the bug fix is not urgent, but it would be great if it could be resolved by the next PHP version upgrade.

Since similar issues may occur with other software when the username is in Japanese, I will report this to the IT department.

Best regards,

1 Like

Sounds good @Kent-up. We don’t have any ETA to provide on when the bug will be addressed but we will share the news here in the forums and our releases page when it is.

@Nick-B
Thank you! I look forward to the announcement of the fix!

1 Like