Hi Christoph, O.K, what I can say already from your enclosed print is that the server mysqld is ignoring your settings.
Lets find out why. Check how your mysql server is started (as mysqld or safe_mysqld) : ps ax |grep mysql see that in my case a script is starting mysql-max (Suse Linux) 694 ? S 0:00 /bin/sh /usr/bin/mysqld_safe --datadir=/var/lib/mysql --pid-file=/var/lib/mysql/baby-bumble-bee.pid 742 ? S 0:00 /usr/sbin/mysqld-max --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/baby-bumble-bee.pid --skip-locking 790 ? S 0:00 /usr/sbin/mysqld-max --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/baby-bumble-bee.pid --skip-locking 791 ? S 0:00 /usr/sbin/mysqld-max --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/baby-bumble-bee.pid --skip-locking 922 ? S 0:00 /usr/sbin/mysqld-max --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/baby-bumble-bee.pid --skip-locking If unsure the easiest way would be to copy the line datadir=/mnt/data/mysql also into the [safe_mysqld] section of /etc/my.cnf Also bear in mind that the file ~/.my.cnf or var/lib/mysql/.my.cnf will take precedence over /etc/my.cnf which should set only the global settings. Please let me know once more the mysql server version you are using mysql> SELECT VERSION(); Best regards Nils Valentin Tokyo/Japan 2003年 5月 30日 金曜日 23:15、Jean Christophe さんは書きました: > [EMAIL PROTECTED] christophe]$ su - > Password: > [EMAIL PROTECTED] root]# vi /etc/my.cnf // I write > datadir=/mnt/data/mysql in the [mysqld] section > [EMAIL PROTECTED] root]# mysql > Welcome to the MySQL monitor. Commands end with ; or \g. > Your MySQL connection id is 1 to server version: 3.23.56 > > Type 'help;' or '\h' for help. Type '\c' to clear the buffer. > > mysql> show variables like '%data%' > -> ; > +-----------------------+-----------------+ > > | Variable_name | Value | > > +-----------------------+-----------------+ > > | datadir | /var/lib/mysql/ | > | innodb_data_file_path | | > | innodb_data_home_dir | | > | safe_show_database | OFF | > | skip_show_database | OFF | > > +-----------------------+-----------------+ > 5 rows in set (0.04 sec) > > mysql> quit > Bye > [EMAIL PROTECTED] root]# service mysqld restart > Stopper MySQL: [ O.k. ] > Starter MySQL: [ O.k. ] > [EMAIL PROTECTED] root]# service mysqld status > mysqld er død men undersystemet er låst // mysqld is dead but > undersystemet is closed > [EMAIL PROTECTED] root]# mysql > ERROR 2002: Can't connect to local MySQL server through socket > '/var/lib/mysql/mysql.sock' (111) > > her is an output of /etc/my.conf > The directory /mnt/data/mysql is a copy of the databases from > /var/lib/mysql. > I have asked the same question on a lot of forum without getting a > useful answer ! > > [mysqld] > datadir=/mnt/data/mysql > socket=/var/lib/mysql/mysql.sock > > [mysql.server] > user=mysql > basedir=/var/lib > > [safe_mysqld] > err-log=/var/log/mysqld.log > pid-file=/var/run/mysqld/mysqld.pid > > I hope you/somebody can help me ! > Regards > ;-) Jean Christophe > > Nils Valentin a écrit: > > Hi Jean; > > enter into /etc/my.cnf or ~/.my.cnf > > datadir=/mnt/data/mysql > > login to mysql and do > > SHOW VARIABLES LIKE '%data%' > > That should do it. > > Best regards > > Nils Valentin > > Tokyo/Japan -- ================================================ Valentin Nils Internet Technology E-Mail: [EMAIL PROTECTED] URL: http://www.knowd.co.jp ================================================ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]