OAR Syntax simplification
In order to ease the reservation of resources with OAR (using oarsub or the job API), Grid'5000 provides the following mechanisms to simplify the oarsub filters (which otherwise use a regular SQL syntax to select resources):
- An alias system to translate simple and short keywords to the OAR resource filter expressions (which are often long and complex).
- The automatic addition of simple quotes for strings (quote still required for text including spaces) in the expressions (e.g. in
cluster='yeti'
orib=EDR
quotes are not mandatory) - The use of short names of nodes instead of the long names which include the grid5000.fr domain name.
- The use of
&
alternatively toand
;|
alternatively toor
in OAR resource filter expressions
Usage
Aliases
Aliases are defined for the most common resources, for instance, to ease clusters selection, GPUs, etc. Aliases do not replace the classical way of using the OAR properties. Some of the aliases are site-specific (e.g. cluster and node names).
Aliases must be used within the classical oarsub
options: -l
and -p
.
Here some examples:
- Request a node with an SSD
Which is equivalent using the regular SQL syntax to:
- Request a node with a GTX 1080 Ti Nvidia GPU
Which is equivalent using the regular SQL syntax to:
- Request 2 nodes with an SSD and 256G or more RAM
Which is equivalent using the regular SQL syntax to:
- Request a node on grimoire cluster with all its disks
Which is equivalent using the regular SQL syntax to:
- Aliases can be mixed with the classical way of requesting resources
Which is equivalent using the regular SQL syntax to:
Long node names completion
The automatic completion of short hostnames to add the domain name can be used when filtering with the host
property:
- For one host
Or even without the quotes:
Or since we provide aliases for each node host property, the following also works:
All 3 are equivalent using the regular SQL syntax to:
- For multiple host within an IN()
Which is equivalent using the regular SQL syntax to:
frontend :
|
oarsub -I -p "host IN ('yeti-1.grenoble.grid5000.fr', 'yeti-2.grenoble.grid5000.fr', 'yeti-3.grenoble.grid5000.fr')" |
Disabling the syntax simplification
If for any reason you want to disable the syntax simplification in order to just use the OAR regular syntax, it is possible by using the no-syntax-simplifier
job type, as follows:
Available aliases
Clusters and nodes
%d
is a digit representing a node's number.
Disks
Alias | Description | Translate to |
---|---|---|
ssd | Select node(s) with SSD | disktype like '%/SSD'
|
hdd | Select node(s) with HDD | disktype like '%/HDD'
|
host+disk | Select node(s) with all its reservable disks | (type='default' or type='disk')
|
disk | Select reservable disk(s) | type='disk'
|
GPUs
Alias | Description | Translate to |
---|---|---|
no-gpu | Select node(s) without any GPU | gpu_count = 0
|
gpu | Select node(s) with a GPU | gpu_count >= 1
|
rtx2080ti | Select node(s) with GeForce RTX 2080 Ti GPU | gpu_model='GeForce RTX 2080 Ti'
|
gtx1080ti | Select node(s) with GeForce GTX 1080 Ti GPU | gpu_model='GeForce GTX 1080 Ti'
|
p100-pcie-16 | Select node(s) with Tesla P100-PCIE-16GB GPU | gpu_model='Tesla P100-PCIE-16GB'
|
p100-sxm2-16 | Select node(s) with Tesla P100-SXM2-16GB GPU | gpu_model='Tesla P100-SXM2-16GB'
|
v100-pcie-32 | Select node(s) with Tesla V100-PCIE-32GB GPU | gpu_model='Tesla V100-PCIE-32GB'
|
v100-sxm2-32 | Select node(s) with Tesla V100-SXM2-32GB GPU | gpu_model='Tesla V100-SXM2-32GB'
|
m2075 | Select node(s) with Tesla M2075 GPU | gpu_model='Tesla M2075'
|
gtx980 | Select node(s) with GeForce GTX 980 GPU | gpu_model='GeForce GTX 980'
|
k40m | Select node(s) with Tesla K40m GPU | gpu_model='Tesla K40m'
|
k80 | Select node(s) with Tesla K80 GPU | gpu_model='Tesla K80'
|
l40s | Select node(s) with L40S GPU | gpu_model='L40S'
|
m40 | Select node(s) with Tesla M40 GPU | gpu_model='Tesla M40'
|
t4 | Select node(s) with Tesla T4 GPU | gpu_model='Tesla T4'
|
a100-pcie-40 | Select node(s) with A100-PCIE-40GB GPU | gpu_model='A100-PCIE-40GB'
|
a100-sxm4-40 | Select node(s) with A100-SXM4-40GB GPU | gpu_model='A100-SXM4-40GB'
|
a40 | Select node(s) with A40 GPU | gpu_model='A40'
|
a5000 | Select node(s) with RTX A5000 GPU | gpu_model='RTX A5000'
|
p6000 | Select node(s) with Quadro P6000 GPU | gpu_model='Quadro P6000'
|
rtx6000 | Select node(s) with Quadro RTX 6000 GPU | gpu_model='Quadro RTX 6000'
|
rtx8000 | Select node(s) with Quadro RTX 8000 GPU | gpu_model='Quadro RTX 8000'
|
mi50-32 | Select node(s) with Radeon Instinct MI50 32GB GPU | gpu_model='Radeon Instinct MI50 32GB'
|
agx-xavier | Select node(s) with AGX Xavier GPU | gpu_model='AGX Xavier'
|
gpu-6GB | Select node(s) with GPU having more than 6GB of memory | gpu_mem>=6000
|
gpu-12GB | Select node(s) with GPU having more than 12GB of memory | gpu_mem>=12000
|
gpu-16GB | Select node(s) with GPU having more than 16GB of memory | gpu_mem>=16000
|
gpu-24GB | Select node(s) with GPU having more than 24GB of memory | gpu_mem>=24000
|
gpu-32GB | Select node(s) with GPU having more than 32GB of memory | gpu_mem>=32000
|
gpu-40GB | Select node(s) with GPU having more than 40GB of memory | gpu_mem>=40000
|
gpu-60GB | Select node(s) with GPU having more than 60GB of memory | gpu_mem>=60000
|
Memory
Alias | Description | Translate to |
---|---|---|
24GB | Select node(s) with 24GB RAM or more | memnode>=24576
|
32GB | Select node(s) with 32GB RAM or more | memnode>=32768
|
48GB | Select node(s) with 48GB RAM or more | memnode>=49152
|
64GB | Select node(s) with 64GB RAM or more | memnode>=65536
|
96GB | Select node(s) with 96GB RAM or more | memnode>=98304
|
128GB | Select node(s) with 128GB RAM or more | memnode>=131072
|
192GB | Select node(s) with 192GB RAM or more | memnode>=196608
|
256GB | Select node(s) with 256GB RAM or more | memnode>=262144
|
384GB | Select node(s) with 384GB RAM or more | memnode>=393216
|
512GB | Select node(s) with 512GB RAM or more | memnode>=524288
|
768GB | Select node(s) with 768GB RAM or more | memnode>=786432
|
1024GB | Select node(s) with 1024GB RAM or more | memnode>=1048576
|
Vlans
Alias | Description | Translate to |
---|---|---|
kavlan | Select routed VLAN(s) | type='kavlan'
|
kavlan-local | Select local VLAN(s) | type='kavlan-local'
|
kavlan-global | Select global VLAN(s) | type='kavlan-global'
|