[Techtalk] MYSQL - newbie questions.

BUNTER MATTHEW Matthew.Bunter at renaultvi.com
Tue May 21 11:01:00 EST 2002


--- Reçu de       VITEUR.BUNTERMA 04 72 96 57 77             21/05/02 11.01

Betty,

You output shows that you aren't running mysql as root. When you run :

shell> cd mysql_installation_directory
shell> ./bin/mysql_install_db
shell> ./bin/safe_mysqld --user=mysql &

The last line starts mysql as a non-root user (in fact the userid mysql).

To create databases what I do is create them as the mysql root user. Then
grant permissions to read, update etc to different users. Remember that you
MUST set the mysql root user's password. This can be done using the
mysqladmin command or going in as the mysql root user, choosing the mysql
database and editing the user table directly. This also teaches some SQL
syntax.

I can really recommend the tutorials found at the mysql website as good
starting points.

I have no problem if you mail me asking questions about MySQL - I am by now
means an expert but have some experience.

Rgs,

Matt





-----------------------------------------------------------------------------

Date: Mon, 20 May 2002 08:14:07 -0600
Subject: [Techtalk] MYSQL - newbie questions.

I am trying to learn to use MySQL.  I am running Mandrake 8.1 and MySQL
version 3.23.41. I am following along in a book and it tells me I should not
be running the mysqld as root.  When I run the command ps auxw | grep mysqld
I get the following output.

root      2106  0.0  0.3  2444 1240 ?        S    07:45   0:00 /bin/sh
/usr/bin/safe_mysqld --datadir=/var/lib/mysql --pid-file=/var
mysql     2143  0.0  1.2 27024 4560 ?        S    07:45   0:00
/usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --
mysql     2146  0.0  1.2 27024 4560 ?        S    07:45   0:00
/usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --
mysql     2147  0.0  1.2 27024 4560 ?        S    07:45   0:00
/usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --
mysql     2148  0.0  1.2 27024 4560 ?        S    07:45   0:00
/usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --
root      2994  0.0  0.1  1760  620 pts/1    S    08:06   0:00 grep mysqld

This looks like I am running the process as root but being fairly new at all
this, I am just not sure. If I am, how can I change it? Also when I try to
add a database as my user, it will not let me do it. Can I change this by
just adding mysql permissions to my user ID?

Sorry for the newbie type questions and thanks.
-
_______________________________________________
Techtalk mailing list
Techtalk at linuxchix.org
http://mailman.linuxchix.org/mailman/listinfo/techtalk

---- 21/05/02 11.01 ---- Envoyé à      --------------------------------------
  -> techtalk(a)linuxchix.org



More information about the Techtalk mailing list