Show Table of Contents
C.2. 主机标签
在集群配置中,可以在配置文件中定义主机标签。如果在
tags 部分设定 hosttags = 1,就会自动使用机器的主机名定义主机标签。这样可允许在所有机器中使用通用配置文件,以便其有该文件的相同的副本,但会根据主机名有不同的动作。
有关配置文件的详情请参考 附录 B, LVM 配置文件。
对于每个主机标签,会读取存在额外的配置文件 lvm_hosttag.conf。如果那个文件定义了新的标签,那么会在要读取的文件列表中添加进一步的配置文件。
例如:下面配置文件中的条目总是定义
tag1,如果主机名为 host1 则定义 tag2。
tags { tag1 { } tag2 { host_list = ["host1"] } }
Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.