Classify machines

In Rudder, we never apply policies to individual nodes, but always to sets of nodes.

A group is a query over inventory data that defines a set of nodes. Groups on which specific policies can then be applied.

In this section, you will learn how to specify such queries, and build consistent groups.

Go to the Node Management → Groups page, you will see a tree on the left. This is the tree of groups, with a hierarchy made of group categories.

Group categories are just there to visually organize groups and have no effect on the content of the groups or applied configuration.

There is a set of predefined groups (called system groups), that covers Rudder-related classification.

We will define a group made of all nodes running Ubuntu 22.04 LTS. Click on Create in the groups tree. You will then see a popup asking for several parameters.

Group of Ubuntu 22.04 nodes

The group type is dynamic. It means the group content will be automatically updated whenever a node respects belonging criteria.

Let’s configure group’s criteria:

  1. go to tab Criteria

  2. click on +

  3. as the default criteria defining the OS type as Linux is what we want, click on + next to it

  4. select Operating System Version and fill the blank space with 22.04

  5. click on Search. Our node appears at the page bottom

  6. Save

Group of Ubuntu 22.04 nodes
You can notice the server does not appear on nodes list as Rudder servers are excluded from groups by default.

We now have defined a first custom group using inventory data.

You can also group machines using your own criteria:

  1. go to menu Nodes

  2. select your node in clicking on hostname

  3. go to tab Properties

  4. add the property env : prod

  5. click on +

Create a property

One property appeared in the table. Now, you will be able to create a group using it as a criteria:

  1. go to menu Groups

  2. click on Create +

  3. add a name Production machines and Create

  4. go to tab Criteria

  5. click on +

  6. in the first column, select Properties

  7. fill the blank with env=prod

  8. click on Search, then Save

Create a dynamic group with a property

Now, we created a group using a custom criteria. Properties enable you to group machines according your own needs.

How to design groups in Rudder?

The best practice advice to:

  • Create multiple layers of groups:

    • Geographic (Data center, rack, …​)

    • Business (Production, QA, …​)

    • Applicative (Installed application, …​)

    • System (Operating system, …​)

  • Build subgroups using the belonging to another group as a criteria, which allows expressing complex cases without duplicating query definition


← Add a new machine Configuration policy management →