There's also the very useful Python hostlist package for translating
from this format and back to it.

On Wed, Feb 1, 2012 at 9:11 AM, Sergey Linev <s.li...@gsi.de> wrote:
> Thanks for the good tip!
>
>
> On 01.02.2012 17:28, Moe Jette wrote:
>>
>> The scontrol command has options to translate:
>>
>> $ scontrol show hostlist tux1,tux3,tux4
>> tux[1,3-4]
>> $ scontrol show hostnames tux[1,3-4]
>> tux1
>> tux3
>> tux4
>>
>>
>> Quoting Sergey Linev <s.li...@gsi.de>:
>>
>>> Hi,
>>>
>>> When running batch job, two variables defines number and list of
>>> nodes, where job should be run: SLURM_JOB_NUM_NODES and
>>> SLURM_JOB_NODELIST.
>>>
>>> Is there easy way (shell command) to extract node name for every node,
>>> listed in SLURM_JOB_NODELIST?
>>>
>>> With best regards,
>>> Sergey
>>>
>>> --
>>>
>>> Dr. Sergey Linev,
>>> GSI Helmholtzzentrum für Schwerionenforschung GmbH
>>>
>>
>>
>>
>

Reply via email to