3.2. 手动将主机注册到 Red Hat Satellite
使用以下步骤手动将主机注册到 Red Hat Satellite 6。
先决条件
- Satellite 服务器、任何胶囊服务器和所有主机都必须与同一 NTP 服务器同步,并且启用了时间同步工具并运行。
- 守护进程 rhsmcertd 必须在主机上运行。
- 激活密钥必须可供主机使用。如需更多信息,请参阅 内容管理指南中的管理 激活码。
- 订阅管理器必须是 1.10 或更高版本。软件包包括在标准 Red Hat Enterprise Linux 软件仓库中。
流程
Red Hat Enterprise Linux 主机默认注册到 Red Hat Content Delivery Network。
更新每个主机配置,以便它们从正确的 Satellite Server 或 Capsule 服务器接收更新:
- 注意卫星服务器或胶囊式服务器的完全限定域名(FQDN),如 server.example.com。
以
root
用户身份登录主机,再从要注册主机的卫星服务器或 Capsule Server 下载katello-ca-consumer-latest.noarch.rpm
软件包。consumer RPM 将主机配置为从 Red Hat Satellite 中指定的内容源下载内容。# curl --insecure --output katello-ca-consumer-latest.noarch.rpm https://satellite.example.com/pub/katello-ca-consumer-latest.noarch.rpm
安装
katello-ca-consumer-latest.noarch.rpm
软件包:# yum localinstall katello-ca-consumer-latest.noarch.rpm
注意RPM 软件包没有签名。如果需要,您可以添加
--nosignature
选项以安装软件包。katello-ca-consumer-hostname-1.0-1.noarch.rpm
软件包是包含服务器主机名的额外katello-ca-consumer
RPM。katello-ca-consumer-latest.noarch.rpm
软件包始终反映最新版本。它们都满足相同的目的。清除与 Red Hat Subscription Manager (RHSM)相关的任何旧的主机数据:
# subscription-manager clean
使用 RHSM 注册主机:
# subscription-manager register --org=your_org_name \ --activationkey=your_activation_key
例 3.1. 注册后命令输出:
# subscription-manager register --org=MyOrg --activationkey=TestKey-1 The system has been registered with id: 62edc0f8-855b-4184-b1b8-72a9dc793b96
您可以使用 --environment
选项覆盖激活密钥定义的内容视图和生命周期环境。例如,要在 "Development" 生命周期内将主机注册到 Content View "MyView" :
# subscription-manager register --org=your_org_name \ --environment=Development/MyView \ --activationkey=your_activation_key
对于 Red Hat Enterprise Linux 6.3 主机,版本默认为 Red Hat Enterprise Linux 6 服务器,需要指向 6.3 存储库:
- 在 Satellite Web UI 中,导航到 Hosts > Content Hosts。
- 选中需要更改的主机旁边的复选框。
- 从 Select Action 列表中,选择 Set Release Version。
- 从 Release Version 列表中,选择 6.3。
- 点 Done。