User avatar
By gtalarico
#379148
I have a network setup that requires me to specify the manager's ip when opening Monitor because they are in different subnets:
mxnetwork.exe -monitor:managerip

Is there a way to do this when running the NetworkRender/Monitor Launch from the SU plugin?
Could there be an advanced optional input the the plugin settings for arguments?
By JDHill
#379153
There are settings for this, but they are accessed via Ruby, and need to be documented; you can open the Ruby console and type things like:
Code: Select all
MX::Settings.start_manager='prompt'
MX::Settings.bind_monitor_to='192.168.0.1'
MX::Settings.start_node='yes'
MX::Settings.bind_node_to='some_machine'
These are persistent from session to session, so you don't need to set them repeatedly. So, besides binding to a particular IP, you can also entirely disable the starting of a node or manager on the local machine (or be prompted to make the choice at the time you click the Network Render button).
User avatar
By gtalarico
#379157
Thanks JD. That makes sense.

To be able to deploy this to multiple computers, could this code just be added to a SetMangerRBfile.rb?

Would just the code you posted work, or would the .rb require other things...?
I don't know ruby, but I could use another simple plugin as a starting point.
By JDHill
#379158
There could be an alternate approach, based on overwriting methods in the plugin to return different values. Let me play with this for a bit and I'll let you know what I come up with.
By JDHill
#379161
Please try this and let me know if it gets you where you'd like to be:
  • 1. Create a file named maxwell.mod.env.rb in your Plugins folder.
    2. Inside, put this script:
    Code: Select all
    require "maxwell.rb"
    module MX
      module Env
        def Env.should_start_node?
          return true
        end    
        def Env.should_start_manager? 
          return true
        end    
        def Env.node_flag
          return '-node:192.168.0.1'
        end    
        def Env.monitor_flag
          return '-monitor:192.168.0.1'
        end
      end # Env
    end # MX
When you start the plugin, this code will overwrite the existing corresponding plugin methods, making the plugin use what you specify here to start the network components, rather than what it otherwise would have figured. In other words, it will not matter whether you'd set anything using MX::Settings as described above, since the code here doesn't use them, and just directly returns whatever you want, which means that to undo this, you literally need to delete this new .rb file.

With the file installed, if you then open the Ruby console as you export to the network (with Options > Ruby Echo enabled), you will see how the values you specify in the code above are incorporated, as the plugin builds a command line to start the network executable (for debugging any potential issue).

Hey, I guess maxwell is not going to be updates a[…]

Help with swimming pool water

Hi Choo Chee. Thanks for posting. I have used re[…]