Sunday, May 20, 2012

BackBurner Renders Autokill about 60minutes

This is extracted from Mayastation - I am going to start using Backburner 2012 soon but this is something I keep forgetting and I can't be bothered to test so I will continue punching in this command and changing the number to 360 minutes.

BackBurner renders fail after 60 minutes - Part 1

Have you noticed your BackBurner jobs failing for no specific reason after 60 minutes?  Well, There is a simple explanation for this.  BackBurner has a default timeout function set to it.  After 60 minutes if the the frame or task is not completed BackBurner will send a kill signal to the job and restart.

If you are noticing this on your renders, there is a simple solution to get around it.  While there is no timeout option in the BackBurner submission window.  You can set a timeout flag manually by clicking the "Use Custom Command" box and then clicking the "Populate Command" button at the bottom of the Submission Window.  This will build a long command to be sent to BackBurner and begin the job.

This is where we need to add the -timeout flag.  Below is an example of the entire command with the timeout value set to 120 minutes. I generally set this after the manager flag.

system ("\"/usr/discreet/backburner/cmdjob\" -jobName \"exp_support_ash025444-110215\" -description \"\" -manager -timeout 120 -priority 50 -taskList \"/usr/tmp/exp_support_ash025444-110215.txt\" -taskName 1 \"/usr/autodesk/maya2011.5-x64/bin/Render\" -r file -s %tp2 -e %tp3 -proj \"/home/assist/maya/projects/default\" -rd \"/home/assist/maya/projects/default/images\" \"/Lnx-ubuntu/public/CustomerCases/renderash/exp_support_ash.ma\"")

 Hope this helps with any of your future renders!

BackBurner renders fail after 60 minutes - Part 2

I thought of revisiting the BackBurner timeout situation after a few customers mentioned that the need to manually enter the timeout was slightly annoying.
Since any permanent changes would need to be done by our development team. I thought It would be best to share a more permanent approach to get the timeout set.
Now setting this does involve editing the performExportToBackburner.mel file which support team does not generally recommend but editing these file.  Please make a local backup of the file before editing it.

We can simply add  an extra line of code to force the timeout to be a new permanent value. Since we are editing this at the file level you will no longer need to populate the command manually when submitting the job.

So, this is what has to be done.

1. Go to: C:\Program Files\Autodesk\Maya 2012\scripts\others
2. locate the file called performExportToBackburner.mel and make a backup of this file.
3. Now open the original file in word pad and locate the the following line.

"// Prepare the list of tasks and send it to Backburner through a task list file"

4. A few lines below that I add a new line.  The new line is in bold below.

// Prepare the list of tasks and send it to Backburner through a task list file
int $startFrame = `intFieldGrp -q -v1 bbExportStartFrameCtl`;
int $endFrame = `intFieldGrp -q -v1 bbExportEndFrameCtl`;
int $taskSize = `intFieldGrp -q -v1 bbExportTaskSizeCtl`;
if( $taskSize < 1) $taskSize = 1;
string $taskListFileName = createTaskListFile($jobName, $startFrame, $endFrame, $taskSize);
if($taskListFileName != "")
{
$exportSysCmd = $exportSysCmd + " -timeout 360 ";
}

5. Save the file.  Launch Maya and submit job and the new task timeout will be set to 360 minutes by default for every job.

Hope this helps the folks out there struggling with the timeout in BackBurner.