Re: Mysql
- From: David Bolt <blacklist-me@xxxxxxxxxx>
- Date: Mon, 31 Mar 2008 18:34:14 +0100
On Sun, 30 Mar 2008, houghi wrote:-
David Bolt wrote:
[0] IIRC, when you start up the mysql daemon for the first time, it asks
you to set a password for user root at localhost and also for
root@xxxxxxxxxxxxxx using /usr/bin/mysqladmin. If you haven't done very
much you might be lucky and find that command, including the password
you set, in your bash history.
The confusion comes from the fact that the user `root` on a system is
a user that has access to everything, while this is not true for a user
`root` in MySQL.
The confusion is probably because, after freshly installing mysql and
starting it for the first time, you get this[0]:
lion:~ # rcmysql start
Creating MySQL privilege database...
Installing MySQL system tables...
OK
Filling help tables...
OK
PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
/usr/bin/mysqladmin -u root password 'new-password'
/usr/bin/mysqladmin -u root -h lion.davjam.org password 'new-password'
See the manual for more instructions.
You can start the MySQL daemon with:
cd /usr ; /usr/bin/mysqld_safe &
You can test the MySQL daemon with mysql-test-run.pl
cd mysql-test ; perl mysql-test-run.pl
Please report any problems with the /usr/bin/mysqlbug script!
The latest information about MySQL is available on the web at
http://www.mysql.com
Support MySQL by buying support/licenses at http://shop.mysql.com
Updating MySQL privilege database...
Looking for 'mysql' in: /usr/bin/mysql
Looking for 'mysqlcheck' in: /usr/bin/mysqlcheck
Running 'mysqlcheck'...
mysql.columns_priv OK
mysql.db OK
mysql.func OK
mysql.help_category OK
mysql.help_keyword OK
mysql.help_relation OK
mysql.help_topic OK
mysql.host OK
mysql.proc OK
mysql.procs_priv OK
mysql.tables_priv OK
mysql.time_zone OK
mysql.time_zone_leap_second OK
mysql.time_zone_name OK
mysql.time_zone_transition OK
mysql.time_zone_transition_type OK
mysql.user OK
Running 'mysql_fix_privilege_tables'...
OK
Starting service MySQL done
There the user can be anybody, including `root` or `mysql_root` or
`anything_you_desire` and there has to be no relation perse between the
users on the system and the users in MySQL.
In a way, there is. That first user has the ability to do anything to
the mysql daemon including creating and "deleting" users, although
"deleting" users is probably the wrong term for it. To delete a user,
you just revoke their access rights using:
revoke all on *.* from 'user@hostname';
and then they no longer have access to any of the databases.
Even worse is that MySQL can work perfectly without the yser 'root' in
MySQL and on some places I read that having 'root' in MySQL could be a
security problem.
I've not read about that, but since I've not been chasing up that much
on mysql, it wouldn't surprise me if I'd missed it. If you can, can you
provide a citation for it?
Setting MySQL up is not the most logical thing to do.
Presently it requires entering 2 commands straight after the initial
start-up to set up the "root" users account and password. What's so hard
about that?
Hence bug #347149
Took me a long time to grasp that as well.
[0] after freshly installing mysql-Max on 10.3 (PPC)
Regards,
David Bolt
--
www.davjam.org/lifetype/ www.distributed.net: OGR@100Mnodes, RC5-72@15Mkeys
SUSE 10.1 32bit | openSUSE 10.2 32bit | openSUSE 10.3 32bit | openSUSE 11.0a1
SUSE 10.1 64bit | openSUSE 10.2 64bit | openSUSE 10.3 64bit
RISC OS 3.6 | TOS 4.02 | openSUSE 10.3 PPC |RISC OS 3.11
.
- Follow-Ups:
- Re: Mysql
- From: houghi
- Re: Mysql
- References:
- Mysql
- From: Blattus Slafaly 0/00 ? ? ?
- Re: Mysql
- From: Michael Soibelman
- Re: Mysql
- From: Blattus Slafaly 0/00 ? ? ?
- Re: Mysql
- From: birre
- Re: Mysql
- From: Blattus Slafaly 0/00 ? ? ?
- Re: Mysql
- From: Vahis
- Re: Mysql
- From: Blattus Slafaly 0/00 ? ? ?
- Re: Mysql
- From: Darrell Stec
- Re: Mysql
- From: Blattus Slafaly 0/00 ? ? ?
- Re: Mysql
- From: David Bolt
- Re: Mysql
- From: houghi
- Mysql
- Prev by Date: Re: Mysql
- Next by Date: Same-old Same-old Flash problem
- Previous by thread: Re: Mysql
- Next by thread: Re: Mysql
- Index(es):
Relevant Pages
|