Centos mysql access remote [closed] - mysql

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 7 years ago.
Improve this question
I could before login with the username : username, and no password.
then it stopped working, created another account, so it worked for a while. Then it randomly stopped.
Now the users are ( from ssh)
i tired to login with the user root, omg, username ( host %), and also tried on root and testacc on the ip adresses. but nothing works. ( i am 100% sure i was using the right passwords)
I get this while trying to connect with one of the users:
Q: How can i make this work? why wont it work out of suddenly? and could someone tell me more about how this acually works?

You need to GRANT access from outside in mysql.
Go to mysql server and login as root user.
Run GRANT ALL ON db_name.* TO 'user'#'81.167.51.107' IDENTIFIED BY 'password' for access from particular IP address or GRANT ALL ON db_name.* TO 'user'#'%' IDENTIFIED BY 'password' for any IP address.

Related

I am getting errors while fetching APIs from FE regarding MySQL database connection [closed]

Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 2 days ago.
Improve this question
I ran following commands in MySql command line
grant all privileges on . to root#localhost;
flush privileges;
but it didn't work
How to grant all permissions to all users no need of thinking about security I just want to start this project immediately on my local machine
And in console onclick the signup button this error occuring(img 2)
I am tried several command to grant permission I don't succeed.

ER_ACCESS_DENIED_ERROR when connecting to Mysql database [closed]

Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 5 years ago.
Improve this question
hello, i am trying to connect to my Mysql database but i get this error : MySQL error: Error: ER_ACCESS_DENIED_ERROR: Access denied for user 'hulken3'#'localhost' (using password: YES)
I have given this user "hulken3" all privileges but it's still not working,
You may need to give privilege to new user, so connect as root user and grant permission. Hope information in below site, gives you instruction on how to do that
http://dev.mysql.com/doc/refman/5.5/en/adding-users.html
My problem was that my Domain provider was blocking connections to the Mysql database. Thanks for your answers!

MySQL for admin and user(receptionist) [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
I am doing a project on hotel management, How can i create a MySQL database (that will connect to java), where the admin has the sole right and the receptionist has privileges on some of the tables, like inserting, selecting...
This is possible, have a look at http://dev.mysql.com/doc/refman/5.5/en/privilege-system.html. However, I would highly recommend to handle these kind of permissions on application (java) level, so you don't have to switch mysql users inside your app.
Install MySQL.
mysqladmin -u root password "secret-password"
mysql -u root -p'secret_password'
> CREATE DATABASE hm ;
> GRANT SELECT,INSERT,UPDATE ON hm.* TO hm_receptionist#'%'
> IDENTIFIED BY 'secret_password' ;
> GRANT ALL ON hm.* TO hm_admin#'%'
> IDENTIFIED BY 'secret_password' ;

Why do I have a lot of root users in my Mysql? [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 9 years ago.
Improve this question
I don't remember creating these users in my Mysql installation:
debian-sys-maint
phpmyadmin
And I have 3 Any users and 4 root users.
Here's the screen shot taken from Phpmyadmin:
http://imgur.com/AYwkxKn
And here's the command line version:
http://imgur.com/PWaccsV
Should I be wary of these users? Or is this the default?
A MySQL user is actually identified by a pair of username and hostname. 127.0.0.1, ::1, and localhost all allow you access from your local machine. Without them, you would not be able to connect. The only one that may be an issue is the ip-10.242.75.6, but I expect that is the machine's IP also?
As for the phpmyadmin and ANY users, the MySQL documentation says
The USAGE privilege specifier stands for “no privileges.” It is used
at the global level with GRANT to modify account attributes such as
resource limits or SSL characteristics without affecting existing
account privileges.
You would have a record for each user and each IP address that user is allowed to connect from.
These are permissions rather than separate user accounts. All it says is that, user root is allowed to connect from all those host addresses with ALL_PRIVILEGES. localhost, ::1 and 127.0.0.1 are the same machines address on which the SQL server is installed on.
The listed hosts on the picture are different name variations of localhost. these 2 users should be able to access localhost by any of these names, that's why there are created duplicates

Setting mysql server name with and without www [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I am using a mysql server on my linux ubuntu 10.04.
Everything is working fine, when I use example.com as the mysql server name.
When I use www.example.com as the mysql server name, the connection does not work. Where can I change the settings.
The URL of my website is working with www and without.
Is the mysql server name a setting in the mysql configuration or is it the hostname of my domain?
You can check your MySQL servers users table. When you see the user, edit it and set this value for the host he/she can connect to:
%example.com
The % is a wildcard for everything in front of "example.com". The second alternative is to add a new user<->host combination via CREATE USER http://dev.mysql.com/doc/refman/5.1/en/create-user.html
BUT ATTENTION: You should never, never, never connect to your MySQL from outside localhost. And if so, use an SSH Tunnel to do so.