@
@
@okolike2016-03-21 10:25:44
MySQL
@okolike, 2016-03-21 10:25:44

How to set permissions for a user in MySQL?

Such a problem, I took a VPS server, created a database, and so on.
But editing the database through MySQL displays an error. The provider says that you need to set the rights to edit, and so on.
I went through SSH to the /etc/mysql/my.cnf section.
What should I set there?

[client]
port=3306
socket=/var/run/mysqld/mysqld.sock

[mysqld_safe]
socket=/var/run/mysqld/mysqld.sock

[mysqld]
user=mysql
pid-file=/var/run/mysqld/mysqld.pid
socket=/var/run/mysqld/mysqld.sock
port=3306
basedir=/usr
datadir=/var/lib/mysql
tmpdir=/tmp
lc-messages-dir=/usr/share/mysql
log_error=/var/log/mysql/error.log

symbolic-links=0

To give rights 775

Answer the question

In order to leave comments, you need to log in

2 answer(s)
Y
Yuri Chudnovsky, 2016-03-21
@Frankenstine

Wow. There are no words.
www.mysql.ru/docs/man/GRANT.html
Although it's probably too complicated :)

A
Anton B, 2016-03-21
@bigton

mysql -uroot -p // connect in ssh to mysql
then use sql commands to create a user and give him privileges (see manual).

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question