Lustre: Installing and setting up a RobinHood server (RBH)
Enabling the HSM Coordinator for an Existing File System
The HSM Coordinator can be enabled at any time after a file system has been created, provided that the file system is based on Lustre 2.5.0 or newer, the Metadata service is online, and the MDT and MGT are mounted.
- Log into Intel® Manager for Lustre dashboard as a superuser.
- Navigate to the File Systems window: Click Configuration > File Systems.
- Select the file system for which HSM support is to be enabled from the list of file systems.
- Under Metadata Target, click the name of the metadata target.
- Click the Advanced tab and look for the property hsm_control.
- Enter the string enabled into the text field.
- Click the Apply button. The background will briefly flash to grey then back to white to indicate that the setting has been applied. Click Close when done.
Verifying the Current Status of the Coordinator
The most reliable way to verify the status of the HSM Coordinator process is to log into the metadata server that currently has the MDT mounted. Then enter the following command:
lctl get_param mdt.*.hsm_control
For example:
[root@mds2 ~]# lctl get_param mdt.*.hsm_control
mdt.lfs-MDT0000.hsm_control=stopped
# Go perform the step above
[root@mds2 ~]# lctl get_param mdt.*.hsm_control
mdt.lfs-MDT0000.hsm_control=enabledConfigure MDS Changelogs
Robinhood relies on the MDT Changelogs feature in Lustre in order to track changes to the file system. The Changelog records changes to the file system's metadata, such as creating and deleting files, modifying a file's content, ownership, permissions, and other attributes. Robinhood captures this data and stores it in a MySQL database for processing by its policy engine. Applications that want to consume the Changelogs content need to register with the MDT, which will return a unique identifier, referred to as a userid. This is not the same as a UNIX user account identifier; it is internal to Lustre and is a token used to distinguish registrations from multiple consumers. Each registered userid has its own view of the Changelog register. Changelog entries are kept until each registered user has acknowledged that the entry has been consumed.
# on server with MGT mounted / also assumes only one FSname (used a * for fsname below)
[root@mds2 ~]# lctl get_param mdd.*-MDT*.changelog_mask
mdd.lfs-MDT0000.changelog_mask=
MARK CREAT MKDIR HLINK SLINK MKNOD UNLNK RMDIR RENME RNMTO OPEN LYOUT TRUNC SATTR XATTR HSM MTIME CTIME
[root@mds2 ~]# lctl set_param -Pmdd.*-MDT*.changelog_mask="all-XATTR-MARK-ATIME"
mdd.lfs-MDT0000.changelog_mask=all-XATTR-MARK-ATIME
[root@mds2 ~]# lctl get_param mdd.*-MDT*.changelog_mask
mdd.lfs-MDT0000.changelog_mask=
CREAT MKDIR HLINK SLINK MKNOD UNLNK RMDIR RENME RNMTO OPEN CLOSE LYOUT TRUNC SATTR HSM MTIME CTIME
# so the word MARK seems to be removed and XATTR
# Note; If you run without the -P, the changes wont be persistent (and without the -P you can run on the MDS)Register a Changelog user identifier on the MDS and keep a record of the name of the userid that is returned (normally this will be "cl1", unless there is more than one Changelog registration):
# lctl --device <fsname>-<MDT index> changelog_register