Example: Convert weights of Fair Scheduler queues
An example of how weights can be converted into Capacity Scheduler's queue capacity (percentage relative to its parents).
Capacity Scheduler equivalent (capacity)
The fs2cs conversion utility ensures that all percentages of direct children under one parent queue add up exactly to 100.000%, as it is demonstrated in the table. For example, all queues under root.users: root.users.alice + root.users.bob + root.users.charlie = 100.000%.
Weights are converted into percentage-based capacities the following way: On queue-level root, there are 2 queues: default and users. Since we specified 10 + 30 weights (40 altogether), 1 “unit of weight” is 2.5%. This is why root.default has 25% and root.users has 75% of the capacity. This calculation can be applied to all queue-levels.