ORBIT-USER: How to use ruby fiile containing deftopology command?
Arinto Murdopo
arinto at gmail.com
Sun Feb 11 05:53:11 EST 2007
Just now I found it, I should make my own repository folder then put my ruby
script there. Please correct me if I'm wrong.. Thank you very much :D
regards,
arinto
On 2/11/07, Arinto Murdopo <arinto at gmail.com> wrote:
>
> Dear all,
>
> How to use the ruby file containing the defTopology command? Do I need to
> put the file in opt/nodehandler-4.1.2/repository/system/topo/ ?
> Or I just use nodehandler4 command to running this script? When I use
> nodehandler4, the process stopped at INFO Experiment: load clickSampleTopo
>
> arinto at console.grid:~/VirtualMobility/OtherScript$ nodehandler4
> clickSampleTopo
> Using logfile /etc/nodehandler/nodehandler_log.xml
> DEBUG oconfig: Testbed name: 'grid'
> INFO init: NodeHandler Version 4.1.2 (1272)
> INFO init: Experiment ID: grid_2007_02_11_05_37_18
> INFO ExecApp: Starting application 'commServer': /opt/nodehandler- 4.1.2/sbin/commServer
> --iface eth1 -l /tmp/commServer-grid_2007_02_11_05_37_18.log
> INFO Experiment: load system:exp:stdlib
> INFO prop.resetDelay: resetDelay = 180:Fixnum
> INFO prop.resetTries: resetTries = 1:Fixnum
> INFO Experiment: load clickSampleTopo
>
> Thank you
>
> arinto
> On 10/26/06, Max Ott < max at semandex.net> wrote:
> >
> > Cute (or not), the message which is trying to tell you that your
> > topology definition is not correct is throwing an exception.
> >
> > I fixed that, so please try again. It still won't work for your
> > definition, but it should give you a more meaningful error message,
> > something along the lines of:
> >
> > Expected array with 2 elements denoting x and y, but found [1..20]
> >
> > Please verify that indeed you get that.
> >
> > Now to fix the problem, your topology definition should look like:
> >
> > defTopology('my:topo:grid', [1..20,1..20])
> >
> > Also see
> >
> > /opt/nodehandler-4.1.2/repository/system/topo/all.rb
> >
> > which means, you will achieve the same using 'system:topo:all'.
> >
> > -max
> >
> >
> > On 10/26/06, Vanessa Frias-martinez < vf2001 at cs.columbia.edu> wrote:
> > >
> > > when running Max's imageNodes4 i get an error in some rb files...
> > >
> > > Imaging nodes: 'my:topo:grid' with image
> > > 'tmp/node-1-2-2006-10-19-18-52-55.ndz '
> > > WARN: init'-s flag' flag is depreciated, use '-k' instead
> > > Using logfile /etc/nodehandler/nodehandler_log.xml
> > > DEBUG oconfig: Testbed name: 'grid'
> > > INFO init: NodeHandler Version 4.1.2 (1272)
> > > INFO init: Experiment ID: grid_2006_10_25_10_43_12
> > > INFO ExecApp: Starting application 'commServer':
> > > /opt/nodehandler-4.1.2/sbin/commServer --iface eth1 -l
> > > /tmp/commServer-grid_2006_10_25_10_43_12.log
> > > INFO Experiment: load system:exp:stdlib
> > > INFO prop.resetDelay: resetDelay = 180:Fixnum
> > > INFO prop.resetTries: resetTries = 1:Fixnum
> > > INFO Experiment: load system:exp:imageNode
> > > INFO prop.nodes: nodes = "my:topo:grid":String
> > > INFO prop.image: image = "tmp/node-1-2-2006-10-19-18-52-55.ndz
> > ":String
> > > INFO prop.pxe: pxe = "1.2.0":String
> > > INFO Topology: Loading topology 'my:topo:grid'.
> > > FATAL run: Exception: undefined local variable or method `n' for
> > > #<Topology:0xa796e9c8> (NameError)
> > > /opt/nodehandler-4.1.2/lib/handler/topology.rb:164:in
> > `addNodes'
> > > /opt/nodehandler- 4.1.2/lib/handler/topology.rb:185:in
> > `addNodes'
> > > /opt/nodehandler-4.1.2/lib/handler/topology.rb:184:in `each'
> > > /opt/nodehandler-4.1.2/lib/handler/topology.rb:184:in
> > `addNodes'
> > > /opt/nodehandler-4.1.2/lib/handler/topology.rb:145:in `add'
> > > /opt/nodehandler-4.1.2/lib/handler/topology.rb:128:in
> > `initialize'
> > > /opt/nodehandler-4.1.2/lib/handler/topology.rb:46:in `new'
> > > /opt/nodehandler-4.1.2/lib/handler/topology.rb:46:in `create'
> > > /opt/nodehandler-4.1.2/lib/handler/handlerCommands.rb:28:in
> > > `defTopology'
> > > ./my_topo_grid.rb:1
> > > (eval):20:in `require'
> > > (eval):20:in `getProc'
> > > /opt/nodehandler-4.1.2/lib/handler/oconfig.rb:132:in `call'
> > > /opt/nodehandler-4.1.2/lib/handler/oconfig.rb:132:in `load'
> > > /opt/nodehandler-4.1.2/lib/handler/topology.rb:22:in `[]'
> > > /opt/nodehandler-4.1.2/lib/handler/handlerCommands.rb:66:in
> > > `defNodes'
> > > /opt/nodehandler-4.1.2/repository/system/exp/imageNode.rb:13
> > > (eval):20:in `require'
> > > (eval):20:in `getProc'
> > > /opt/nodehandler-4.1.2/lib/handler/oconfig.rb:132:in `call'
> > > /opt/nodehandler-4.1.2/lib/handler/oconfig.rb:132:in `load'
> > > /opt/nodehandler-4.1.2/lib/handler/experiment.rb:38:in `load'
> > > /opt/nodehandler-4.1.2/app/nodeHandler.rb:179:in `run'
> > > /opt/nodehandler-4.1.2/app/nodeHandler.rb:622
> > > INFO ExecApp: Application 'commServer' finished
> > > INFO run: Experiment grid_2006_10_25_10_43_12 finished after 0:8
> > > vanessa at console.grid:~
> > >
> > > On Wed, 25 Oct 2006, Haris Kremo wrote:
> > >
> > > > Vanessa,
> > > >
> > > > Below is a message from Max about more robust way of imaging the
> > nodes.
> > > >
> > > > Hope it helps,
> > > >
> > > > H.
> > > >
> > > > ---------- Forwarded message ----------
> > > > From: Max Ott <max at winlab.rutgers.edu>
> > > > Date: Oct 7, 2006 9:34 PM
> > > > Subject: ORBIT-USER: Improved imaging procedures
> > > > To: orbit-user at winlab.rutgers.edu
> > > >
> > > >
> > > > Folks,
> > > >
> > > > I installed a new version of the nodehandler with which I now
> > > > regularly image the entire grid (or better the approx. 385 nodes
> > which
> > > > boot up properly) in about 16 minutes with almost half of the time
> > > > spent coaxing the nodes to boot up.
> > > >
> > > > As I haven't tested much more than just imaging and also haven't
> > > > installed the new agent on anything but the PXE image, the old
> > > > nodehandler is still there and the new one is called 'nodehandler4'.
> > > >
> > > > Similarly, the new imaging command is called 'imageNodes4'
> > > >
> > > > $ imageNodes4 -h
> > > > Usage: /usr/bin/imageNodes4 [topology] [image_file_path]
> > > > Example:
> > > > /usr/bin/imageNodes4 system:topo:all tmp/image-
> > tridencom-test.ndz
> > > >
> > > > It takes two optional arguments, a topology and the image name.
> > > >
> > > > Right now, 'topology' is just a fancy way for defining the list of
> > > > nodes to use, but will in the future include ways to define the
> > > > additional noise injection settings to get us closer to a real
> > > > topology.
> > > >
> > > > There is a new command 'defTopology' (http://tinyurl.com/pcqo8 )
> > which
> > > > is almost identical to the way 'defNodes' defines the list of nodes.
> > A
> > > > topology can be saved in its own file and referenced from a defNodes
> > > > command.
> > > >
> > > > For instance, the repository contains a topology containing all
> > nodes
> > > > in the grid. It's URI is 'system:topo:all' and is simply defined as:
> > > >
> > > > defTopology('system:topo:all', [1 .. OConfig['X_MAX'], 1 ..
> > OConfig['Y_MAX']])
> > > >
> > > > Now let's assume you want to use two opposing corner nodes and we
> > hard
> > > > code the grid size to 20x20 (not that I would ever condone hard
> > > > coding). Create a file 'my_topo_diagonal.rb' and add the following
> > > > line:
> > > >
> > > > defTopology('my:topo:diagonal', [[1,1],[20,20]])
> > > >
> > > > Now, you can image those nodes with your image through:
> > > >
> > > > $ imageNodes4 my:topo:diagonal my_image.ndz
> > > >
> > > > The 'defNodes' command in the new nodehandler will accept a topology
> > > > URI as the second argument (selector), but we'll announce that when
> > we
> > > > fully switch over.
> > > >
> > > > Also, please don't use a block with the 'defTopology' command. I
> > > > realized last night that the installed version doesn't properly
> > > > support that - and I don't want to install the fix without testing
> > it
> > > > - not sure when that will happen. In other words, the fancy 'circle'
> > > > example in the wiki page doesn't work, yet. The normal array
> > > > definitions do work, though.
> > > >
> > > > There is still the odd node which sometimes goes deaf during imaging
> > > > and the current imaging script doesn't detect that and as a result
> > > > won't finish, but it happens much less frequently than before and I
> > > > only saw it for > 350 nodes. Hopefully, your experience is similar.
> > > >
> > > > Finally, please note that the default topology behavior is
> > > > 'non-strict', meaning the nodehandler will remove a node from a
> > > > topology or node set if the node doesn't check in after one
> > additional
> > > > reboot. The nodehandler will print a warning message but will then
> > > > continue.
> > > >
> > > > So please check if the nodes skipped are important to you.
> > > >
> > > > WARN Giving up on node n_19_6
> > > >
> > > > Let me know if you have problems and I'll look into it. Don't forget
> > > > to add the experiment ID to any bug report.
> > > >
> > > > Thanks,
> > > >
> > > > -max
> > > >
> > >
> >
> >
> > --
> > Dr. Max Ott
> > Research Program Leader - Network and Pervasive Computing, NICTA
> > Australia
> > Founder & CTO, Semandex Networks
> > Research Professor, WINLAB, Rutgers University
> >
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://orbit-lab.org/pipermail/orbit-user/attachments/20070211/1caabea4/attachment.htm
More information about the orbit-user
mailing list