Mariadb non-root userERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)MySQL Access denied for user 'root'@'localhost'Mariadb not working just after install on Ubuntu 16.04i have mysql 8.0.2 installed on my ubuntu 16.04.can not open it through terminal. so what to do now?ERROR 1698 (28000): Access denied for user 'root'@'localhost' at Ubuntu 18.04With Adminer.php I get a Access denied for user 'root'@'localhost' error. Ubuntu 18.04ERROR 1698 (28000): Access denied for user 'root'@'localhost'Problem in accessing to Mysql
Who verifies the trust of certificate authorities?
How to tell my Mom that I don't care about someone without upsetting her?
Intersection of sorted lists
Prospective employer asking for my current pay slip during interview
Thoughts on using user stories to define business/platform needs?
50K what to do with it?
How do electric hot water heaters explode and what can be done to prevent that from happening?
Forecast accuracy rolling window
Exception in thread "main" java.lang.AssertionError: expected [3] but found [3]
What's the difference between jpg and JPG on mac?
Ball hits curve of same curvature
Is gaining 1 AC in exchange for disadvantage on Perception checks a balanced trade?
Round up my number
Turing award papers
Professor Pun's Personal Project
How to replace all elements of a list by a rule "element" -> "element_"
Is a midspace space station between Earth and Mars practical?
Retracting Recommendation Letters
Which moves can’t be used in raid battles?
Delete selection without gradient effect
How much tech advancement could be made out of modern processor appearing in 1980s?
Prefix all commands in shell
Can I make leading exclamation points be ignored in the terminal? (I type them by instinct due to ipython)
What should be done if I suspect a player is using weighted dice?
Mariadb non-root user
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)MySQL Access denied for user 'root'@'localhost'Mariadb not working just after install on Ubuntu 16.04i have mysql 8.0.2 installed on my ubuntu 16.04.can not open it through terminal. so what to do now?ERROR 1698 (28000): Access denied for user 'root'@'localhost' at Ubuntu 18.04With Adminer.php I get a Access denied for user 'root'@'localhost' error. Ubuntu 18.04ERROR 1698 (28000): Access denied for user 'root'@'localhost'Problem in accessing to Mysql
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty
margin-bottom:0;
I have installed mariadb and when as a Linux root user, I can run mysql command to access the database. But when I try to login as a normal Linux user and run mysql -u root -p
, I am getting error:
ERROR 1698 (28000): Access denied for user 'root'@'localhost'.
I tried several methods like reset password for the mysql root user, but no use.
Any help will be great.
mysql root mariadb
add a comment
|
I have installed mariadb and when as a Linux root user, I can run mysql command to access the database. But when I try to login as a normal Linux user and run mysql -u root -p
, I am getting error:
ERROR 1698 (28000): Access denied for user 'root'@'localhost'.
I tried several methods like reset password for the mysql root user, but no use.
Any help will be great.
mysql root mariadb
Possible duplicate of ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
– Faizan Akram Dar
Dec 3 '16 at 10:37
add a comment
|
I have installed mariadb and when as a Linux root user, I can run mysql command to access the database. But when I try to login as a normal Linux user and run mysql -u root -p
, I am getting error:
ERROR 1698 (28000): Access denied for user 'root'@'localhost'.
I tried several methods like reset password for the mysql root user, but no use.
Any help will be great.
mysql root mariadb
I have installed mariadb and when as a Linux root user, I can run mysql command to access the database. But when I try to login as a normal Linux user and run mysql -u root -p
, I am getting error:
ERROR 1698 (28000): Access denied for user 'root'@'localhost'.
I tried several methods like reset password for the mysql root user, but no use.
Any help will be great.
mysql root mariadb
mysql root mariadb
edited May 5 '16 at 8:43
muru
1
1
asked May 5 '16 at 8:34
Narayanan NarayananNarayanan Narayanan
11 silver badge1 bronze badge
11 silver badge1 bronze badge
Possible duplicate of ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
– Faizan Akram Dar
Dec 3 '16 at 10:37
add a comment
|
Possible duplicate of ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
– Faizan Akram Dar
Dec 3 '16 at 10:37
Possible duplicate of ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
– Faizan Akram Dar
Dec 3 '16 at 10:37
Possible duplicate of ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
– Faizan Akram Dar
Dec 3 '16 at 10:37
add a comment
|
2 Answers
2
active
oldest
votes
I had the same problem, it was caused by a "plugin" value in "mysql.user" table.
Have you tried with this answer: https://askubuntu.com/a/636579/299538
Here is an explanation for that: https://superuser.com/a/1071043/592085
add a comment
|
In MariaDB you cannot login with normal user, you must root access or use sudo
. Another solution add another root user with full privileges.
Connect with sudo to db:
sudo mysql -u root
Check your account in present db:
mysql> SELECT User,Host FROM mysql.user;
+------------------+-----------+
| User | Host |
+------------------+-----------+
| root | localhost |
Recreate user root
(use password if you need):
mysql> CREATE USER 'root'@'%' IDENTIFIED BY '';
Give permission:
mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'%';
Flush:
mysql> FLUSH PRIVILEGES;
Show database uses:
SELECT User,Host FROM mysql.user;
+------+-----------+
| User | Host |
+------+-----------+
| root | % |
| root | localhost |
+------+-----------+
Exit and connect with normal user:
mysql -u root
add a comment
|
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "89"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/4.0/"u003ecc by-sa 4.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f767887%2fmariadb-non-root-user%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
I had the same problem, it was caused by a "plugin" value in "mysql.user" table.
Have you tried with this answer: https://askubuntu.com/a/636579/299538
Here is an explanation for that: https://superuser.com/a/1071043/592085
add a comment
|
I had the same problem, it was caused by a "plugin" value in "mysql.user" table.
Have you tried with this answer: https://askubuntu.com/a/636579/299538
Here is an explanation for that: https://superuser.com/a/1071043/592085
add a comment
|
I had the same problem, it was caused by a "plugin" value in "mysql.user" table.
Have you tried with this answer: https://askubuntu.com/a/636579/299538
Here is an explanation for that: https://superuser.com/a/1071043/592085
I had the same problem, it was caused by a "plugin" value in "mysql.user" table.
Have you tried with this answer: https://askubuntu.com/a/636579/299538
Here is an explanation for that: https://superuser.com/a/1071043/592085
edited Apr 13 '17 at 12:23
Community♦
1
1
answered May 9 '16 at 17:55
J.SerraJ.Serra
5311 gold badge6 silver badges24 bronze badges
5311 gold badge6 silver badges24 bronze badges
add a comment
|
add a comment
|
In MariaDB you cannot login with normal user, you must root access or use sudo
. Another solution add another root user with full privileges.
Connect with sudo to db:
sudo mysql -u root
Check your account in present db:
mysql> SELECT User,Host FROM mysql.user;
+------------------+-----------+
| User | Host |
+------------------+-----------+
| root | localhost |
Recreate user root
(use password if you need):
mysql> CREATE USER 'root'@'%' IDENTIFIED BY '';
Give permission:
mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'%';
Flush:
mysql> FLUSH PRIVILEGES;
Show database uses:
SELECT User,Host FROM mysql.user;
+------+-----------+
| User | Host |
+------+-----------+
| root | % |
| root | localhost |
+------+-----------+
Exit and connect with normal user:
mysql -u root
add a comment
|
In MariaDB you cannot login with normal user, you must root access or use sudo
. Another solution add another root user with full privileges.
Connect with sudo to db:
sudo mysql -u root
Check your account in present db:
mysql> SELECT User,Host FROM mysql.user;
+------------------+-----------+
| User | Host |
+------------------+-----------+
| root | localhost |
Recreate user root
(use password if you need):
mysql> CREATE USER 'root'@'%' IDENTIFIED BY '';
Give permission:
mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'%';
Flush:
mysql> FLUSH PRIVILEGES;
Show database uses:
SELECT User,Host FROM mysql.user;
+------+-----------+
| User | Host |
+------+-----------+
| root | % |
| root | localhost |
+------+-----------+
Exit and connect with normal user:
mysql -u root
add a comment
|
In MariaDB you cannot login with normal user, you must root access or use sudo
. Another solution add another root user with full privileges.
Connect with sudo to db:
sudo mysql -u root
Check your account in present db:
mysql> SELECT User,Host FROM mysql.user;
+------------------+-----------+
| User | Host |
+------------------+-----------+
| root | localhost |
Recreate user root
(use password if you need):
mysql> CREATE USER 'root'@'%' IDENTIFIED BY '';
Give permission:
mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'%';
Flush:
mysql> FLUSH PRIVILEGES;
Show database uses:
SELECT User,Host FROM mysql.user;
+------+-----------+
| User | Host |
+------+-----------+
| root | % |
| root | localhost |
+------+-----------+
Exit and connect with normal user:
mysql -u root
In MariaDB you cannot login with normal user, you must root access or use sudo
. Another solution add another root user with full privileges.
Connect with sudo to db:
sudo mysql -u root
Check your account in present db:
mysql> SELECT User,Host FROM mysql.user;
+------------------+-----------+
| User | Host |
+------------------+-----------+
| root | localhost |
Recreate user root
(use password if you need):
mysql> CREATE USER 'root'@'%' IDENTIFIED BY '';
Give permission:
mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'%';
Flush:
mysql> FLUSH PRIVILEGES;
Show database uses:
SELECT User,Host FROM mysql.user;
+------+-----------+
| User | Host |
+------+-----------+
| root | % |
| root | localhost |
+------+-----------+
Exit and connect with normal user:
mysql -u root
answered Sep 28 at 6:42
ObelixObelix
236 bronze badges
236 bronze badges
add a comment
|
add a comment
|
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f767887%2fmariadb-non-root-user%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Possible duplicate of ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
– Faizan Akram Dar
Dec 3 '16 at 10:37