Announcement

Collapse
No announcement yet.

Vray DR -> Disable Backburner scripts

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Vray DR -> Disable Backburner scripts

    I think i requested a unified network rendering/distributed rendering solution for a number of times.
    Finally have time to script something that kind of works.

    This script basically check what DR servers are selected, then crosscheck with the backburner server list. Then it sets schedules for the dr servers to be unavailable.
    You essentially need two scripts, one to disable servers on the Pre-Render Script, and one to disable for the Post-Render script.

    Disabling services with PSTools via shell doesn't seem to be that efficient, so that was abandoned.
    Can implement for Deadline if people are interested.

    Let me know if it works in your environments as well.


    Code:
    /*
    Disable/Enable Backburner for DR
    Copyright Ivor Ip 2012
    */
    
    --1. Find dr list
    dr_servers = #()
    bb_servers = #()
    dr_list = (dotNetClass "System.IO.File").ReadAllLines ((getDir #plugcfg)+"\\vray_dr.cfg")
    for i = 1 to (dr_list.count - 3) do(
    	l = filterstring dr_list[i] " "
    	if l[2] == "1" then(
    		append dr_servers l[1]
    	)	
    )
    --2. Find BB server list, replace "rendermanagername with your server.
    m = netrender.getmanager() 
    m.connect #manual "rendermanagername"
    bb_servers = m.getservers()
    m.getcontrol()
    m.setupdates false
    
    --3. X-check servers and set schedule
    for i in bb_servers do (
    		sched = i.schedule
    		for j = 1 to 7 do(
    			for k = 1 to 24 do(
    				sched[j][k]=false
                                     --Set above to True for enable servers
    			)
    		)
    		
    		if (finditem dr_servers i.name) != 0 then (	
    			i.schedule = sched
    			i.SendUpdate()
    		)
    	
    )
    m.setupdates true
    Last edited by IVOR_IP; 24-07-2012, 12:35 PM.

  • #2
    We coded a small external tool that allows you to query the state of a particular DR server (i.e. idle or working) - perhaps it can tie into this as well.

    Best regards,
    Vlado
    I only act like I know everything, Rogers.

    Comment


    • #3
      That tool sounds interesting Vlado, I've wanted to automate the process of getting DR blades for a while, I want to write something similar for Deadline.
      Maxscript made easy....
      davewortley.wordpress.com
      Follow me here:
      facebook.com/MaxMadeEasy

      If you don't MaxScript, then have a look at my blog and learn how easy and powerful it can be.

      Comment


      • #4
        Vlado,

        Would be great if this tool can check the various vray dr platforms as well(rhino, maya, max, etc.)

        Ivor

        Comment


        • #5
          Originally posted by IVOR_IP View Post
          Would be great if this tool can check the various vray dr platforms as well(rhino, maya, max, etc.)
          It should work fine for all of them, but only for relatively recent builds.

          Best regards,
          Vlado
          I only act like I know everything, Rogers.

          Comment


          • #6
            Hey Vlado, Can we have access to this tool ?

            Thanks
            3LP Team

            Comment


            • #7
              Yes, you can now find the vraydr_check tool at the bottom of the V-Ray tools page here: http://www.spot3d.com/vray/misc/

              Best regards,
              Vlado
              I only act like I know everything, Rogers.

              Comment

              Working...
              X