Page 1 of 1

Anyone run MySQL on a RPi 3+?

Posted: Wed Jun 12, 2019 3:13 pm
by Mtl_Biker
Thinking I'm going to get a second RPi. They're addictive. And like potato chips, you can't have just one.

Does anyone run MySQL on a RPi? Server. If so, I'm thinking it might make a great platform to play with and get my feet wet with MySQL. Years ago I used to program in Visual FoxPro and some MS SQL Server, but I'm really rusty.

Is there a MySQL version/package that's recommended? Any gotchas with running an external drive via USB? Any words of wisdom about this idea?

Re: Anyone run MySQL on a RPi 3+?

Posted: Wed Jun 12, 2019 3:22 pm
by fruitoftheloom
Mtl_Biker wrote:
Wed Jun 12, 2019 3:13 pm
Thinking I'm going to get a second RPi. They're addictive. And like potato chips, you can't have just one.

Does anyone run MySQL on a RPi? Server. If so, I'm thinking it might make a great platform to play with and get my feet wet with MySQL. Years ago I used to program in Visual FoxPro and some MS SQL Server, but I'm really rusty.

Is there a MySQL version/package that's recommended? Any gotchas with running an external drive via USB? Any words of wisdom about this idea?

Yes MySQL / MariaDB has been extensively posted about over the last 7 years. Many blogs and tutorials on this subject !

Re: Anyone run MySQL on a RPi 3+?

Posted: Wed Jun 12, 2019 3:28 pm
by rpdom
It's MariaDB now instead of MySQL, but yes, I do run it on a 3B+. I also run the older MySQL on a couple of Pi 2Bs, one of which has a couple of servers running MariaDB slaves off it.

Re: Anyone run MySQL on a RPi 3+?

Posted: Wed Jun 12, 2019 4:14 pm
by Mtl_Biker
Great! Thanks guys. I'd never heard of MariaDB (I haven't touched programming in years) and I'm going to look into it. And I'm ordering another RPi today to install it on (for playing and learning).

Cheers!

Re: Anyone run MySQL on a RPi 3+?

Posted: Wed Jun 12, 2019 9:05 pm
by W. H. Heydt
Mtl_Biker wrote:
Wed Jun 12, 2019 4:14 pm
Great! Thanks guys. I'd never heard of MariaDB (I haven't touched programming in years) and I'm going to look into it. And I'm ordering another RPi today to install it on (for playing and learning).

Cheers!
MariaDB is a fork of MySQL that was started after Oracle bought MySQL. As I understand it, there is much more active development work taking place on MariaDB than on MySQL. The general interfaces are the same, though that souldn't be an issue to some new to either DBMS.

And isn't it cute that you are getting your second Pi.. :-) I think I have somewhere upwards of 30...or should that be 40? In either case, once the Pi4B shows up in a year of two, that'll probably grow by another 10 or so.

Re: Anyone run MySQL on a RPi 3+?

Posted: Wed Jun 12, 2019 9:16 pm
by Andyroo
Mtl_Biker wrote:
Wed Jun 12, 2019 4:14 pm
...And I'm ordering another RPi today to install it on (for playing and learning).

Cheers!
Warned you :lol:

Re: Anyone run MySQL on a RPi 3+?

Posted: Thu Jun 13, 2019 9:05 pm
by deepo
I just installed MariaDB on my RPi 3B+ running Raspbian Lite.

All you have to do is:

Code: Select all

sudo apt-get install mariadb-server
You can then log in:

Code: Select all

sudo mysql -u root -p -h localhost
There is no password, so just press enter.

/Mogens

Re: Anyone run MySQL on a RPi 3+?

Posted: Thu Jun 13, 2019 9:20 pm
by Mtl_Biker
deepo wrote:
Thu Jun 13, 2019 9:05 pm
I just installed MariaDB on my RPi 3B+ running Raspbian Lite.

All you have to do is:

Code: Select all

sudo apt-get install mariadb-server
You can then log in:

Code: Select all

sudo mysql -u root -p -h localhost
There is no password, so just press enter.

/Mogens
Thank you! That's very helpful!

But just to confirm... you've installed MariaDB, but you log in with sudo MYSQL?

Re: Anyone run MySQL on a RPi 3+?

Posted: Fri Jun 14, 2019 5:21 am
by rpdom
Mtl_Biker wrote:
Thu Jun 13, 2019 9:20 pm
But just to confirm... you've installed MariaDB, but you log in with sudo MYSQL?
That is correct. MariaDB and MySQL are compatible. The Opensource community were unhappy with Oracle taking over MySQL, so they forked an earlier version of the code, updated it and renamed it MariaDB. (That's a simplified version, but essentially what happened).

Pretty much any code that uses MySQL can use MariaDB with no changes. The command line client kept the same name for compatibility. You can type "mariadb" instead of "mysql" if you want. It will still work and still give a "MySQL" prompt.