PDA

View Full Version : Backburner Cmdjob learnings


actionsketch
09-15-2011, 11:18 PM
so, I've recently needed to use the new-ish backburner cmdjob command line tool... and I ran into all sorts of fun problems that I had to solve my self because I couldn't find answers online. I write this hoping that it will be crawled by google and help out fellow cmdjob users in the future =)

error code 2: this is a file not found error
error code 193: I don't know what you would call this error, but I got rid of it by adding a "exit 0" to the end of the .bat file I was executing.


now, if you look at the cmdjob manual... this is the syntax it suggests for declaring dependencies:
-dependencies:<jobName>;<jobName>;...

there are two things wrong with this... the word "jobname" and the delimiter. It should be rewritten to say:

-dependencies:<jobHandle>,<jobHandle>,...


I hope this helps someone!

katisss
02-20-2012, 01:41 AM
How do you get the handle for a job you submit in first place?

PiXeL_MoNKeY
02-20-2012, 02:04 AM
Use the netrender interface and call .handle on the job as documented here (http://docs.autodesk.com/3DSMAX/14/ENU/MAXScript%20Help%202012/files/GUID-DEF2CDBF-C729-46B9-BC0D-F030E255E3A-631.htm). Example:mngr = netrender.getManager()
mngr.connect #automatic "255.255.255.0"
jobs = mngr.getJobs()
for job in jobs do (
format "%: (Handle) %: (Handle Hex) %\n" job.name (job.handle as string) (bit.intAsHex job.handle)
)
-Eric

EDIT: .handle returns an integer value, while the data returned to the monitor is a hex value. Added the bit.intAsHex command to verify the value returned with what is shown in the Monitor. I believe that the cmdjob items expect the integer value.

katisss
02-20-2012, 02:12 AM
I am in maya/composite. This is maxscript?
Is there a commad line version?

PiXeL_MoNKeY
02-20-2012, 02:16 AM
Yes, sorry you are asking in a 3ds max forum so expected you to be using it as you didn't note that in your question.

-Eric

PiXeL_MoNKeY
02-20-2012, 02:24 AM
I am in maya/composite. This is maxscript?
Is there a commad line version?You could try digging through the python code posted here (http://forums.cgsociety.org/showpost.php?p=5384316&postcount=201).

-Eric

katisss
02-20-2012, 02:55 AM
Thanks, looks useful. Is this the standard way to set dependencies?
I was hoping for cmdjob to return an id when staring the job really...

PiXeL_MoNKeY
02-20-2012, 03:10 AM
AFAIK, backburner doesn't give access to a way to get information about a job. cmdjob is for job submission only, it isn't designed to return any information about existing jobs. From the Backburner help:The Backburner command-job utility, cmdjob, lets you submit batch, executable or script files to Backburner as "custom" jobs from the command line, for execution on render nodes.So you will have to use general scripting or host application access to get the information you want about existing jobs.

-Eric

katisss
02-20-2012, 04:12 AM
hi,
helpful for getting the jobid but then i was expecting to be able to use -dependencies flag to set it when submitting a new job. Somehow i wont let me.


C:\Users\katisss>cmdjob -progress -manager "katisss-pc" -dependencies:"62DA236E"
-jobname "bla2" "txrender.exe" -p "C:/Users/katisss/Desktop/project/CompositeTes
t_v002.txcomposition" -s 1 -userfilepath -o "Output" -v CompositeTest_v002.txc
omposition -c "C:/Users/katisss/Desktop/project/CompositeTest_v002.txcomposition"

Cannot set job info: Unknown job: '62DA236E'

PiXeL_MoNKeY
02-20-2012, 04:42 AM
You need to convert the Hex value to Integer. You could try something like this (http://stackoverflow.com/questions/209513/convert-hex-string-to-int-in-python).

-Eric

katisss
02-20-2012, 05:03 AM
much better. Thanks for getting me started.

chib
08-14-2012, 03:34 PM
now, if you look at the cmdjob manual... this is the syntax it suggests for declaring dependencies:
-dependencies:<jobName>;<jobName>;...

there are two things wrong with this... the word "jobname" and the delimiter. It should be rewritten to say:

-dependencies:<jobHandle>,<jobHandle>,...


Thank you very much!!
Actually, dependencies:<jobName>;<jobName>;... used to work with BB 2009...

Paul.

CGTalk Moderation
08-14-2012, 03:34 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.