?
Solved

why the machine name is appended with db user is mysql?

Posted on 2013-11-21
2
Medium Priority
?
359 Views
Last Modified: 2013-11-22
Hi,

I have created a database in mysql with user id "root" and pwd "xxx".

Now when the user from different machine access the database it gives error say
"root@machinename" does not exists.

every time i need to create user "root@machinename" and grant privileges to that then only db accessed.

why the machine name is appended with db user is mysql?
0
Comment
Question by:Rocking
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
2 Comments
 
LVL 14

Assisted Solution

by:jb1dev
jb1dev earned 2000 total points
ID: 39667978
When creating users, you need to grant them access:

http://dev.mysql.com/doc/refman/5.5/en/adding-users.html

E.g.
GRANT ALL PRIVILEGES ON *.* TO 'monty'@'localhost'

Open in new window


You can use the wildcare '%' for all hosts.

E.g.
GRANT ALL PRIVILEGES ON *.* TO 'monty'@'%'
0
 
LVL 14

Accepted Solution

by:
jb1dev earned 2000 total points
ID: 39667983
From the link I posted above

mysql> CREATE USER 'monty'@'%' IDENTIFIED BY 'some_pass';
mysql> GRANT ALL PRIVILEGES ON *.* TO 'monty'@'%'
    ->     WITH GRANT OPTION;

Open in new window



The 'monty'@'%' account uses the '%' wildcard for the host part, so it can be used to connect from any host.
0

Featured Post

Optimize your web performance

What's in the eBook?
- Full list of reasons for poor performance
- Ultimate measures to speed things up
- Primary web monitoring types
- KPIs you should be monitoring in order to increase your ROI

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
This article shows the steps required to install WordPress on Azure. Web Apps, Mobile Apps, API Apps, or Functions, in Azure all these run in an App Service plan. WordPress is no exception and requires an App Service Plan and Database to install
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question