High Performance Computing Group

 View Only
  • 1.  Selecting host model - correct syntax

    Posted Mon June 27, 2022 06:55 AM
    Hi,
    I am confused about the "correct" syntax for the model parameter in the select[...] resources string. 
    As the requirement (according to the documentation) is, that everything should evaluate as a logical expression, I would assume that "select[ model == hostmodel]" is the correct syntax!  However, in the configuration file we got from IBM support, and have been using happily for years(!), we see this: "select[model = hostmodel]" (this is in the RES_REQ section of a queue in lsb.queues).  
    What is correct: "model == ..." or "model = ..."?  Is there a difference, or are they treated the same (undocumented feature)?  If the single "=" is not correct, why does it still work? 

    Regards, Bernd



    ------------------------------
    Bernd Dammann
    ------------------------------

    #SpectrumComputingGroup


  • 2.  RE: Selecting host model - correct syntax

    Posted Mon June 27, 2022 11:13 AM
    It should be "model=something", e.g. bsub -R "model=Intel_E5"  or bsub -R "model!=Intel_E5". The model value of a host should be displayed in lshosts output.

    ------------------------------
    YI SUN
    ------------------------------



  • 3.  RE: Selecting host model - correct syntax

    Posted Tue June 28, 2022 04:28 AM
    Thanks!   The single "=" seems to work, but it still conflicts with the documentation, where the examples with  "model" are using "==", e.g. like in "model == local" (see https://www.ibm.com/docs/en/spectrum-lsf/10.1.0?topic=strings-selection-string).  Furthermore, on the same page, in the section "Operators", only "==" is mentioned! 

    When I test with bsub, both versions do the correct host selection, i.e. both 'bsub -R "model=Intel_E5"' and 'bsub -R "model==Intel_E5"' get dispatched to the host model Intel_E5.

    ------------------------------
    Bernd Dammann
    ------------------------------