mysql_upgrade doesn't find its own stuff

2006-08-08 Thread Yves Goergen
Hello,

I was just trying out the mysql_upgrade script on my MySQL 5.0 server
but it shows an error message that makes me believe it doesn't know
where to find its own data.

Here's what I did:

mysql_upgrade --basedir=/usr/local/mysql5 --datadir=/var/mysql5/data
--password

And this is what I got:

Enter password: [so did I]
/usr/local/mysql5/bin/mysqlcheck: Got error: 2002: Can't connect to
local MySQL server through socket '/tmp/mysql.sock' (2) when trying to
connect
Could not find MySQL command-line client (mysql).
Please use --basedir to specify the directory where MySQL is installed.

The correct socket to connect to would be /var/tmp/mysql5.sock which is
written in the my.cnf file in the given datadir. And 'mysql' is in the
$PATH so my shell finds it without a problem. What can I do to make that
programme work? The MySQL version is 5.0.21 on a Debian 3.1 Linux
system. The server is running and works perfectly. I'm not sure if I
should upgrade to 5.0.24 if this script doesn't work.

-- 
Yves Goergen LonelyPixel [EMAIL PROTECTED]
http://beta.unclassified.de – My web laboratory.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: mysql_upgrade doesn't find its own stuff

2006-08-08 Thread chris smith

On 8/8/06, Yves Goergen [EMAIL PROTECTED] wrote:

Hello,

I was just trying out the mysql_upgrade script on my MySQL 5.0 server
but it shows an error message that makes me believe it doesn't know
where to find its own data.

Here's what I did:

mysql_upgrade --basedir=/usr/local/mysql5 --datadir=/var/mysql5/data
--password

And this is what I got:

Enter password: [so did I]
/usr/local/mysql5/bin/mysqlcheck: Got error: 2002: Can't connect to
local MySQL server through socket '/tmp/mysql.sock' (2) when trying to
connect
Could not find MySQL command-line client (mysql).
Please use --basedir to specify the directory where MySQL is installed.

The correct socket to connect to would be /var/tmp/mysql5.sock which is
written in the my.cnf file in the given datadir. And 'mysql' is in the
$PATH so my shell finds it without a problem.


Are you sure about that ?

Notice that you're installing into /usr/local/mysql5 which is NOT a
standard path.

Maybe it's finding an old version, check it:

mysql --version

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: mysql_upgrade doesn't find its own stuff

2006-08-08 Thread Yves Goergen
On 08.08.2006 13:16 CE(S)T, chris smith wrote:
 Are you sure about that ?

Well, I'm sure about what I've seen.

 Notice that you're installing into /usr/local/mysql5 which is NOT a
 standard path.
 
 Maybe it's finding an old version, check it:
 
 mysql --version

The 'mysql' binary it finds (located using 'which') is from the mysql5
directory, I've changed my PATH so that it works. There's a MySQL 4.0 in
/usr/local/mysql4 and the 5.0 in /usr/local/mysql5 on that machine, no
old versions, it was a clean OS image before it has seen any MySQL.

'mysql --version' says:

mysql  Ver 14.12 Distrib 5.0.21, for pc-linux-gnu (i686) using readline 5.0

What for do I specify the basedir and datadir (which should be enough)
if mysql_upgrade can't use it to find the files?

-- 
Yves Goergen LonelyPixel [EMAIL PROTECTED]
http://beta.unclassified.de – My web laboratory.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]