1.3.2. 机构间同步
Satellite 间同步还可用来将内容导入到具体机构中,可以本地执行,也可以使用远程同步。这个功能对多个机构间断开连接的 satellite 非常有用,您可以通过频道转储搜索内容,或者从连接的 satellite 中导出,然后导入到断开连接的 satellite 中。机构间同步可用于从连接的 satellite 中导出自定义频道。它还可用于在机构间有效地移动内容。
机构间同步遵循以下明确规则以便保持源机构的完整性:
- 如果源内容属于
NULL
机构(即红帽内容),它将默认使用NULL
机构,即使指定了目的机构也会如此。这是要保证指定的内容总是在特许的NULL
机构中。 - 如果在命令行中指定一个机构,它就会从那个机构中导入内容。
- 如果没有指定机构,则默认使用机构 1。
以下是三个在 Satellite 间使用机构 ID(
orgid
)同步的示例情况:
例 1.1. 从主 satellite 中向辅 satellite 中导入内容
这个示例是从主 satellite 中向辅 satellite 中导入内容:
satellite-sync --parent-sat=master.satellite.example.com -c channel-name --orgid=2
satellite-sync --parent-sat=master.satellite.example.com -c channel-name --orgid=2
例 1.2. 从某个机构导出的转储中导入内容
这个示例是从具体机构导出的转储中导入内容:
satellite-sync -m /dump -c channel-name --orgid=2
$ satellite-sync -m /dump -c channel-name --orgid=2
例 1.3. 从红帽网络托管的服务器导入内容
这个示例是导入红帽网络托管的内容(假设系统已经注册并激活):
satellite-sync -c channel-name
$ satellite-sync -c channel-name