Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
phpmyadmin: Access denied for user 'root'@'localhost'
phpmyadmin: Access denied for user 'root'@'localhost'
I just installed LAMP on debian9, but I can not log in to phpmyadmin with mariadb root/passwd. All I get is:
#1698 - Access denied for user 'root'@'localhost'
mysqli_real_connect(): (HY000/1698): Access denied for user 'root'@'localhost'
But I can log in to mariadb using command-line:
mysql -u root -p
...
So where is the problem? Why I can not login to mariadb over phpmyadmin?
#1698 - Access denied for user 'root'@'localhost'
mysqli_real_connect(): (HY000/1698): Access denied for user 'root'@'localhost'
But I can log in to mariadb using command-line:
mysql -u root -p
...
So where is the problem? Why I can not login to mariadb over phpmyadmin?
Re: phpmyadmin: Access denied for user 'root'@'localhost'
The root problem lies in your failure to do a simple search before posting a forum question:Jarry wrote:So where is the problem?
The verbatim title you chose for your thread returns over 100K answers to the question: https://www.google.com/search?q=phpmyad ... 8&oe=utf-8
And please accompany any claim that you did too search ("for hours" ) with a complete list of the exact things you have already tried and the exact results and verbatim output of each attempt.
If you are unable to do so for some mysterious reason, then go back and retry each and every one of them to produce that list. After all, there's no point in anyone here suggesting something you already tried, right?
(To be clear: "I tried them all and nothing worked" is neither specific nor even remotely believable. You did not try so much as 1% of the 100K available answers.)
-
- Posts: 1394
- Joined: 2007-03-04 21:10
- Location: U.S.A. - WI.
Re: phpmyadmin: Access denied for user 'root'@'localhost'
dasein wrote:The root problem lies in your failure to do a simple search before posting a forum question:Jarry wrote:So where is the problem?
The verbatim title you chose for your thread returns over 100K answers to the question: https://www.google.com/search?q=phpmyad ... 8&oe=utf-8
And please accompany any claim that you did too search ("for hours" ) with a complete list of the exact things you have already tried and the exact results and verbatim output of each attempt.
If you are unable to do so for some mysterious reason, then go back and retry each and every one of them to produce that list. After all, there's no point in anyone here suggesting something you already tried, right?
(To be clear: "I tried them all and nothing worked" is neither specific nor even remotely believable. You did not try so much as 1% of the 100K available answers.)
Since I am personally sick of hearing this in every thread from you:
You know how you tell Gary to STFU about all the stuff he doesn't understand all the time? Take your own advice and ignore all of these people that you tell to search better. As it is we might as well make an edit to the PHPBB code to just make a post comprised of " you suck at searching, goaway --signed dasein" to be immediately posted at each new thread generation.
That or try posting actual answers, I think I saw one maybe two actual answers in the last year from you. The rest was immediately jumping to conclusions, calling people trolls, and bitching incessantly about how people can't do searches.
TL;DR: Let easy search solvable threads die a natural death, your post count doesn't really matter that much.
EDIT = please feel free to add me to your ever-growing ignore list. Then you can wonder why the forums are so silent when you finally have "*" at the top of your list.
fortune -o
Your love life will be... interesting.
How did it know?
The U.S. uses the metric system too, we have tenths, hundredths and thousandths of inches
Your love life will be... interesting.
How did it know?
The U.S. uses the metric system too, we have tenths, hundredths and thousandths of inches
- GarryRicketson
- Posts: 5644
- Joined: 2015-01-20 22:16
- Location: Durango, Mexico
Re: phpmyadmin: Access denied for user 'root'@'localhost'
It would help to know what version of MySQL, is it MySQL 5.7 ?
http://parrotsandopenbsd.org/myforum/index.php it does work just fine
without phpmyadmin.
To avoid getting search results that are mostly just for ms windows,
It will be better if you add Debian, or specify Linux in your search string, like this:
you can copy paste into any search engine.
Also, this yields many results, that should be usefull:
https://www.startpage.com/do/search/?q= ... Y000/1698)
======================================================
This : https://stackoverflow.com/questions/368 ... d-everythi
Note where it mentions :
It may take a few tries before you get the passwords and user names set correctly, it was the same for me, it did not work the first couple of times,...
But in a nut shell, the reason you can not login via phpmyadmin , is something is wrong with how you set the user and password.
This was the reason I had problems recently :
So any way, if none of the things in the above links work, and you can give more details ,
show the error messages, etc,... maybe someone can narrow it down to something specific.
More then likely it is this:So where is the problem?
I have had the same problem on various servers, it can be different things. Most recently,but also it was not Debian, after several tries, it occurred to me that maybe phpmyadmin is not really necessary, and I decided to just not use it, it is not necessary, everything works just fine with out it. If you don't believe me see :From :https://askubuntu.com/questions/763336/ ... -mysql-5-7 MySQL 5.7 changed the secure model: now MySQL root login requires a sudo (while the password still can be blank).
I.e., phpMyAdmin will be not able to use root as user.
The simplest (and safest) solution will be create a new user and grant required privileges.
http://parrotsandopenbsd.org/myforum/index.php it does work just fine
without phpmyadmin.
To avoid getting search results that are mostly just for ms windows,
It will be better if you add Debian, or specify Linux in your search string, like this:
Code: Select all
phpmyadmin: Access denied for user 'root'@'localhost' on a Debian system
Also, this yields many results, that should be usefull:
https://www.startpage.com/do/search/?q= ... Y000/1698)
======================================================
This : https://stackoverflow.com/questions/368 ... d-everythi
Note where it mentions :
bind to all addresses:
The easiest way is to comment out the line in your /etc/mysql/mariadb.conf.d/50-server.cnf or /etc/mysql/mysql.conf.d/mysqld.cnf file, depending on what system you are running:Code: Select all
bind-address = 127.0.0.1
Since you have not really given much details, it is not possible to give a definite answer,Why I can not login to mariadb over phpmyadmin?
It may take a few tries before you get the passwords and user names set correctly, it was the same for me, it did not work the first couple of times,...
But in a nut shell, the reason you can not login via phpmyadmin , is something is wrong with how you set the user and password.
This was the reason I had problems recently :
MySQL makes a difference between "localhost" and "127.0.0.1".
It might be possible that 'root'@'localhost' is not allowed because there is an entry in the user table that will only allow root login from 127.0.0.1.
This could also explain why some application on your server can connect to the database and some not because there are different ways of connecting to the database. And you currently do not allow it through "localhost".
When I used 127.0.0.1 it worked fine. [/quote]My self: Hah, it turned out to be so simple, I was using "localhost" as the "hostname" , then I noticed on the tutorial,
Database host; Enter 127.0.0.1 or ::1. Do not leave it as “localhost” as we want to use the sockets;
So any way, if none of the things in the above links work, and you can give more details ,
show the error messages, etc,... maybe someone can narrow it down to something specific.
Re: phpmyadmin: Access denied for user 'root'@'localhost'
Believe or not, but I did search google (did not take me hours) and got the same list of answers you were so kind to post. If you really want to know what I did, so I tried the first solution and got stuck immediatelly with "Step 3: Open and edit your config.inc.php file located in your local server files".dasein wrote:The root problem lies in your failure to do a simple search before posting a forum question:
The verbatim title you chose for your thread returns over 100K answers to the question: https://www.google.com/search?q=phpmyad ... 8&oe=utf-8
And please accompany any claim that you did too search ("for hours" ) with a complete list of the exact things you have already tried and the exact results and verbatim output of each attempt.
First, I checked that file /etc/phpmyadmin/config.inc.php and found it does not contain the line with $cfg['Servers'][$i]['password']. Second, that file is "-rw-r--r--"! Call me paranoid, but I find it quite dangerous to put somewhere plain text root password that can be read by everyone (!!!). I could not believe *that* is the right solution, so in that moment I decided to ask here.
I expected to get a few "smart ass" answers like yours and you did not dissapoint me. Yet I sincerely hope you do not represent behaviour of typical debian-comunity user. I really do...
Re: phpmyadmin: Access denied for user 'root'@'localhost'
When I login to phpmyadmin—which is not often—the login is root with the mysql password.Jarry wrote:[...]Call me paranoid, but I find it quite dangerous to put somewhere plain text root password that can be read by everyone (!!!). I could not believe *that* is the right solution, so in that moment I decided to ask here.
No, it's not paranoid to be concerned about security; my advice, now that letsencrypt is available, is to use https.
DebianStable
Code: Select all
$ vrms
No non-free or contrib packages installed on debian! rms would be proud.
- GarryRicketson
- Posts: 5644
- Joined: 2015-01-20 22:16
- Location: Durango, Mexico
Re: phpmyadmin: Access denied for user 'root'@'localhost'
Still not clear, if it is
==========
The above is basically what I had to do, however I am not using 5.7 , it is 5.5,
also, I do not use "sudo", ever,...
I also removed and re-intsalled "phpmyadmin" , to try again... however the
dpkg-reconfigure command, accomplishes the same.
Hint, After you reconfigure phpmyadmin, it is a good idea to restart Mysql,
I don't see that mentioned in the one tutorial, in others they do .
Another thing , that causes confusion, the browser you use may be keeping
the old password, etc. in a cache, this can result in it not working, even after you
have made some changes and re-configured.
I am not familiar enough with Debian 9 and some of the "new features", but in any event
I had the same troubles even with Debian 6 and 7, ...
need phpmyadmin on my server. (probably should be another topic)
I strongly recommend looking at the information they (phpmydamin) have on their website:
https://docs.phpmyadmin.net/en/latest/security.html
https://www.phpmyadmin.net/support/
=============================
All though phpmyadmin is a package availble in Debian repositories, the problems
and security risks associated with it, are not specific to just Debian,..
https://docs.phpmyadmin.net/en/latest/config.html
you will find more details,and accurate info, on the Myphpadmin website.
==== Off topic a little ========
various ones , and mostly just the old, "if at first you don't succeed, try,try,and try again",..
================ on security =========
Yes, indeed, they do try to access all of the php files, looking for a way to access:
Here this one was trying to get the "setup.php". Since there is no "phpmyadmin"
on the system, they got a "404", the file does not exist, but any way, this is the kind of thing you need to be able to deal with if you have a production server, there are 100s of
"bad" bots, constantly trying to access...............
=======================Post by GarryRicketson » 2017-08-19 19:44
It would help to know what version of MySQL, is it MySQL 5.7 ?
from: https://askubuntu.com/questions/763336/ ... -mysql-5-7The fix was by reconfiguring phpmyadmin, and by answering some interactive questions.
Code: Select all
sudo dpkg-reconfigure phpmyadmin
<Ok>
Reinstall database for phpmyadmin: <Yes>
Connection method for MySQL database server for phpmyadmin: TCP/IP
Host name of the MySQL database server for phpmyadmin: localhost
Port number for the MySQL service: 3306
MySQL database name for phpmyadmin: phpmyadmin
<Ok>
MySQL username for phpmyadmin: root
MySQL application password for phpmyadmin: pass # OR ANY PASSWORD YOU WANT
Password confirmation: pass
Name of the database's administrative user: root
Web server to reconfigure automatically: apache2
An error occurred while installing the database: ignore
The above is basically what I had to do, however I am not using 5.7 , it is 5.5,
also, I do not use "sudo", ever,...
I also removed and re-intsalled "phpmyadmin" , to try again... however the
dpkg-reconfigure command, accomplishes the same.
Code: Select all
dpkg-reconfigure phpmyadmin
I don't see that mentioned in the one tutorial, in others they do .
Another thing , that causes confusion, the browser you use may be keeping
the old password, etc. in a cache, this can result in it not working, even after you
have made some changes and re-configured.
I am not familiar enough with Debian 9 and some of the "new features", but in any event
I had the same troubles even with Debian 6 and 7, ...
I agree, I found it questionable, and that leads to another reason I decided I don't reallyJarry wrote:Call me paranoid, but I find it quite dangerous to put somewhere plain text root password that can be read by everyone (!!!). I could not believe *that* is the right solution, so in that moment I decided to ask here.
need phpmyadmin on my server. (probably should be another topic)
Is a good solution as well.by kedaha »
When I login to phpmyadmin—which is not often—the login is root with the mysql password.
No, it's not paranoid to be concerned about security; my advice, now that letsencrypt is available, is to use https.
I strongly recommend looking at the information they (phpmydamin) have on their website:
https://docs.phpmyadmin.net/en/latest/security.html
=====================The phpMyAdmin developer team is putting lot of effort to make phpMyAdmin as secure as possible. But still web application like phpMyAdmin can be vulnerable to a number of attacks and new ways to exploit are still being explored.
https://www.phpmyadmin.net/support/
=============================
All though phpmyadmin is a package availble in Debian repositories, the problems
and security risks associated with it, are not specific to just Debian,..
https://docs.phpmyadmin.net/en/latest/config.html
There is no problem asking here, and since you are using Debian 9, ... how everAll configurable data is placed in config.inc.php in phpMyAdmin’s toplevel directory. If this file does not exist, please refer to the Installationsection to create one. This file only needs to contain the parameters you want to change from their corresponding default value in libraries/config.default.php (this file is not intended for changes).
you will find more details,and accurate info, on the Myphpadmin website.
==== Off topic a little ========
I believe you, and I spent literally days, going over the lists of answers, some are not very clear, others just don't work, ... after all said and done, it was little bit's and pieces fromby Jarry »Believe or not, but I did search google (did not take me hours) and got the same list of answers you were so kind to post.
various ones , and mostly just the old, "if at first you don't succeed, try,try,and try again",..
================ on security =========
Yes, indeed, they do try to access all of the php files, looking for a way to access:
Here this one was trying to get the "setup.php". Since there is no "phpmyadmin"
on the system, they got a "404", the file does not exist, but any way, this is the kind of thing you need to be able to deal with if you have a production server, there are 100s of
"bad" bots, constantly trying to access...............
Code: Select all
default 104.197.3.228 - - [22/Jul/2017:20:07:54 -0500] "GET /w00tw00t.at.blackhats.romanian.anti-sec:) HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:55 -0500] "GET /phpmyadmin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:55 -0500] "GET /phpMyAdmin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:55 -0500] "GET /mysqlmanager/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:55 -0500] "GET /p/m/a/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:55 -0500] "GET /phpmanager/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:55 -0500] "GET /mysql-admin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:55 -0500] "GET /mysqladmin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:56 -0500] "GET /webdb/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:56 -0500] "GET /webadmin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:56 -0500] "GET /phpmy-admin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:56 -0500] "GET /php-myadmin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:56 -0500] "GET /my/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:56 -0500] "GET /MyAdmin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:56 -0500] "GET /phpMyAdmin-2.10.0/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:57 -0500] "GET /myAdmin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:57 -0500] "GET /mysql/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:57 -0500] "GET /dbadmin/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:57 -0500] "GET /sqladm/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:57 -0500] "GET /scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:57 -0500] "GET /PMA/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:57 -0500] "GET /db/scripts/setup.php HTTP/1.1" 404 0
default 104.197.3.228 - - [22/Jul/2017:20:07:58 -0500] "GET /myadmin/scripts/setup.php HTTP/1.1" 404 0
- GarryRicketson
- Posts: 5644
- Joined: 2015-01-20 22:16
- Location: Durango, Mexico
Re: phpmyadmin: Access denied for user 'root'@'localhost'
I think I mentioned this before, but it is another thing that can cause this problem:
https://docs.phpmyadmin.net/en/latest/f ... calhost%27
https://docs.phpmyadmin.net/en/latest/f ... calhost%27
Do you have "127.0.0.1" as the host name.2.6 I get an “Access denied for user: 'root@localhost‘ (Using password: YES)”-error when trying to access a MySQL-Server on a host which is port-forwarded for my localhost.
When you are using a port on your localhost, which you redirect via port-forwarding to another host, MySQL is not resolving the localhost as expected. Erik Wasser explains: The solution is: if your host is “localhost” MySQL (the command line tool mysql as well) always tries to use the socket connection for speeding up things. And that doesn’t work in this configuration with port forwarding. If you enter “127.0.0.1” as hostname, everything is right and MySQL uses the TCP connection.
Code: Select all
man hosts
Code: Select all
man hostname
SEE ALSO
domainname(1), gethostname(3), myname(5), hostname(7), netstart(8)
Re: phpmyadmin: Access denied for user 'root'@'localhost'
[OT]pendrachken wrote: Since I am personally sick of hearing this in every thread from you:
You know how you tell Gary to STFU about all the stuff he doesn't understand all the time? Take your own advice and ignore all of these people that you tell to search better. As it is we might as well make an edit to the PHPBB code to just make a post comprised of " you suck at searching, goaway --signed dasein" to be immediately posted at each new thread generation.
That or try posting actual answers, I think I saw one maybe two actual answers in the last year from you. The rest was immediately jumping to conclusions, calling people trolls, and bitching incessantly about how people can't do searches.
Since you say you are sick of "hearing" (SIC) that, the simple solution that occurs to me is to take a bit of your own advice and put dasein on your ignore list. Nobody forces you to read any post.
Personally, I don't like people posting off topic in a help request about a personal issue when the forum has the mechanism for PMs.
I note your post doesn't have doesn't have any "actual answers" to the help request either. I don't find fault with constantly reminding of the expectation that users should search first and/or use Debian documentation as explained by the forum stickies from a forum admin. It seems clear to me that original poster wasn't harmed by dasein's post and has a thick enough skin to survive. I expect that otherwise Moderators would step in. Remember that these forums don't exist only to help the original poster and I hope that lurkers can recognise the goal of at least some of us here, that is is best to learn to help themselves and to detail what they have tried or don't understand so that it is easier to try and help them.
[/OT]
I apologise for adding my off topic post.
Thorny
-
- Posts: 11
- Joined: 2017-08-21 15:41
Re: phpmyadmin: Access denied for user 'root'@'localhost'
I was coming to this post to see if I could help and instead for the first time experience something I have read multiples times about Debian community.dasein wrote:The root problem lies in your failure to do a simple search before posting a forum question:Jarry wrote:So where is the problem?
The verbatim title you chose for your thread returns over 100K answers to the question: https://www.google.com/search?q=phpmyad ... 8&oe=utf-8
And please accompany any claim that you did too search ("for hours" ) with a complete list of the exact things you have already tried and the exact results and verbatim output of each attempt.
If you are unable to do so for some mysterious reason, then go back and retry each and every one of them to produce that list. After all, there's no point in anyone here suggesting something you already tried, right?
(To be clear: "I tried them all and nothing worked" is neither specific nor even remotely believable. You did not try so much as 1% of the 100K available answers.)
I am a new comer I love Debian and want to learn and help but when I see this type of post from a user with over 7000k post on this forum it made me question my decision. I do understand that seen redundant questions can be irritating but it is no reason.
There is no way this is helping the community at any level, the vibe behind is extremely controlling, negative and territorial and I hope admin of the forum will take notice.
Re: phpmyadmin: Access denied for user 'root'@'localhost'
Ooooo. Chastised by a sock puppet. I'm crushed.
(Do I win a prize if I guess who's behind the sock puppet account? Because I'm pretty sure I can. )
(Do I win a prize if I guess who's behind the sock puppet account? Because I'm pretty sure I can. )
-
- Posts: 11
- Joined: 2017-08-21 15:41
Re: phpmyadmin: Access denied for user 'root'@'localhost'
I will not dive further into this thread, it's already hijacked enough however this is not puppet account. I never posted here since I ask most of my question on the Debian help channel. Like I mentioned your post was the second one I have ever read here and I believe you should reconsider it if it's your desire is to help Debian and the community who support it.dasein wrote:Ooooo. Chastised by a sock puppet. I'm crushed.
(Do I win a prize if I guess who's behind the sock puppet account? Because I'm pretty sure I can. )
If you still believed this is a puppet account please come and speak with me on the Debian IRC channel. Most regular know me there for my incessant questioning.
Maybe you should take a break from helping on forum? Try IRC for a change?
Re: phpmyadmin: Access denied for user 'root'@'localhost'
Yep, that solved the problem! First I checked /etc/dbconfig-common/phpmyadmin.conf, and there was already some user (probably created during installation):GarryRicketson wrote:More then likely it is this:
From :https://askubuntu.com/questions/763336/ ... -mysql-5-7
MySQL 5.7 changed the secure model: now MySQL root login requires a sudo (while the password still can be blank). I.e., phpMyAdmin will be not able to use root as user. The simplest (and safest) solution will be create a new user and grant required privileges.
dbc_dbuser='phpmyadmin'
dbc_dbpass='**************'
I do not know what this user is good for (?) so I created another one:
CREATE USER 'adminmyphp'@'localhost' IDENTIFIED BY '**********';
GRANT ALL PRIVILEGES ON *.* TO 'adminmyphp'@'localhost' WITH GRANT OPTION;
FLUSH PRIVILEGES;
Now I can log in to phpmyadmin with user "adminmyphp" and password. Thanks!
Re: phpmyadmin: Access denied for user 'root'@'localhost'
"That" = the #5 hit at Google using the exact search that I pointed you to two days ago, but you were too farqing lazy even to click.Jarry wrote:Yep, that solved the problem!GarryRicketson wrote:More then likely it is this:
From :https://askubuntu.com/questions/763336/ ... -mysql-5-7
So much for "you searched, honest."
Lazy, lyin', Oedipus-wannabe
Re: phpmyadmin: Access denied for user 'root'@'localhost'
The times I've found myself unable to connect to web interfaces like phpmyadmin are more than I care to remember. Countless times. I think that the more such issues are documented either on the Debian wiki or here, the better; it's a pity places like askubuntu need to be consulted at all.
DebianStable
Code: Select all
$ vrms
No non-free or contrib packages installed on debian! rms would be proud.
Re: phpmyadmin: Access denied for user 'root'@'localhost'
Just to confirm, this is, in fact, the #4 hit for me when I click on the link in the second post [since Google displays result order differently per user] - even higher. The OP did say the following:dasein wrote: "That" = the #5 hit at Google using the exact search that I pointed you to two days ago, but you were too farqing lazy even to click.
That's weird, because if he got the same list of answers previously, he already would have come across that link, but yet, it was untried by him. He says he only tried the first link in the results generated. Everything points to insufficient research.Believe or not, but I did search google (did not take me hours) and got the same list of answers you were so kind to post
Let's face it, this thread has turned into a bit of a strudel but it does exhibit an important lesson about the importance of thorough user research. Objectively, dasein's original reply was critical but also helpful [if heeded] because the link the OP needed was indeed part of that he posted [which he said he already tried, and if he had clicked it, it would have appeared a second time for him]. As a result, the thread became unnecessarily circular.
Still, I'm glad the OP got his problem sorted.
EDIT: I didn't realise that all dasein did was Google the exact topic title. None of this needed to happen.
Re: phpmyadmin: Access denied for user 'root'@'localhost'
Yes, you are right. I tried only the 1st link, and got stuck. Not because it did not work, but because I had doubts doing something like that (as I mentioned previously, that "solution" required to write root's password in file that is globally readable!). It might work, but I considered it dangerous. That's why I asked here. No, I did not try the 2nd, 3rd, 4th, not even the milionth link. Google is usually pretty good in putting the right answer at the top (but not in thise case).Lysander wrote:That's weird, because if he got the same list of answers previously, he already would have come across that link, but yet, it was untried by him. He says he only tried the first link in the results generated. Everything points to insufficient research.
I'm new to Debian, but not to Linux generally. I'm running a few lamp-installations and had no problem with root's passwd (true, there's older mysql, I did not catch that 5.5->5.7 change). Ppl like dasein can not surprise me. I don't care of barking. But those like him make to Debian (and Linux in general) more harm than good...
Re: phpmyadmin: Access denied for user 'root'@'localhost'
I never login to mariadb from phpmyadmin as root. in a terminal I logged in to mariadb as root. I created a user and granted all privileges with grant privilege. When I login to phpmyadmin, I use the regular user name I created.
debian sid
Re: phpmyadmin: Access denied for user 'root'@'localhost'
Seriously, replies like this make go the extra mile to sign up and everything (although I probably already have/had an account here that I can't remember), just to say, you are the reason that traditional forums are being replaced by StackExchange type websites. You also contribute to the fact that "Google searches" also come up with threads like this, which are of no use to anyone.So much for "you searched, honest."
Lazy, lyin', Oedipus-wannabe
That said, the reply that you claim "works" does not work. It invites users to create a separate user not called 'root' and then give it the same exact privileges. IMHO, it's backwards.
If you want to allow access for user 'root' via PhpMyAdmin all you need to do is change the 'plugin' row/value for user root in the 'mysql' DB. Here's a step by step howto:
1. Connect to MySQL/MariaDB as root and select 'mysql' database
Code: Select all
server$ mysql -u root -p mysql
Code: Select all
MariaDB [mysql]> update user set plugin='' where user='root';
Code: Select all
MariaDB [mysql]> flush privileges;
Now, because some consider that this is not secure, you can always revert back, just do as above and replace set 2 with:
Code: Select all
MariaDB [mysql]> update user set plugin='unix_socket' where user='root';
This can be useful for those that would like to use PhpMyAdmin as root temporarily. It's better than just bypassing security with a different user that will have the same permissions and which will remain forever. And ever.
Bye.