2 copy of Mysql (3.23.58 & 4.017)

Hi,

Mysql 3.23.58 is running,
/usr/local/mysql/data
/tmp/mysql.sock
/etc/my.cnf
port 3306

i use /usr/local/mysql/mysql.server start/stop to start mysql 3.23

Now i install another copy, Mysql 4.0.17
/usr/local/mysql2
/usr/local/mysql2/bin/mysqladmin, mysqld_safe,etc

and i want to use /usr/local/mysql2/mysql.server start/stop
to start mysql 4, as well as using /usr/local/mysql2/etc/my.cnf

# The following options will be passed to all MySQL clients
[client]
#password = your_password
port = 3308
socket = /usr/local/mysql2/tmp/mysql.sock

# Here follows entries for some specific programs

# The MySQL server
[mysqld]
port = 3308
socket = /usr/local/mysql2/tmp/mysql.sock
pid-file =/usr/local/mysql2/data--enable-assembler/mysql2.pid
skip-locking
key_buffer = 256M
max_allowed_packet = 1M
table_cache = 256
sort_buffer_size = 1M
read_buffer_size = 1M
myisam_sort_buffer_size = 64M
thread_cache = 8
query_cache_size= 16M
thread_concurrency = 4
....
....

But FAILED, err saying :
040206 22:12:24 mysqld started
040206 22:12:24 Can't start server: Bind on TCP/IP port: Address already in use
040206 22:12:24 Do you already have another mysqld server running on port: 3306 ?
040206 22:12:24 Aborting

AND
I try using >bin/mysqld_safe --user=mysql --port=3308 --socket=/usr/local/mysql2/tmp/mysql.sock --skip-locking &
Mysql 4 is running well on port 3308!

SO, the main problem is how to configure the mysql.server to get the correct /usr/local/mysql2/etc/my.cnf file

 

 

 

 

Top