MySQL "Procedure does not exist" failures

We migrated our servers from RHEL 6 running Percona MySQL 5.5.35 to RHEL 7 running Percona MySQL 8.0.26. On our RHEL 7 servers we are seeing 10 to 30 warnings per day in our application logs similar to the following message:

2022-02-24 22:15:09,763 w 140041653294:MySQLCommand::HandleException: Executing cmd="", error=“PROCEDURE … does not exist”. queryTime=1ms, timeout=20, connected=1, disconnects=51, p=CC2A4CB0.
2022-02-24 22:15:09,791 w 140041653294:MySQLCommand::Attempt: After previous failure, success on attempt (2) while executing cmd="". disconnects=51, p=CC2A4CB0.

On our legacy RHEL 6 stack running Percona 5.5.35 we seldom saw this error. Our procedures are defined and never changing. We call procedures around 500 times per second.

Questions:
Why are we getting occasional “Procedure does not exist” failures?
What can be done to address the root cause of the occasional “Procedure does not exist” failures?

How exactly did you migrate from MySQL 5.5 to MySQL 8? You cannot simply uninstall 5.5 and install 8. You must follow the upgrade paths as laid out in the documentation. MySQL 8 introduced a data dictionary which is where stored procedures are located. Perhaps this action failed during your upgrade.

1 Like

Hey, thanks for the reply. We did not upgrade in place or try to migrate the existing DB files between versions. We are starting new servers with RHEL 7 (fresh install) and Percona 8.0.26 (we did not attempt to convert MySQL 5.5.7 to 8.0.26) and the numbers of entries in the tables grow as we add users and data to the server. The errors don’t seem load dependent as they happen at all hours of the day and night and our servers get more load during working hours.

1 Like

Have you tried SHOW CREATE PROCEDURE to even see if it exists?

1 Like

It succeeds on a retry. See log message below:

2022-02-24 22:15:09,763 w 140041653294:MySQLCommand::HandleException: Executing cmd="", error=“PROCEDURE … does not exist”. queryTime=1ms, timeout=20, connected=1, disconnects=51, p=CC2A4CB0.
2022-02-24 22:15:09,791 w 140041653294:MySQLCommand::Attempt: After previous failure, success on attempt (2) while executing cmd="". disconnects=51, p=CC2A4CB0.

1 Like

Any one have any thoughts as why we are seeing a “Procedure does not exist error” on the initial call but succeeds on a retry? These are procs in our schema.

1 Like