[GE users] Assigning custom complex attributes values to hosts

emallove ethan.mallove at sun.com
Wed Aug 12 20:26:51 BST 2009


On Wed, Aug/12/2009 11:02:39AM, templedf wrote:
> Ugh. That got pretty mangled. Let me try that again...
> 
> #!/bin/sh
> for host in `qhost | tail +4`; do
>     distro=`ssh $host uname -s`
>     qconf -aattr exechost complex_values os_distro=$distro $host
>     ssh $host ls /path/to/compilers
>     [ $? -ne 0 ]
>     cc_avail=$?
>     qconf -aattr exechost complex_values compilers_available=$cc_avail $host
> done

Exactly what I needed. Thanks for the scripty!

-Ethan

> 
> 
> Daniel
> 
> templedf wrote:
> > Off the top of my head...
> >
> > #!/bin/sh
> > for host in `qhost | tail +4`; do
> > qconf -aattr exechost complex_values os_distro=`ssh $host uname -s` $host
> > ssh $host ls /path/to/compilers
> > [ $? -ne 0 ]
> > compilers_available=$?
> > qconf -aattr exechost complex_values 
> > compilers_available=$compilers_available $host
> > done
> >
> > Daniel
> >
> > emallove wrote:
> >   
> >> Hi,
> >>
> >> I added a couple custom complex attributes via "qconf -mc": 
> >>
> >>   $ qconf -sc global
> >>   #name                  shortcut    type        relop requestable consumable default  urgency
> >>   #--------------------------------------------------------------------------------------------
> >>   ...
> >>   compilers_available    compiler    RESTRING    ==    YES         NO         NONE     0
> >>   os_distro              distro      RESTRING    ==    YES         NO         NONE     0
> >>   ...
> >>
> >> I want to be able to qsub a script, and have it run, e.g., on a
> >> RedHat5 host which has the PGI compilers available:
> >>
> >>   $ qsub -l os_distro=redhat5 -l compilers_available=pgi foo.sh
> >>
> >> How do I set my user-defined complex attributes for each host in my
> >> cluster?
> >>
> >> -Ethan
> >>
> >> ------------------------------------------------------
> >> http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=212029
> >>
> >> To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].
> >>
> >>     
> >
> > ------------------------------------------------------
> > http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=212030
> >
> > To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].
> >
> 
> ------------------------------------------------------
> http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=212034
> 
> To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].

------------------------------------------------------
http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=212043

To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].



More information about the gridengine-users mailing list