My MySQL instance in a slave node (set up to sync with a master node via replication) is showing this error when queried via SHOW SLAVE STATUS\G:

Error 1304: PROCEDURE mydb.SOMEPROC does not exist' on query. Default database: 'mydb'. Query: 'INSERT INTO mydb.sometable (fooID, someColumn, ...) VALUES ('12376', 'somevalue', ...)

What can cause this error? Replication has been runnning fine for weeks. I don't understand. (When I set up replication, back in the day, I remembered to specify the --routines flag when executing the mysqldump to transfer the data from the master node to the slave node.)

NB: This database has some triggers that execute when some things are inserted in some tables, which result probably in execution of some stored procedures. However, as far as I understand, triggers should not be executed in the slave node (because if they did, then slave node would suddenly have different data than the master node, right?). And anyway this stored procedure should not be missing, I don't understand.

Thanks

  • Triggers won't execute on the slave if you are using the default row-based replication. Are any other sprocs missing or just this one? Does seem odd why it would be calling a sproc on an insert. – topshot Aug 3 '16 at 13:29
  • Are you using ROW? Does SOMEPROC exist on the slave? Show us the TRIGGER(s) involved. Etc. – Rick James Aug 3 '16 at 19:02
  • SOMEPROC in fact doesn't exist, and I don't know why, is it possible that it gets deleted if you mess around with the mysql.proc table? – user1623521 Aug 4 '16 at 8:54

Your Answer

 
discard

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.