List:General Discussion« Previous MessageNext Message »
From:Gerald Clark Date:June 7 2002 7:26pm
Subject:Re: Permissions for mysqladmin
View as plain text  

Cindy Nelson wrote:

> Hi,
> I am using SuSE 7.0 and MySQL 4.0.1. I had quite a time
> getting the daemon started on Linux but finally succeeded.
> I can start the daemon logged on as su and I can connect
> to the database as user=mysql and modify the existing DB
> called test.
> I set the permissions as recommended in INSTALL-BINARY.
> Logged on as "su" I did the following:
>  chown -R root /usr/local/mysql 

that should be mysql, not root
chown -R mysql:mysql  /usr/local/mysql

>  chown -R mysql /usr/local/mysql/data 

not necessary - see above.

>  chgrp -R  /usr/local/mysql 

You forgot the group, but not necessary - see above.

>  chown -R /usr/root/local/mysql/bin

You forgot the user, but this should be ok from the chown -R 
 mysql:mysql /usr/local/mysql above

> Apparently what should happen is the system administrator should
> be able to start and stop the daemon and control the binary files and
> anybody in the group that I created "mysql" should be able to manipulate
> data in the DBs to which they have permissions. 

Only the mysqld  manipulates the data.

> Well.. I have a problem when I try to issue the
> command to create a new database. 

mysql -u root

That should get you in.
You need to read the manual section on privileges.
You have to set up privileges for other users that want to connect to 
the server.

>   mysqladmin create <databasename>
> If I am logged on as root or a user in the group mysql, I get the message
> Access denied for <anybody>@localhost.  I tried doing a chmod on 
> several files
> in mysql but to no avail. Also I notice there is no file in etc called
> my.cfg as the documentation suggests. It seems that the permissions are
> stored in a table in /usr/local/mysql/data/mysql but I cannot get at 
> the table to
> change anything.
> It would seem that there is someway to issue some kind of external 
> command
> that would change the permissions for the superuser and user mysql 
> without
> manipulating that table directly.
> I am really not concerned about security right now. This is a stand 
> alone Linux
> server at my house that is rarely connected to anything. I just want 
> to practice
> my SQL skills.
> Any ideas.
> **********************************************************************
> Cindy Nelson                                        (404) 213-9498 cell
> 202 Jimmie Nelson Rd SW                    (770) 382-4474 home
> Kingston, Ga 30145
>  e-mail: cindynelson@stripped
> **********************************************************************

Permissions for mysqladminCindy Nelson7 Jun
  • Re: Permissions for mysqladminGerald Clark7 Jun