I've tried to follow the above advice.
I've completely deleted my MySQl on OS X Server 10.4.7 and reinstalled using the lastest package "mysql-standard-5.0.24a-osx10.4-powerpc.dmg".
I just cannot get mysql to work properly, to set my root password.
See my first attempts with Terminal below (No.1)...
MySQL Adminsitaror and CoCoa SQL connecs with no username or password.
I've also tried to follow marcs advice at
http://www.entropy.ch/software/macosx/mysql/ but to no avail.
See my second attemps with Terminal below (No.2)...
If I can crack how to reinstall and setup MySQL on OS X Server 10.4.7 then I'll have a good Disaster Recovery Plan, I hope you can help, thanks.
----
No.1
---------------------------------------------------------------
Last login: Fri Sep 22 17:26:02 on ttyp1
Welcome to Darwin!
Server:~ admin$
Server:~ admin$ sudo /usr/local/mysql/bin/mysqld_safe --skip-grant-tables -u root &
[1] 1014
Server:~ admin$ A mysqld process already exists
[1]+ Exit 1 sudo /usr/local/mysql/bin/mysqld_safe --skip-grant-tables -u root
Server:~ admin$ sudo /Library/StartupItems/MySQLCOM/MySQLCOM stop
Stopping MySQL database server
Server:~ admin$ sudo /usr/local/mysql/bin/mysqld_safe --skip-grant-tables -u root &
[1] 1066
Server:~ admin$ Starting mysqld daemon with databases from /usr/local/mysql/data
Server:~ admin$ sudo /Library/StartupItems/MySQLCOM/MySQLCOM start
Starting MySQL database server
Server:~ admin$ /usr/local/mysql/bin/mysql -u root
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (13)
Server:~ admin$ /usr/local/mysql-standard-5.0.24a-osx10.4-powerpc/bin/mysql -u root
ERROR 2002 (HY000):
Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (13)
Server:~ admin$
----
No.2
---------------------------------------------------------------
Last login: Fri Sep 22 17:26:12 on ttyp1
Welcome to Darwin!
Server:~ admin$ sudo find /usr/local/mysql/data -type f -exec rm {} ';'
Password:
Server:~ admin$
Server:~ admin$ sudo hostname 127.0.0.1
Server:~ admin$ cd /usr/local/mysql
Server:/usr/local/mysql admin$ sudo ./scripts/mysql
installdb
Installing all prepared tables
060922 17:35:30 [Warning] Setting lower
case_tablenames=2 because file system for /usr/local/mysql-standard-5.0.24a-osx10.4-powerpc/data/ is case insensitive
060922 17:35:30 [Warning] No argument was provided to --log-bin, and --log-bin-index was not used; so replication may break when this MySQL server acts as a master and has his hostname changed!! Please use '--log-bin=127-bin' to avoid this problem.
Fill help tables
060922 17:35:31 [Warning] Setting lower
case_tablenames=2 because file system for /usr/local/mysql-standard-5.0.24a-osx10.4-powerpc/data/ is case insensitive
060922 17:35:31 [Warning] No argument was provided to --log-bin, and --log-bin-index was not used; so replication may break when this MySQL server acts as a master and has his hostname changed!! Please use '--log-bin=127-bin' to avoid this problem.
To start mysqld at boot time you have to copy support-files/mysql.server
to the right place for your system
PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:
./bin/mysqladmin -u root password 'new-password'
./bin/mysqladmin -u root -h 127.0.0.1 password 'new-password'
See the manual for more instructions.
You can start the MySQL daemon with:
cd . ; ./bin/mysqld_safe &
You can test the MySQL daemon with the benchmarks in the 'sql-bench' directory:
cd sql-bench ; perl run-all-tests
Please report any problems with the ./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
Server:/usr/local/mysql admin$ sudo chown -R mysql data/
Server:/usr/local/mysql admin$ /usr/local/mysql/bin/mysqladmin -u root password operate
/usr/local/mysql/bin/mysqladmin:
connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (13)'
Check that mysqld is running and that the socket: '/var/mysql/mysql.sock' exists!
Server:/usr/local/mysql admin$