In the previous recipe, we saw how to set up an MMS account and how to set up an MMS agent. In this recipe, we will throw some light on how to set up the groups and user access to the MMS console.
Refer to the previous recipe for setting up the agent and the MMS account. This is the only prerequisite for this recipe.
The preceding screen will be used to add users. Take note of the various available roles.
When a new group is created, it will be visible in the upper-left corner in a dropdown for all the groups, as shown in the following screenshot:
You can switch between the groups using this dropdown, which should show all the details and stats relevant to the selected group.
The tasks we completed in the recipe are pretty straightforward and don't need a lot of explanation, except for one question. When and why do we add a group? It is when we want to segregate our MongoDB instances by different environments or applications. There will be a different MMS agent running for each group. Creating a new group is necessary when we want to have separate monitoring groups for different environments of an application (development, QA, production, and so on), and each group has different privileges for the users. That is, the same agent cannot be used for two different groups. If we remember from the previous recipe, while configuring the MMS agent, we give it an API key unique to the group. To view the API key for the group, select the appropriate group from the dropdown on the top (if your user has access only to one group, the dropdown won't be seen), go to Administration | Group Settings, as shown in the following screenshot. The group ID and the API key will both be shown at the top of the page.
Note that not all user roles will see this option. For example, users with read-only privileges can only personalize their profile, and most of the other options will not be visible.