Getting error when starting up a site

What issue or error are you experiencing?

New issue just popped up when trying to fire up a site in my Local app.

Error: Command failed: /Users/me/Library/Application Support/Local/lightning-services/mysql-8.0.35+2/bin/darwin/bin/mysqladmin ping

mysqladmin: connect to server at ‘localhost’ failed

error: ‘Can’t connect to local MySQL server through socket ‘/Users/me/Library/Application Support/Local/run/bhGEgTNpG/mysql/mysqld.sock’ (2)’

Check that mysqld is running and that the socket: ‘/Users/me/Library/Application Support/Local/run/bhGEgTNpG/mysql/mysqld.sock’ exists!

at genericNodeError (node:internal/errors:983:15)

at wrappedFn (node:internal/errors:537:14)

at ChildProcess.exithandler (node:child_process:414:12)

at ChildProcess.emit (node:events:518:28)

at ChildProcess.emit (node:domain:489:12)

at maybeClose (node:internal/child_process:1101:16)

at Socket. (node:internal/child_process:456:11)

at Socket.emit (node:events:518:28)

at Socket.emit (node:domain:489:12)


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

Go to Local, click the wp-admin button for a site. See error.


System Details

  • Local Version:
    Version 9.2.4+6788
  • Operating System (OS) and OS version:
    mac sequoia 15.5

Local Logs

Attach your Local Logs here (Help Doc - Retrieving Local’s Log)
local-logs.zip (1.1 MB)


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 @bradhogan

If you create a new, blank site in Local can you access that okay? If you can, then you may want to try reimporting the site getting the errors. The steps would look like this:

  • Locate the site files on your machine, and save a copy of them to your desktop. If you click Go to Site Folder under your site name it should take you right to where they are located.
  • Once you have those copied, completely delete the site from Local
  • Restart Local/your machine
  • Reimport the site back into Local. You can refer here on how to Restore from only Local site files

@Nick-B Yes, I can. That seems like a temp fix though… what’s the underlying cause? Bug in LocalWP I assume?

Not so much a bug as there can be several underlying reasons why this might show up but we have been looking for ways to help cut down on errors of this type. If this is the only time you’ve seen it pop up, it might be because of something as simple as not Stopping the Site in Local before closing the app when you’ve finished up some work.

I’m seeing a lot of references in your logs that might indicate a port conflict or multiple instances of MySQL trying to run. If you’re seeing this type of thing all of the time then there might be a conflict at play with another application on your device, or something else amiss within the configuration. Are you running other developer applications simultaneously?

As far as the mysqld.sock’ (2)’ portion of the message, if you wanted to dig into this further you could follow Ben’s steps here: