Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Document <backbone> and cosmetics in the platform doc
[simgrid.git] / docs / source / XML_reference.rst
1 .. raw:: html
2
3    <object id="TOC" data="graphical-toc.svg" type="image/svg+xml"></object>
4    <script>
5    window.onload=function() { // Wait for the SVG to be loaded before changing it
6      var elem=document.querySelector("#TOC").contentDocument.getElementById("ReferenceBox")
7      elem.style="opacity:0.93999999;fill:#ff0000;fill-opacity:0.1;stroke:#000000;stroke-width:0.35277778;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1";
8    }
9    </script>
10    <br/>
11    <br/>
12
13 .. _platform_reference:
14
15 Complete XML Reference
16 **********************
17
18 Your platform description should follow the specification presented in the
19 `simgrid.dtd <https://simgrid.org/simgrid.dtd>`_ DTD file. The same DTD is used for both platform and deployment files.
20
21 Here is the complete list of all existing tags in the DTD:
22
23 :ref:`pf_tag_actor`: request the creation of an actor (deployment file, not in the platform). |br|
24 :ref:`pf_tag_argument`: pass parameters to the created actors (deployment file, not in the platform). |br|
25 :ref:`pf_tag_backbone`: building clusters manually from the XML (deprecated, please use the C++ API). |br|
26 :ref:`pf_tag_bypassRoute`: tweeking the routing (advanced tag). |br|
27 :ref:`pf_tag_bypassZoneRoute`: tweeking the routing (expert-only tag). |br|
28 :ref:`pf_tag_cabinet`: building clusters manually from the XML (deprecated, please use the C++ API). |br|
29 :ref:`pf_tag_config`: pass simulation parameters from the XML file. |br|
30 :ref:`pf_tag_disk`: storage resource. |br|
31 :ref:`pf_tag_host`: computing resource. |br|
32 :ref:`pf_tag_link`: communication resource. |br|
33 :ref:`pf_tag_link_ctn`: name of a link to be included in a route. |br|
34 :ref:`pf_tag_peer`: host located in a :ref:`pf_rm_vivaldi` zone. |br|
35 :ref:`pf_tag_platform`: root tag of any platform description. |br|
36 :ref:`pf_tag_prop`: attach used-defined properties to your :ref:`pf_tag_actor`, :ref:`pf_tag_disk`, :ref:`pf_tag_host`, :ref:`pf_tag_link` or :ref:`pf_tag_zone`. |br|
37 :ref:`pf_tag_route`: intra-zone network path. |br|
38 :ref:`pf_tag_router`: like an :ref:`pf_tag_host` that cannot host actors (for network routing algorithms). |br|
39 :ref:`pf_tag_zone`: area of the network containing elements (:ref:`pf_tag_disk`, :ref:`pf_tag_host`, :ref:`pf_tag_link` and sub-:ref:`pf_tag_zone`). |br|
40 :ref:`pf_tag_zoneRoute`: inter-zone network path.
41
42 .. TODO::
43
44    Missing tags: <host_link>
45
46 -------------------------------------------------------------------------------
47
48 .. _pf_tag_cluster:
49
50 <cluster>
51 ---------
52
53 This complex tag builds a full zone, with some hosts, links, a router, and the relevant routing algorithm. There is several
54 kind of specifically tailored cluster types: crossbar clusters (contention-free internal network), backbone clusters
55 (constrained internal network), fat-trees, DragonFly and Torus (star clusters are similar, but can only be created from the
56 C++ code). The ``topology`` attribute is used to choose the type of cluster while the ``topo_parameters`` attribute is used
57 to configure the topology. Please refer to the  :ref:`examples in the documentation <platform_examples>` for all details.
58
59 Regardless of its topology, each cluster comes with a router that can be used for inter-zone routing. Its name is defined
60 as ``${prefix}${clusterId}_router${suffix}``.
61
62 **Parent tags:** :ref:`pf_tag_platform`, :ref:`pf_tag_zone` |br|
63 **Children tags:** none |br|
64 **Attributes:**
65
66 :``id``: The identifier of the cluster. Facilitates referring to this cluster.
67 :``prefix``: Each node of the cluster has to have a name. This name will be prefixed with this prefix.
68 :``suffix``: Each node of the cluster will be suffixed with this suffix
69 :``radical``: Regexp used to generate cluster nodes name.
70
71     Syntax: "10-20" will give you 11 machines numbered from 10 to 20, "10-20;2" will give you 12 machines, one with the number 2, others numbered as before.
72
73     The produced number is concatenated between prefix and suffix to form machine names.
74 :``speed``: Same as the ``speed`` attribute of the :ref:`pf_tag_host` tag.
75 :``core``: Same as the ``core`` attribute of the :ref:`pf_tag_host` tag.
76 :``bw``: Bandwidth for the links between nodes and backbone (if any). See :ref:`pf_tag_link` for syntax/details.
77 :``lat``: Latency for the links between nodes and backbone (if any). See :ref:`pf_tag_link` for syntax/details.
78 :``sharing_policy``: Sharing policy for the links between nodes and backbone (if any). See :ref:`pf_tag_link` for syntax/details.
79 :``bb_bw``: Bandwidth for backbone (if any). See :ref:`pf_tag_link` for syntax/details.
80
81     If bb_bw and bb_lat attributes are omitted, no backbone is created (alternative cluster architecture described earlier).
82 :``bb_lat``: Latency for backbone (if any). See :ref:`pf_tag_link` section for syntax/details.
83
84     If bb_lat and bb_bw attributes are omitted, no backbone is created (alternative cluster architecture described earlier).
85 :``bb_sharing_policy``: Sharing policy for the backbone (if any). See :ref:`pf_tag_link` section for syntax/details.
86 :``limiter_link``: Bandwidth for limiter link (if any).
87
88     This adds a specific link for each node, to set the maximum bandwidth reached when communicating in both directions at the same time.
89
90     In theory this value should be 2*bw for splitduplex links, but in reality this might be less. This value will depend heavily on the communication model, and on the cluster's hardware, so no default value can be set, this has to be measured.
91
92     More details can be obtained in `Toward Better Simulation of MPI Applications on Ethernet/TCP Networks <https://hal.inria.fr/hal-00919507/>`_
93 :``loopback_bw``: Bandwidth for loopback (if any). See :ref:`pf_tag_link` section for syntax/details.
94
95     If loopback_bw and loopback_lat attributes are omitted, no loopback link is created and all intra-node communication will use the main network link of the node.
96
97     The sharing policy of a loopback link is **FATPIPE** :ref:`pf_tag_link`.
98 :``loopback_lat``: Latency for loopback (if any). See loopback_bw for more info.
99 :``topology``: Network topology to use.
100
101     SimGrid currently supports FLAT (with or without backbone, as described before), TORUS, FAT_TREE and DRAGONFLY attributes for this tag.
102
103     See :ref:`platform_examples` for more details.
104
105 :``topo_parameters``: Specific parameters to pass for the topology defined in the topology tag.
106
107     For torus networks, comma-separated list of the number of nodes in each dimension of the torus.
108
109     Please refer to :ref:`platform_examples`.
110
111 -------------------------------------------------------------------------------
112
113 .. _pf_tag_config:
114
115 <config>
116 --------
117
118 Adding configuration flags directly into the platform file becomes particularly
119 useful when the realism of the described platform depends on some specific
120 flags. For example, this could help you to finely tune SMPI. Almost all
121 :ref:`command-line configuration items <options_list>` can be configured this
122 way.
123
124 Each configuration flag is described as a :ref:`pf_tag_prop` whose ``id`` is the
125 name of the flag and ``value`` is what it has to be set to.
126
127 **Parent tags:** :ref:`pf_tag_platform` (must appear before any other tags) |br|
128 **Children tags:** :ref:`pf_tag_prop` |br|
129 **Attributes:** none
130
131 .. code-block:: xml
132
133    <?xml version = '1.0'?>
134    <!DOCTYPE platform SYSTEM "https://simgrid.org/simgrid.dtd">
135    <platform version = "4.1">
136      <config>
137        <prop id = "maxmin/precision" value = "0.000010" />
138        <prop id = "cpu/optim" value = "TI" />
139        <prop id = "network/model" value = "SMPI" />
140        <prop id = "smpi/bw-factor" value = "65472:0.940694;15424:0.697866;9376:0.58729" />
141      </config>
142
143      <!-- The rest of your platform -->
144    </platform>
145
146 -------------------------------------------------------------------------------
147
148 .. _pf_tag_disk:
149
150 <disk>
151 ------
152
153 SimGrid can simulate the time it takes to read or write data on disk, even if the stored data is not made persistent in
154 any way by SimGrid. This means that your application will correctly be slowed down when doing simulated I/O, but there
155 is no way to get the data stored this way.
156
157 We decided to not model anything beyond raw access in SimGrid because we believe that there is not single way of doing so.
158 We provide an example model of file system as a plugin, (sparsely) documented in :ref:`plugin_filesystem`.
159
160 **Parent tags:** :ref:`pf_tag_host` |br|
161 **Children tags:** :ref:`pf_tag_prop` |br|
162 **Attributes:**
163
164 :``id``: A name of your choice (must be unique on this host).
165 :``read_bw``: Read bandwidth for this disk. You must specify a unit as follows.
166
167    **Units in bytes and powers of 2** (1 KiBps = 1,024 Bps):
168      Bps, KiBps, MiBps, GiBps, TiBps, PiBps, or EiBps. |br|
169    **Units in bits  and powers of 2** (1 Bps = 8 bps):
170      bps, Kibps, Mibps, Gibps, Tibps, Pibps, or Eibps. |br|
171    **Units in bytes and powers of 10**  (1 KBps = 1,000 Bps):
172      Bps, KBps, MBps, GBps, TBps, PBps, or EBps. |br|
173    **Units in bits  and powers of 10:**
174      bps, Kbps, Mbps, Gbps, Tbps, Pbps, or Ebps.
175
176 :``write_bw``: Write bandwidth for this disk. You must specify a unit as for the read bandwidth.
177
178 .. code-block:: xml
179
180     <host id="alice" speed="1Gf">
181       <disk id="Disk1" read_bw="200MBps" write_bw="80MBps">
182         <!-- you can add properties for anything you want: they are not used by SimGrid -->
183         <prop id="content" value="storage/content/small_content.txt"/>
184       </disk>
185       <prop id="ram" value="100B" />
186     </host>
187
188 -------------------------------------------------------------------------------
189
190 .. _pf_tag_host:
191
192 <host>
193 ------
194
195 A host is the computing resource on which an actor can run. See :cpp:class:`simgrid::s4u::Host`.
196
197 **Parent tags:** :ref:`pf_tag_zone` (only leaf zones, i.e., zones containing neither inner zones nor clusters) |br|
198 **Children tags:** :ref:`pf_tag_mount`, :ref:`pf_tag_prop`, :ref:`pf_tag_disk` |br|
199 **Attributes:**
200
201 :``id``: Host name.
202    Must be unique over the whole platform.
203 :``speed``: Computational power (per core, in flop/s).
204    If you use DVFS, provide a comma-separated list of values for each pstate (see :ref:`howto_dvfs`).
205 :``core``: Amount of cores (default: 1).
206    See :ref:`howto_multicore`.
207 :``availability_file``:
208    File containing the availability profile.
209    Almost every lines of such files describe timed events as ``date ratio``.
210    Example:
211
212    .. code-block:: python
213
214       1 0.5
215       2 0.2
216       5 1
217       LOOPAFTER 5
218
219    - At time t = 1, half of the host computational power (0.5 means 50%) is used to process some background load, hence
220      only 50% of this initial power remains available to your own simulation.
221    - At time t = 2, the available power drops at 20% of the initial value.
222    - At time t = 5, the host can compute at full speed again.
223    - At time t = 10, the profile is reset (as we are 5 seconds after the last event). Then the available speed will drop
224      again to 50% at time t = 11.
225
226    If your profile does not contain any LOOPAFTER line, then it will
227    be executed only once and not repeated.
228
229    .. warning:: Don't get fooled: Bandwidth and Latency profiles of a :ref:`pf_tag_link` contain absolute values, while
230       Availability profiles of a :ref:`pf_tag_host` contain ratios.
231 :``state_file``: File containing the state profile.
232    Almost every lines of such files describe timed events as ``date boolean``.
233    Example:
234
235    .. code-block:: python
236
237       1 0
238       2 1
239       LOOPAFTER 8
240
241    - At time t = 1, the host is turned off (a zero value means OFF)
242    - At time t = 2, the host is turned back on (any other value than zero means ON)
243    - At time t = 10, the profile is reset (as we are 8 seconds after the last event). Then the host will be turned off
244      again at time t = 11.
245
246    If your profile does not contain any LOOPAFTER line, then it will
247    be executed only once and not repeated.
248
249 :``coordinates``: Vivaldi coordinates (meaningful for Vivaldi zones only).
250    See :ref:`pf_tag_peer`.
251 :``pstate``: Initial pstate (default: 0, the first one).
252    See :ref:`howto_dvfs`.
253
254 -------------------------------------------------------------------------------
255
256 .. _pf_tag_link:
257
258 <link>
259 ------
260
261 SimGrid links usually represent one-hop network connections (see :cpp:class:`simgrid::s4u::Link`), i.e., a single wire.
262 They can also be used to abstract a larger network interconnect, e.g., the entire transcontinental network, into a
263 single element. Links are characterized by their bandwidth and latency, and their sharing is realistic wrt TCP connexions.
264 Another unusual point is that SimGrid links can be used to connect more than two elements, just like
265 hyperlinks in an `hypergraph <https://en.wikipedia.org/wiki/Hypergraph>`_.
266
267 **Parent tags:** :ref:`pf_tag_zone` (both leaf zones and inner zones) |br|
268 **Children tags:** :ref:`pf_tag_prop` |br|
269 **Attributes:**
270
271 :``id``:  Link name. Must be unique over the whole platform.
272 :``bandwidth``: Maximum bandwidth for this link. You must specify a unit as follows.
273
274    **Units in bytes and powers of 2** (1 KiBps = 1,024 Bps):
275      Bps, KiBps, MiBps, GiBps, TiBps, PiBps, or EiBps. |br|
276    **Units in bits  and powers of 2** (1 Bps = 8 bps):
277      bps, Kibps, Mibps, Gibps, Tibps, Pibps, or Eibps. |br|
278    **Units in bytes and powers of 10**  (1 KBps = 1,000 Bps):
279      Bps, KBps, MBps, GBps, TBps, PBps, or EBps. |br|
280    **Units in bits  and powers of 10:**
281      bps, Kbps, Mbps, Gbps, Tbps, Pbps, or Ebps.
282
283 :``latency``: Latency for this link (default: 0.0). You must specify a unit as follows.
284
285    ==== =========== ======================
286    Unit Meaning     Duration in seconds
287    ==== =========== ======================
288    ps   picosecond  10⁻¹² = 0.000000000001
289    ns   nanosecond  10⁻⁹ = 0.000000001
290    us   microsecond 10⁻⁶ = 0.000001
291    ms   millisecond 10⁻³ = 0.001
292    s    second      1
293    m    minute      60
294    h    hour        60 * 60
295    d    day         60 * 60 * 24
296    w    week        60 * 60 * 24 * 7
297    ==== =========== ======================
298
299 :``sharing_policy``: Sharing policy for the link. Possible values are ``SHARED``, ``FATPIPE`` or ``SPLITDUPLEX``
300    (default: ``SPLITDUPLEX``).
301
302    If set to ``SPLITDUPLEX``, the link models the full-duplex
303    behavior, as meant in TCP or UDP. To that extend, the link is
304    actually split in two links whose names are suffixed with "_UP" and
305    "_DOWN". You should then specify the direction to use when
306    referring to that link in a :ref:`pf_tag_link_ctn`.
307
308    If set to ``FATPIPE``, flows have no impact on each other, hence
309    each flow can exploit the full bandwidth. This models Internet
310    backbones that cannot get saturated by your application. From your
311    application point of view, there is no congestion on these
312    backbones.
313
314    If set to ``SHARED``, the available bandwidth is fairly shared
315    among ALL flows traversing this link. The resulting link is not
316    full-duplex (as UDP or TCP would be): communications in both
317    directions share the same link. Prefer ``SPLITDUPLEX`` for TCP flows.
318
319 :``bandwidth_file``: File containing the bandwidth profile.
320    Almost every lines of such files describe timed events as ``date
321    bandwidth`` (in bytes per second).
322    Example:
323
324    .. code-block:: python
325
326       4.0 40000000
327       8.0 60000000
328       LOOPAFTER 12.0
329
330    - At time t = 4, the bandwidth is of 40 MBps.
331    - At time t = 8, it raises to 60MBps.
332    - At time t = 24, it drops at 40 MBps again.
333
334    If your profile does not contain any LOOPAFTER line, then it will
335    be executed only once and not repeated.
336
337    .. warning:: Don't get fooled: Bandwidth and Latency profiles of a :ref:`pf_tag_link` contain absolute values, while
338       Availability profiles of a :ref:`pf_tag_host` contain ratios.
339
340 :``latency_file``: File containing the latency profile.
341    Almost every lines of such files describe timed events as ``date
342    latency`` (in seconds).
343    Example:
344
345    .. code-block:: python
346
347       1.0 0.001
348       3.0 0.1
349       LOOPAFTER 5.0
350
351    - At time t = 1, the latency is of 1ms (0.001 second)
352    - At time t = 3, the latency is of 100ms (0.1 second)
353    - At time t = 8 (5 seconds after the last event), the profile loops.
354    - At time t = 9 (1 second after the loop reset), the latency is back at 1ms.
355
356    If your profile does not contain any LOOPAFTER line, then it will
357    be executed only once and not repeated.
358
359   .. warning:: Don't get fooled: Bandwidth and Latency profiles of a :ref:`pf_tag_link` contain absolute values, while
360       Availability profiles of a :ref:`pf_tag_host` contain ratios.
361
362 :``state_file``: File containing the state profile. See :ref:`pf_tag_host`.
363
364 -------------------------------------------------------------------------------
365
366 .. _pf_tag_link_ctn:
367
368 <link_ctn>
369 ----------
370
371 An element in a route, representing a previously defined link.
372
373 **Parent tags:** :ref:`pf_tag_route` |br|
374 **Children tags:** none |br|
375 **Attributes:**
376
377 :``id``: Link that is to be included in this route.
378 :``direction``: either ``UP`` (by default) or ``DOWN``, specifying whether to
379                 use the uplink or downlink component of the link (that must
380                 follow the ``SPLITDUPLEX`` sharing policy). |br|
381                 Please refer to the ``sharing_policy`` attribute in
382                 :ref:`pf_tag_link`.
383
384 -------------------------------------------------------------------------------
385
386 .. _pf_tag_peer:
387
388 <peer>
389 ------
390
391 This tag represents a peer, as in Peer-to-Peer (P2P) networks. It is
392 handy to model situations where hosts have an asymmetric
393 connectivity. Computers connected through set-top-boxes usually have a
394 much better download rate than their upload rate.  To model this,
395 <peer> creates and connects several elements: a host, an upload link
396 and a download link.
397
398 **Parent tags:** :ref:`pf_tag_zone` (only with Vivaldi routing) |br|
399 **Children tags:** none |br|
400 **Attributes:**
401
402 :``id``: Name of the host. Must be unique on the whole platform.
403 :``speed``: Computational power (in flop/s).
404
405    If you use DVFS, provide a comma-separated list of values for each pstate (see :ref:`howto_dvfs`).
406 :``bw_in``: Bandwidth of the private downstream link, along with its
407             unit. See :ref:`pf_tag_link`.
408 :``bw_out``: Bandwidth of the private upstream link, along with its
409              unit. See :ref:`pf_tag_link`.
410 :``lat``: Latency of both private links. See :ref:`pf_tag_link`.
411 :``coordinates``: Coordinates of the gateway for this peer.
412
413    The communication latency between a host A = (xA,yA,zA) and a host B = (xB,yB,zB) is computed as follows:
414
415    latency = sqrt( (xA-xB)² + (yA-yB)² ) + zA + zB
416
417    See the documentation of
418    :cpp:class:`simgrid::kernel::routing::VivaldiZone` for details on
419    how the latency is computed from the coordinates, and on how the up
420    and down bandwidth are used.
421 :``availability_file``: File containing the availability profile.
422    See the full description in :ref:`pf_tag_host`
423 :``state_file``: File containing the state profile.
424    See the full description in :ref:`pf_tag_host`
425
426 -------------------------------------------------------------------------------
427
428 .. _pf_tag_platform:
429
430 <platform>
431 ----------
432
433 **Parent tags:** none (this is the root tag of every file) |br|
434 **Children tags:** :ref:`pf_tag_config` (must come first),
435 :ref:`pf_tag_cluster`, :ref:`pf_tag_cabinet`, :ref:`pf_tag_peer`,
436 :ref:`pf_tag_zone`, :ref:`pf_tag_trace`, :ref:`pf_tag_trace_connect`, or
437 :ref:`pf_tag_actor` in :ref:`deployment <deploy>` files. |br|
438 **Attributes:**
439
440 :``version``: Version of the DTD, describing the whole XML format.
441               This versioning allow future evolutions, even if we
442               avoid backward-incompatible changes. The current version
443               is **4.1**. The ``simgrid_update_xml`` program can
444               upgrade most of the past platform files to the most recent
445               formalism.
446
447 -------------------------------------------------------------------------------
448
449 .. _pf_tag_prop:
450
451 <prop>
452 ------
453
454 This tag can be used to attach user-defined properties to some
455 platform elements. Both the name and the value can be any string of
456 your wish. You can use this to pass extra parameters to your code and
457 the plugins.
458
459 From your code, you can interact with these properties using the
460 following functions:
461
462 - Actor: :cpp:func:`simgrid::s4u::Actor::get_property` or :cpp:func:`MSG_process_get_property_value`
463 - Cluster: this is a zone, see below.
464 - Disk: :cpp:func:`simgrid::s4u::Disk::get_property`
465 - Host: :cpp:func:`simgrid::s4u::Host::get_property` or :cpp:func:`MSG_host_get_property_value`
466 - Link: :cpp:func:`simgrid::s4u::Link::get_property`
467 - Zone: :cpp:func:`simgrid::s4u::NetZone::get_property` of :cpp:func:`MSG_zone_get_property_value`
468
469 **Parent tags:** :ref:`pf_tag_actor`, :ref:`pf_tag_config`, :ref:`pf_tag_cluster`, :ref:`pf_tag_host`,
470 :ref:`pf_tag_link`, :ref:`pf_tag_disk`,:ref:`pf_tag_zone` |br|
471 **Children tags:** none |br|
472 **Attributes:**
473
474 :``id``: Name of the defined property.
475 :``value``: Value of the defined property.
476
477 -------------------------------------------------------------------------------
478
479 .. _pf_tag_route:
480
481 <route>
482 -------
483
484 A path between two network locations, composed of several occurrences of :ref:`pf_tag_link`. It is only relevant for
485 intra-:ref:`pf_tag_zone` routes. Inter-zone routes must be declared with :ref:`pf_tag_zoneRoute`. More detail can be
486 found in the following sections :ref:`pf_routes` and :ref:`pf_route_usage`.
487
488 **Parent tags:** :ref:`pf_tag_zone` |br|
489 **Children tags:** :ref:`pf_tag_link_ctn` |br|
490 **Attributes:**
491
492 :``src``: Host from which this route starts. Must be the name of an existing host.
493 :``dst``: Host to which this route leads. Must be the name of an existing host.
494 :``symmetrical``: Whether this route is symmetrical, ie, whether we
495                   are defining the route ``dst -> src`` at the same
496                   time. Valid values: ``yes``, ``no``, ``YES``, ``NO``
497                   (default: YES).
498
499 -------------------------------------------------------------------------------
500
501 .. _pf_tag_router:
502
503 <router>
504 --------
505
506 A router is similar to a :ref:`pf_tag_host`, but it cannot contain any actor. It is only useful to some routing
507 algorithms. In particular, they are useful when you want to use the NS3 bindings to break the routes that are longer
508 than 1 hop.
509
510 **Parent tags:** :ref:`pf_tag_zone` (only leaf zones, i.e., zones containing neither inner zones nor clusters) |br|
511 **Attributes:**
512
513 :``id``: Router name.
514    No other host or router may have the same name over the whole platform.
515 :``coordinates``: Vivaldi coordinates. See :ref:`pf_tag_peer`.
516
517 -------------------------------------------------------------------------------
518
519 .. _pf_tag_zone:
520
521 <zone>
522 ------
523
524 A networking zone is an area in which elements are located. See :cpp:class:`simgrid::s4u::NetZone`.
525
526 **Parent tags:** :ref:`pf_tag_platform`, :ref:`pf_tag_zone` (only internal nodes, i.e., zones
527 containing only inner zones or clusters but no basic
528 elements such as host or peer) |br|
529 **Children tags (if internal zone):** :ref:`pf_tag_cluster`, :ref:`pf_tag_link`, :ref:`pf_tag_zone` |br|
530 **Children tags (if leaf zone):** :ref:`pf_tag_host`, :ref:`pf_tag_link`, :ref:`pf_tag_peer` |br|
531 **Attributes:**
532
533 :``id``: Zone name.
534    No other zone may have the same name over the whole platform.
535 :``routing``: Routing algorithm to use.
536
537 -------------------------------------------------------------------------------
538
539 .. _pf_tag_zoneRoute:
540
541 <zoneRoute>
542 -----------
543
544 All information to factorize the routes between two zones; intra-zone paths must be declared with :ref:`pf_tag_route`.
545 Since zones form a tree, :ref:`pf_tag_zoneRoute` is probably best used to connect sibling zones.
546
547 When declaring a zoneRoute, you must give the source and destination zones, along with the gateway in each zone (i.e.,
548 the point to reach within that zone to reach the declared route), and the list of links to go from one zone to another.
549 More detail can be found in the following sections :ref:`pf_routes` and :ref:`pf_route_usage`.
550
551 **Parent tags:** :ref:`pf_tag_zone` |br|
552 **Children tags:** :ref:`pf_tag_link_ctn` |br|
553 **Attributes:**
554
555 :``src``: Zone from which this route starts. Must be an existing zone.
556 :``dst``: Zone to which this route leads. Must be an existing zone.
557 :``gw_src``: Netpoint (within src zone) from which this route starts. Must be an existing host/router.
558 :``gw_dst``: Netpoint (within dst zone) to which this route leads. Must be an existing host/router.
559 :``symmetrical``: Whether this route is symmetrical, ie, whether we are defining the route ``dst -> src`` at the same
560                   time. Valid values: ``yes``, ``no``, ``YES``, ``NO``. 
561
562 -------------------------------------------------------------------------------
563
564 Advanced tags
565 -------------
566
567 The following list contains some tags that are less often used. They are still valid, but unless you know what you are
568 doing, there is a good chance that you don't really want to use them.
569
570
571 -------------------------------------------------------------------------------
572
573 .. _pf_tag_bypassRoute:
574
575 <bypassRoute>
576 ^^^^^^^^^^^^^
577
578 This tag can be used to completely bypass the classical :ref:`routing algorithm <pf_route_usage>` for a pair of hosts. The
579 provided list of links will be used directly, with no further routing computation. This is an advanced tag that is rarely
580 used in practice.
581
582 **Parent tags:** :ref:`pf_tag_zone` |br|
583 **Children tags:** :ref:`pf_tag_link_ctn` |br|
584 **Attributes:**
585
586 :``src``: Host from which this route starts. Must be the name of an existing host.
587 :``dst``: Host to which this route leads. Must be the name of an existing host.
588 :``symmetrical``: Whether this route is symmetrical, ie, whether we are defining the route ``dst -> src`` at the same time.
589                   Valid values: ``yes``, ``no``, ``YES``, ``NO`` (default: YES).
590
591 -------------------------------------------------------------------------------
592
593 .. _pf_tag_bypassZoneRoute:
594
595 <bypassZoneRoute>
596 ^^^^^^^^^^^^^^^^^
597
598 This tag can be used to completely bypass the classical :ref:`routing algorithm <pf_route_usage>` between two zones. When
599 provided, it breaks the recursive search and the provided links will be used instead. This tag should probably be reserved
600 to experts.
601
602 **Parent tags:** :ref:`pf_tag_zone` |br|
603 **Children tags:** :ref:`pf_tag_link_ctn` |br|
604 **Attributes:**
605
606 :``src``: Zone from which this route starts. Must be an existing zone.
607 :``dst``: Zone to which this route leads. Must be an existing zone.
608 :``gw_src``: Netpoint (within src zone) from which this route starts. Must be an existing host/router.
609 :``gw_dst``: Netpoint (within dst zone) to which this route leads. Must be an existing host/router.
610 :``symmetrical``: Whether this route is symmetrical, ie, whether we are defining the route ``dst -> src`` at the same
611                   time. Valid values: ``yes``, ``no``, ``YES``, ``NO``. 
612
613 .. _pf_tag_backbone:
614
615 <backbone>
616 ^^^^^^^^^
617
618 Within a manually-built cluster, specify the backbone to use. See the documentation of :ref:`pf_tag_cabinet` for all
619 details, even if you should probably stop using this tag and switch to the C++ interface.
620
621 **Parent tags:** :ref:`pf_tag_zone` with ``routing="Cluster"`` attribute |br|
622 **Children tags:** none |br|
623 **Attributes:**
624
625 :``id``: No other link in the platform shall have the same identifier.
626 :``bw``: Bandwidth, see the :ref:`pf_tag_link` for syntax/details.
627 :``lat``: Latency, see the :ref:`pf_tag_link` for syntax/details.
628
629 -------------------------------------------------------------------------------
630
631 .. _pf_tag_cabinet:
632
633 <cabinet>
634 ^^^^^^^^^
635
636 The cabinet tag is a shortcut for creating a set of (homogenous) hosts and links quickly, as in cabinets of data centers.
637 This is mostly useful when manually describing a cluster, i.e. a ``<zone routing="Cluster">`` where you manually specify
638 the content with :ref:`pf_tag_cabinet`, :ref:`pf_tag_backbone` and maybe :ref:`pf_tag_host_link`.
639
640 But this approach is somewhat deprecated now, as the C++ interface is both more convinient and more powerful. For example,
641 the core amount or link characteristics cannot be changed with this tag.
642
643 **Parent tags:** :ref:`pf_tag_zone` with ``routing="Cluster"`` attribute |br|
644 **Children tags:** none |br|
645 **Attributes:**
646
647 :``id``: The identifier of the cabinet. Facilitates referring to it.
648 :``prefix``: Each node of the cabinet has to have a name. This name will be prefixed with this prefix.
649 :``suffix``: Each node of the cabinet will be suffixed with this suffix.
650 :``radical``: Regexp used to generate cabinet nodes name.
651     Syntax: "10-20" will give you 11 machines numbered from 10 to 20, "10-20;2" will give you 12 machines, one with the number 2, others numbered as before.
652
653     The produced number is concatenated between prefix and suffix to form machine names.
654 :``speed``: Same as the ``speed`` attribute of the :ref:`pf_tag_host` tag.
655 :``bw``: Bandwidth for the links between nodes and backbone (if any). See the :ref:`pf_tag_link` for syntax/details.
656 :``lat``: Latency for the links between nodes and backbone (if any). See the :ref:`pf_tag_link` for syntax/details.
657
658 **Example**
659
660 .. literalinclude:: ../../examples/platforms/meta_cluster.xml
661
662 The hosts generated in the above example are named host-1.cluster, host-2.cluster1
663 etc.
664
665
666 .. |br| raw:: html
667      
668    <br />