linux

How to truncate Job Queue (or other tables) in MySQL for MythTV

I’ve been running mythtv for awhile and I thought I had transcoding/commercial flags turned off, but I guess not. I’ve seen my ‘Job Queue’ jobs creeping up over time when looking at my ‘Backend Status’ via MythWeb.

Decided to write down how to fix this. Keep in mind this ‘fix’ forcibly removes all the jobs queued up from mythtv, so don’t run this unless you want all those jobs INSTANTLY gone!

In my case, that’s exactly what I wanted. 🙂

Run the following from a shell.

mysql -u mythtv -p -e "USE mythconverg; TRUNCATE Table jobqueue;"

This runs the mysql client using the mythtv user (prompting for password due to -p) and executing the sql command which selects the mythconverg database and clearing out all records in the jobqueue table.