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

Can't find MySQL database on rpi? #1705

Open
FailurePoint opened this issue Sep 9, 2023 · 3 comments
Open

Can't find MySQL database on rpi? #1705

FailurePoint opened this issue Sep 9, 2023 · 3 comments

Comments

@FailurePoint
Copy link

Hi there everyone, I have been trying to install koel server on my raspberry pi for the last few days and have come a long way but I keep getting stuck on the init process, running "sudo php artisan koel:init" I get the configuration wizard which then tells me it can't find the data base. Great so far, I have not told it where that data base is yet, So I point it at the database I made for koel in mySQL with the correct username and password on localhost which I can connect to with maradb monitor and leave the port default (blank) and hit enter. Nothing... about 10 seconds later (I think the delay is just because my pi is a older model) it respons with:

WARN Cannot connect to the database. Let's set it up.

Your DB driver of choice [MySQL/MariaDB]:
[mysql ] MySQL/MariaDB
[pgsql ] PostgreSQL
[sqlsrv ] SQL Server
[sqlite-e2e] SQLite

What is up? Did I miss something? I tried from source and from the zip file.
This database and user is correctly filled out and I can reach it from maradb monitor from the command line on localhost... I have no firewall on the pi since it is a Lan only server, and mySQL is configured to accept on localhost...
Please help!

My setup:
Ras pi 3b+ 2 GB ram.
MySQL database from maradb.
Apache2 server.
Over the Lan on my starlink router.
Everything is configured as default.

Not sure if it helps any but my web root directory is "/var/www/html/" and koel is at "/var/www/html/koel/koel/"

I also posted this in discussions, I was not sure where it was more appropriate. Sorry.

@patrick-motard
Copy link

When I was installing Koel with Docker and Postgres I ran into an issue where php artisan koel:init --no-assets during the initial setup was failing to connect to Postgres. This issue lead me to the solution. Postgres uses port 5432 as it's default while MySQL and MariaDB use 3306 as their default. Koel defaults to 3306 when Postgress env vars are set. I would assume that it attempts to use 3306 all the time, but it wouldn't hurt to set the environment variable for this port explicitly to rule it out when you're attempting to connect.

@FailurePoint
Copy link
Author

I just used Navidrome(subsonic) and the Symphonium client instead :)
But thanks.

@ruhqersa
Copy link

I'm getting the same error. Did you solve the problem?

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