Page 1 of 1

MySql set up problem ?

Posted: Tue Mar 22, 2005 4:49 am
by timf
Ok, a little progress here, suspect I haven't got the right DB, user etc set-up in MySql.
If so how can I check what Mysql is working with and add to /change ?

Sorry for being so slow at this but this is all new ground for me !

PS running Mysql 4.0.24
Thanks Tim

[root@amdxp1800 zm-1.20.1]# perl zmconfig.pl -noi
Loading config from 'zmconfig.txt'
Loading config from DB
DBI connect('database=zm;host=localhost','timf_mys',...) failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) at zmconfig.pl line 1611
Error: unable to load options from database: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
Saving config to 'zmconfig.txt'
Saving config to DB
DBI connect('database=zm;host=localhost','timf_mys',...) failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) at zmconfig.pl line 1515
Error: unable to save options to database: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
Generating 'src/zm_config_defines.h'
Processing 'zm.conf'
Processing 'src/zm_config.h'
Processing 'web/zm_config.php'
Processing 'scripts/zmdc.pl'
Processing 'scripts/zmwatch.pl'
Processing 'scripts/zmaudit.pl'
Processing 'scripts/zmfilter.pl'
Processing 'scripts/zmtrigger.pl'
Processing 'scripts/zmx10.pl'
Processing 'scripts/zmpkg.pl'
Processing 'scripts/zmupdate.pl'
Processing 'scripts/zmvideo.pl'
Processing 'scripts/zm'
Processing 'db/zmschema.sql'
etc etc

Posted: Tue Mar 22, 2005 5:09 am
by cordel
So where did you configre Mysql to put the socket? setting should be in /etc/my.conf for mysql. You could also run a whereis for the sock. If it don't turn up then check to make sure mysql is running. You can also referance http://www.mysql.com/documentation/index.html there is alot of info in their doc's to trouble shoot.

Cordel

Port 3306

Posted: Tue Mar 22, 2005 5:57 am
by timf
Hi Cordel,

making progress - slowly but better with your help..
Maybe I have to edit socket = /tmp/mysql.sock
to
/var/lib/mysql/mysql.sock ???

Hope there's something I can do for you in return sometime..

I'll study the MySql docs tomorrow....

Regards Tim

contents of my.conf
# The following options will be passed to all MySQL clients
[client]
#password = your_password
port = 3306
socket = /tmp/mysql.sock

# Here follows entries for some specific programs

# The MySQL server
[mysqld]
port = 3306
socket = /tmp/mysql.sock
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
# Try number of CPU's*2 for thread_concurrency
thread_concurrency = 8

Posted: Tue Mar 22, 2005 6:22 am
by cordel
That would be the simplist for you to do. As long as the the mysql is putting the sock file the same place as zm is looking for it. Once you change the config make sure to restart mysql.

try help

Posted: Tue Mar 22, 2005 9:55 pm
by kern
em, on this problem,
if mysqld prblem to load or startup,based on my experience is just put
command line like this:

[client]
password=<yourpassword>

into file .my.cnf at directory /root

mention me if it work

ZM start script ?

Posted: Wed Mar 23, 2005 5:16 am
by timf
Hi Kern, Cordel
A bit of progress to report and another question..
First editing my.conf as suggested got rid of the can't find socket error.
So I was able to complete make and install ZM - lots of new perl scripts and binaries in all the right places, as far as I can tell.
But I don't appear to have a zm start script so I can't figure out how to 'turn it on'.

I have zma, zmc, zmf, zmu and zmfix but no zm. (and no zms either)
Any suggestions ?

tia Tim

Posted: Wed Mar 23, 2005 7:13 am
by cordel
Look in the readme doc. The script has to be hand installed and a couple changes need be made.
change chkconfig line to this
# chkconfig: 2345 99 01
Cheers,
Cordel