verify your servers (MySQL,PHP, etc) versions
or post your code
Main Topics
Browse All TopicsI'm trying to create a procedure using the same syntax successfully used on a different server with the same version of MySQL. This is a new LAMP server (CentOS 5.2) so mysql may not be configured correctly. I've checked the permissions in /var/lib/mysql and they look fine.
What configuration options might I need to change?
I've read some suggestions that mysql be reinstalled. I'd rather not do that obviously, but if I must, how can I do this in a thorough manner?
Thanks for any feedback.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
I'm having trouble finding the error log. According to
http://dev.mysql.com/doc/r
the error log should be in the /var/lib/mysql directory with the .err extension, but i'm only seeing ib_logfile0, ib_logfile1.
I'm using
mysql Ver 14.14 Distrib 5.1.32 for redhat-linux-gnu (i686) using readline 5.1
and
PHP 5.2.9 (cli)
Check on your mysql configuration, if you have error log on, if you specify a name for it (hostname.err is the default) and the location of it.
http://dev.mysql.com/doc/r
I've found the log for my installation in /var/log/mysqld.log. I'm not noticing any errors when I attempt to create the procedure, but there are some errors when mysql is started:
090403 12:05:55 [Note] /usr/libexec/mysqld: Normal shutdown
090403 12:05:55 InnoDB: Starting shutdown...
090403 12:05:56 InnoDB: Shutdown completed; log sequence number 0 43665
090403 12:05:56 [Warning] Forcing shutdown of 2 plugins
090403 12:05:56 [Note] /usr/libexec/mysqld: Shutdown complete
090403 12:05:56 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid
090403 12:05:57 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
/usr/libexec/mysqld: Table 'mysql.plugin' doesn't exist
090403 12:05:57 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
090403 12:05:58 InnoDB: Started; log sequence number 0 43665
090403 12:05:58 [ERROR] Can't open and lock privilege tables: Table 'mysql.servers' doesn't exist
090403 12:05:58 [ERROR] Column count of mysql.db is wrong. Expected 22, found 20. Created with MySQL 50045, now running 50132. Please use mysql_upgrade to fix this error.
090403 12:05:58 [ERROR] mysql.user has no `Event_priv` column at position 29
090403 12:05:58 [ERROR] Cannot open mysql.event
090403 12:05:58 [ERROR] Event Scheduler: An error occurred when initializing system tables. Disabling the Event Scheduler.
090403 12:05:58 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.1.32' socket: '/var/lib/mysql/mysql.sock
I tried running mysql_update, but I'm getting this:
Looking for 'mysql' as: mysql
Looking for 'mysqlcheck' as: mysqlcheck
Running 'mysqlcheck'...
mysqlcheck: Got error: 1045: Access denied for user 'root'@'localhost' (using password: NO) when trying to connect
FATAL ERROR: Upgrade failed
Is there a way to specify a password when running mysql_upgrade? From the man page this doesn't seem to be the case.
I've sucessfully run mysql_update (thanks dmonzon), and there are no longer any errors appearing in the log, just the warning 'Forcing shutdown of 2 plugins'.
Now I'm getting a different error:
#1607 - Cannot create stored routine `calcResTotals`. Check warnings
Running
SHOW WARNINGS;
from the command line as the same user and using the same database returns an empty result set. Is this the correct way to view warnings?
I've been trying to create the procedure from phpMyAdmin, but also from the command line and from a php script. They all produce the same result.
Referencing this issue:
http://www.experts-exchang
I've attempted setting sql_mode = '' both in the my.cnf file and directly from the command line. Still no joy.
I'm thinking this issue must pertain to my initial installation of the PHP/MySQL package. I did this using the remi repository, following the guide at:
http://timt881.wordpress.c
Has any one else had success using this repository and/or PHP 5.2.9 with stored routines?
Business Accounts
Answer for Membership
by: gawaiPosted on 2009-03-28 at 13:00:14ID: 24009895
check if there is something in Error log