• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
The Electric Toolbox Blog

The Electric Toolbox Blog

Linux, Apache, Nginx, MySQL, Javascript and PHP articles

  • Applications
  • FCKEditor
  • Apache
  • Windows
  • Contact Us
Home / Cannot load from mysql.proc. The table is probably corrupted

Cannot load from mysql.proc. The table is probably corrupted

I mistyped the name of an internal MySQL function in some code this morning and got back the error message "Cannot load from mysql.proc. The table is probably corrupted" which appeared to have no bearing on the actual error. The simple fix to this problem is to run the mysql_upgrade command.

mysql_upgrade

From the command line (you won’t be able to do this from a tool like phpMyAdmin) run the command line tool mysql_upgrade passing like so:

mysql_upgrade -u root -p

Then enter the root’s password and it will check all the databases and tables and fix them where appropriate. You may need to specify the full path to the above command if it’s not in the shell’s search path.

On Debian 6 it’s at /usr/bin/mysql_upgrade

On Mac MAMP /Applications/MAMP/Library/bin/mysql_upgrade

On Windows it’ll be where-ever MySQL is installed in the bin subdirectory. You’ll need to open up the command prompt, change to that directory and then run mysql_upgrade.exe -u root -p

Now that I’d upgraded the databases I got a much better error message which was related to the error I’d created: "FUNCTION [dbname].[function name] does not exist"

Disclaimer

Before running a command like this on a production server, it’s always a good idea to take a full backup of all databases first, just in case something goes wrong.

Check Out These Related posts:

  1. mysql_upgrade relocation error
  2. MySQL utility commands
  3. How to mount an ISO image on Linux
  4. Copy a table in MySQL with CREATE TABLE LIKE

Filed Under: MySql

Primary Sidebar

Categories

  • Apache
  • Applications
  • Article
  • Case Studies
  • Email Servers
  • FCKEditor
  • HTML And CSS
  • Javascript
  • Linux/Unix/BSD
  • Microsoft SQL Server
  • Miscellaneous Postings
  • MySql
  • Networking
  • Nginx Web Server
  • Offsite Articles
  • OSX
  • PHP
  • Quick Tips
  • RFC – Request for Comments
  • SilverStripe
  • VMWare
  • VPN
  • Windows
  • WordPress

Recent Posts

  • Vim Show Line Numbers
  • Add User To Group Linux
  • Chmod 777 Tutorial
  • How to Copy Directory Linux
  • Linux create user

Copyright © 2021. ElectricToolBox. All Rights Reserved.

  • Contact Us
  • Copyright Info
  • Privacy Policy
  • Sitemap