Page 1 of 1

MariaDB help forum?? Can't log on initially

Posted: Mon Jul 01, 2019 2:00 pm
by Mtl_Biker
I'm a beginner to RPi and to MariaDB... and I've done a Google search to try finding a forum where it's discussed and where help might be available. Is there such a place?

I installed MariaDB a couple of weeks ago but haven't had a chance to do anything at all with it, other than confirming at the time that it was installed. I have not changed passwords or anything. Now I'm trying to log in (remotely using RealVNC) and cannot. Today is a holiday here in Canada and I was hoping to spend some time playing with and learning MariaDB and I'm stuck.

I believe my version is 10.1.38-0+deb9u1. If I enter the command

Code: Select all

mysql -u root -p -h localhost
I get

Code: Select all

ERROR 1698 (28000): Access denied for user 'root'@'localhost'
. My understanding is that the initial password is blank, so I only hit <enter> at the password prompt.

Any suggestions?

Re: MariaDB help forum?? Can't log on initially

Posted: Mon Jul 01, 2019 2:20 pm
by rpdom
Try just plain

Code: Select all

sudo mysql
That should default to the local root user. If there is no password set you leave out the "-p" option. The standard install on MariaDB is for root to only have access through the local interface, but once you have done that you can add users with access from other systems if needed.

Re: MariaDB help forum?? Can't log on initially

Posted: Mon Jul 01, 2019 2:20 pm
by Andyroo
Try

Code: Select all

sudo mysql -u root
and see if that gets you in

Re: MariaDB help forum?? Can't log on initially

Posted: Mon Jul 01, 2019 2:27 pm
by Mtl_Biker
rpdom wrote:
Mon Jul 01, 2019 2:20 pm
Try just plain

Code: Select all

sudo mysql
That should default to the local root user. If there is no password set you leave out the "-p" option. The standard install on MariaDB is for root to only have access through the local interface, but once you have done that you can add users with access from other systems if needed.
I'm IN!!!!! Thank you!

I was trying to follow a tutorial on the MariaDB site, and it did not use SUDO which I guess they assumed I would know to use. But I didn't know.

Do you know of any beginners forum for MariaDB?

Thanks again!

Re: MariaDB help forum?? Can't log on initially

Posted: Mon Jul 01, 2019 2:29 pm
by Mtl_Biker
Andyroo wrote:
Mon Jul 01, 2019 2:20 pm
Try

Code: Select all

sudo mysql -u root
and see if that gets you in
That works too! I was missing the SUDO part! Which I guess the MariaDB start guide assumed I would know about, but didn't.

Any suggestion of a beginners forum for MariaDB somewhere? Or is it alright to post here?

Re: MariaDB help forum?? Can't log on initially

Posted: Mon Jul 01, 2019 11:07 pm
by fbe
Avoid tutorials that recommend mysql_secure_installation on Debian/Raspbian Stretch or Buster.
Avoid tutorials that recommend to configure native password authentification for root@localhost on Debian/Raspbian Stretch or Buster without mentioning that a logrotate job will break and how to fix that.

Re: MariaDB help forum?? Can't log on initially

Posted: Tue Jul 02, 2019 1:34 pm
by Mtl_Biker
fbe wrote:
Mon Jul 01, 2019 11:07 pm
Avoid tutorials that recommend mysql_secure_installation on Debian/Raspbian Stretch or Buster.
Avoid tutorials that recommend to configure native password authentification for root@localhost on Debian/Raspbian Stretch or Buster without mentioning that a logrotate job will break and how to fix that.
Thank you. But what is "logrotate job"?