Issues running user transcode Handbrake script

Have a MythTV related problem? Ask for help from other MythTV users here.

Moderator: Forum Moderators

Post Reply
compmania
Newcomer
Posts: 2
Joined: Wed Mar 05, 2014 5:39 am
United States of America

Issues running user transcode Handbrake script

Post by compmania »

I just updated my system from the latest Mythbuntu (running 0.24 release) to Ubuntu 13.10 with the 0.27 release.

When I was running Mythbuntu, I ran a slightly modified version of this Handbrake script (http://tech.surveypoint.com/blog/mythtv ... handbrake/) as a user transcode on all my recordings. Once done, it would copy to a network enabled Western Digital My Book Live for access by a PS3 and iPad.

After updating my system to Ubuntu 13.10, I've been able to get everything back up and running (mythbackend, mythfrontend, mythweb) except that my user transcode script will not run correctly for some reason. Things I have done:

* Ensured the mp4_transcode.sh file is owned by and grouped for the mythtv user
* Ensured the mp4_transcode.sh file is executable, allows read/write access, and is located in a directory that is owned by and grouped for the mythtv user
* Ensured HandbrakeCLI and Handbrake-gtk are both installed
* Ensured my settings are correct to run the script (/Video/mp4_transcode.sh "%CHANID%" "%STARTTIME%")
* Ensured the script runs find outside of Mythtv (./mp4_transcode.sh #### ############, per the .mpg filename in the recording directory)
* Ensured my My Book Live is properly mounted to the correct directory for use by the script
* Scoured various forums for answers before posting here...

What happens both in Mythweb and Mythbackend is that the transcode job begins, then almost immediately ends and shows a status of "Finished" without actually doing anything. It doesn't error at all, it just sits at Queued for about a minute then changes to Finished.

Any ideas? I'm surprised that the script was working fine before, doesn't work now, but does work if I manually initialize it from the command line.

Thanks in advance!
User avatar
bill6502
Developer
Posts: 2372
Joined: Fri Feb 07, 2014 5:28 pm
United States of America

Re: Issues running user transcode Handbrake script

Post by bill6502 »

Ensured my settings are correct to run the script (/Video/mp4_transcode.sh "%CHANID%" "%STARTTIME%")
Upgrading from 0.24 to 0.27 means that you've now got the UTC changes done in 0.26, so you likely want %STARTTIMEUTC%.

See: http://www.mythtv.org/wiki/Release_Note ... structions (esp. the 4th bullet) and http://www.mythtv.org/wiki/User_Jobs.
compmania
Newcomer
Posts: 2
Joined: Wed Mar 05, 2014 5:39 am
United States of America

Re: Issues running user transcode Handbrake script

Post by compmania »

That solved it. I didn't think to check the change log, I figured it was a problem with my install/configuration. Thanks so much!
User avatar
rwagner
Developer
Posts: 217
Joined: Thu Feb 06, 2014 11:37 pm
United States of America

Re: Issues running user transcode Handbrake script

Post by rwagner »

It's a problem with your script. CHANID and STARTTIME should be considered internal MythTV values. The only reason to need those passed to a script is because the script is interfacing with the Services API or database. If the script is interfacing with the database, it should be performing a schema check, and refusing to operate if the database it is accessing is newer or older than it understands.
Kwisher
Junior
Posts: 58
Joined: Fri Sep 25, 2015 3:02 pm
United States of America

Re: Issues running user transcode Handbrake script

Post by Kwisher »

I'm having issues getting this same script the OP is using to work. I've made sure the mythtv user has read/write permissions to the script and all /paths I've modified from the original. The userjob is calling the script only, no options as the original blogpost noted.

My modified script can be seen here: http://dpaste.com/146YRSC

TIA
Post Reply