Navigation Menu

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

connect to DB: Database ping failed: commands out of sync #246

Closed
misaka00251 opened this issue Jan 18, 2020 · 2 comments
Closed

connect to DB: Database ping failed: commands out of sync #246

misaka00251 opened this issue Jan 18, 2020 · 2 comments

Comments

@misaka00251
Copy link

misaka00251 commented Jan 18, 2020

Describe the bug

I want to move the instance to another machine, but it outputs this error after I setup.

2020/01/18 11:49:48 Starting WriteFreely 0.11.2...
2020/01/18 11:49:48 Loading config.ini configuration...
2020/01/18 11:49:48 Loading templates...
2020/01/18 11:49:48 Loading pages...
2020/01/18 11:49:48 Loading user pages...
2020/01/18 11:49:48 Loading encryption keys...
2020/01/18 11:49:48 Connecting to mysql database...
ERROR: 2020/01/18 11:49:48 main.go:119: connect to DB: Database ping failed: commands out of sync. Did you run multiple statements at once?

Well, MySQL is running, and I can log in and see the writefreely database.

Steps to reproduce (if necessary)

Steps to reproduce the behavior:

  1. Zip the instance, then unzip it on another machine
  2. Export then import MySQL data.
  3. run ./writefreely

Expected behavior

It works!

Application configuration

  • Single mode
  • Database? mysql
  • Open registration? no
  • Federation enabled? no

Version or last commit:

0.11.2

@misaka00251
Copy link
Author

misaka00251 commented Jan 19, 2020

Related to this.

How can we use the sock method?

Edit: I'm on Debian 10, and still on 10.3.18-MariaDB.

@misaka00251
Copy link
Author

Ok, if anyone has the same problem, and don't need access the database from other machines:

Remove skip-name-resolve from your my.cnf.

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

No branches or pull requests

1 participant