システム管理者のガイド

Red Hat Update Infrastructure 3.1

Red Hat Update Infrastructure のインストール、設定、および管理

Red Hat Customer Content Services

概要

Red Hat Update Infrastructure 3.1.9 System Administrator's Guide には、クラウドプロバイダーが Red Hat Update Infrastructure を実装し、設定するのに役立つ要件と手順が記載されています。また、コンテンツ配信サーバー、ロードバランサー、カスタムリポジトリーの追加や削除など、管理タスクを実行する手順をステップバイステップで説明します。

多様性を受け入れるオープンソースの強化

Red Hat では、コード、ドキュメント、Web プロパティーにおける配慮に欠ける用語の置き換えに取り組んでいます。まずは、マスター (master)、スレーブ (slave)、ブラックリスト (blacklist)、ホワイトリスト (whitelist) の 4 つの用語の置き換えから始めます。この取り組みは膨大な作業を要するため、今後の複数のリリースで段階的に用語の置き換えを実施して参ります。詳細は、Red Hat CTO である Chris Wright のメッセージ をご覧ください。

第1章 Red Hat Update Infrastructure の概要

Red Hat Update Infrastructure (RHUI) は、スケーラビリティーが高く、冗長なフレームワークで、リポジトリーとコンテンツを管理できます。また、クラウドプロバイダーは、Red Hat Enterprise Linux (RHEL) インスタンスにコンテンツおよび更新を配信できます。アップストリームの Pulp プロジェクトに基づいて、RHUI を使用すると、クラウドプロバイダーは Red Hat がホストするリポジトリーコンテンツをローカルにミラーリングし、独自のコンテンツでカスタムリポジトリーを作成し、負荷分散されたコンテンツ配信システムを通じてエンドユーザーの大規模なグループがそれらのリポジトリーを利用できるようになります。

システム管理者は、Red Hat Update Appliance (RHUA)、コンテンツ配信サーバー (CD)、リポジトリー、共有ストレージ、および負荷分散をインストールして設定する手順に従うことで、Red Hat Certified Cloud and Service Provider プログラム に参加するためのインフラストラクチャーを準備できます。経験のある RHEL システム管理者には、ターゲットオーディエンスがあります。Red Hat Enterprise Linux スキルが限定されたシステム管理者は、Red Hat 認定クラウドプロバイダーアーキテクチャーサービスを提供するために Red Hat コンサルティングを行うことを検討してください。

RHUI の設定、管理、および更新について、以下のトピックでご紹介します。

  • RHUI の各種コンポーネント
  • コンテンツプロバイダーのタイプ
  • コンポーネントの管理に使用するコマンドラインインターフェイス (CLI)
  • ユーティリティーコマンド
  • 証明書の管理
  • コンテンツ管理

Red Hat Update Infrastructure Management Tool で利用可能な全メニューおよびコマンドの一覧は、付録A Red Hat Update Infrastructure Management Tool のメニューおよびコマンド を参照してください。

標準シェルプロンプトからも実行できる機能の一覧は、付録B Red Hat Update Infrastructure コマンドラインインターフェイス を参照してください。

既知の問題および考えられる解決策の一部は、付録C Resolve Common Problems in Red Hat Update Infrastructure を参照してください。

Red Hat Update Infrastructure で使用される Pulp API の一覧は、付録D Red Hat Update Infrastructure における API リファレンス を参照してください。

さまざまな Red Hat Update Infrastructure コンポーネントの詳細は、以下のリソースを参照してください。

1.1. 新機能

Red HatUpdateInfrastructure は以下を提供します。

  • Puppet を使用した簡単なインストール
  • Red Hat Satellite 6 のコードベースと一貫性を保つためにコードを Pulp 2.18 にリベース。
  • 自動インストール用のアーキテクチャーが再設計されたことで、コンテンツへのアクセス時間を短縮します。
  • CDS でコンテンツの可用性を高速化し、同期の必要がなくなるように Red Hat Gluster Storage をデフォルトの共有ストレージとして使用します。
  • 高可用性デプロイメントで別の CDS に同期されないというエラーを軽減。
  • クライアントに表示されるロードバランサー/HAProxy ノード。(この機能は以前のリリースで CDS ロジックに統合されました。)
  • rhui-installer および rhui-manager コマンドで証明書を管理。
  • 新規の統合 URL を使用するために yum.repos.d/*、証明書、および鍵を更新。
  • rhui-lb.py からクライアント側の負荷分散機能を削除。
  • Docker および OSTree (atomic) コンテンツをサポート。

1.2. インストールオプション

以下の表は、さまざまな Red Hat Update Infrastructure コンポーネントを示しています。

表1.1 Red Hat Update Infrastructure のコンポーネントおよび機能

Component略語機能代替方法

Red Hat 更新アプライアンス

RHUA

Red Hat コンテンツ配信ネットワークから新しいパッケージをダウンロードして、各 CDS ノードにコピーする

なし

コンテンツ配信サーバー

CDS

クライアントが更新パッケージ用に接続する yum リポジトリーを提供する

なし

HAProxy

なし

CDS ノード全体での負荷分散を提供する

既存のストレージソリューション

Gluster Storage

なし

共有ストレージを提供する

既存のストレージソリューション

以下の表は、インストールタスクを実行する方法を説明します。

表1.2 Red Hat Update Infrastructure のインストールタスク

インストールタスク実行場所

Install Red Hat Enterprise Linux 7

RHUA、CDS、および HAProxy

システムのサブスクライブ

RHUA、CDS、および HAProxy

Red Hat Update Infrastructure サブスクリプションのアタッチ

RHUA、CDS、および HAProxy

更新の適用

RHUA、CDS、および HAProxy

Red Hat Update Infrastructure ISO のマウント (任意)

RHUA、CDS、および HAProxy

setup_package_repos スクリプトを実行します (RHUI 3 ISO を使用している場合はオプション)

RHUA、CDS、および HAProxy

rhui-installer のインストール

RHUA

rhui-installer の実行

RHUA

クラウド環境の設定にはいくつかのシナリオがあります。オプション 1: 完全なインストールについて詳しく説明し、他のシナリオでインストールを変更する方法に関するメモと注釈を含めます。

1.2.1. オプション 1: 完全なインストール

  • RHUA
  • Gluster Storage を使用する 3 つ以上の CDS ノード
  • 2 台以上の HAProxy サーバー

1.2.2. オプション 2: 既存のストレージソリューションを使用したインストール

  • RHUA
  • 既存のストレージソリューションを備えた 2 つ以上の CDS ノード
  • 2 台以上の HAProxy サーバー

1.2.3. オプション 3: 既存のロードバランシングソリューションを使用したインストール

  • RHUA
  • Gluster Storage を使用する 3 つ以上の CDS ノード
  • 既存のロードバランサー

1.2.4. オプション 4: 既存のストレージおよび負荷分散ソリューションを使用したインストール

  • RHUA
  • 既存のストレージソリューションを備えた 2 つ以上の CDS ノード
  • 既存のロードバランサー

以下の図は、さまざまな RHUI コンポーネントが対話する方法の概要を示しています。

図1.1 Red Hat Update Infrastructure の概要

Red Hat Update Infrastructure Overview
注記

Red Hat Update Infrastructure をインストールするには、RHUI ISO と Red Hat Certified Cloud and Service Provider サブスクリプションが必要です。適切なコンテンツ証明書も必要です。

RHUA ノードと CDS ノードを別々の x86_64 サーバー (ベアメタルまたは仮想マシン) にインストールします。RHUI に接続するすべてのサーバーとネットワークが ISO または Red Hat Subscription Management サービスにアクセスできることを確認します。

注記

RHUA は実際にはアプライアンスとして同梱されていませんが、クラウドのインスタンスにインストールされる RPM です。

Red Hat Update Infrastructure をセットアップする前に、リリースノート を参照してください。

1.3. Red Hat Update Infrastructure のコンポーネント

RHUI の各コンポーネントについて詳細に説明します。

1.3.1. Red Hat Update Appliance

RHUI インストールごとに RHUA がありますが、多くのクラウド環境では、リージョンまたはデータセンターごとに RHUI インストールがあります。たとえば、Amazon の EC2 クラウドは複数のリージョンで設定されています。すべてのリージョンでは、独自の RHUA ノードを持つ個別の RHUI が設定されています。

RHUA では、以下の作業を行うことができます。

  • Red Hat コンテンツ配信ネットワーク (CDN) から新規パッケージをダウンロードします。RHUA は Red Hat に接続する唯一の RHUI コンポーネントであり、RHUA の同期スケジュールを設定できます。
  • 新規パッケージを各 CDS ノードにコピーします。
  • RHUI インストールの健全性を検証し、結果を RHUA にあるファイルに書き込みます。監視ソリューションは、このファイルを使用して RHUI インストールの健全性を判断します。
  • CLI ツールを使用して RHUI インストールの健全性について人間が判読できるビューを提供します。

RHUI は主に /etc/rhui/rhui-tools.conf/etc/rhui-installer/answers.yaml の設定ファイルを使用します。

/etc/rhui/rhui-tools.conf 設定ファイルには、RHUA で使用される一般的なオプション (証明書のデフォルトのファイルの場所、Red Hat CDN 同期のデフォルト設定パラメーターなど) が含まれます。通常、このファイルを編集する必要はありません。

Red Hat Update Infrastructure Management Tool は、ユーザー入力の値に基づいて /etc/rhui-installer/answers.yaml 設定ファイルを生成します。これには、特定のリージョンで RHUA の実行を促進するすべての情報が含まれます。設定例には、パッケージをダウンロードするための RHUA の宛先と、RHUI インストールの CDS ノード (ホスト名) の一覧が含まれます。

RHUA は複数のサービスを使用して、配信を簡単にするためにコンテンツを同期し、整理し、配布します。

RHUA サービス

Pulp
サポートされるサービスの管理を監視し、ユーザーが対話するユーザーインターフェイスを提供するサービスです。
MongoDB
現在同期しているリポジトリー、パッケージ、およびその他の重要なメタデータを追跡するために使用されるバリアントデータベースです。MongoDB は、値を bson (Binary JSON) オブジェクトに保存します。
Qpid
RHUA が CDS と安全に対話して、必要なアクションを RHUA に対して通知できるようにする Apache ベースのメッセージングブローカーシステム (同期、削除、調整リポジトリーなど)。これにより、RHUA システムから RHUI アプライアンスを完全に制御できます。

以下の考慮事項が該当します。

1.3.2. コンテンツ配信サーバー

CDS ノードは、クライアントが更新したコンテンツ用に接続するリポジトリーを提供します。CDS は 1 つしかありません。RHUI はフェイルオーバー機能を備えたロードバランサーを提供するため、複数の CDS ノードを使用することが推奨されます。

エンドユーザーの RHEL システムへの CDS ホストコンテンツシステムの数は必要ありませんが、CDS はラウンドロビン形式の負荷分散方式 (A、B、C、A、B、C) で動作し、エンドユーザーシステムにコンテンツを提供します。CDS は HTTP を使用して、httpd-based yum リポジトリーを介してコンテンツをエンドユーザーシステムにホストします。

設定時に、パッケージが同期される CDS ディレクトリーを指定します。RHUA と同様に、唯一の要件は、CDS にディレクトリーをマウントすることです。必要なデバイスを割り当てる際の最適なアクションが判断されるのは、クラウドプロバイダー次第です。Red Hat Update Infrastructure Management Tool 設定 RPM は、パッケージディレクトリーと Apache 設定をリンクして、パッケージディレクトリーを提供します。

NFS が使用される場合、rhui-installer は RHUA で NFS 共有を設定し、コンテンツと NFS 共有をマウントする CDS のディレクトリーを保存できます。以下の rhui-manager オプションは、この設定を制御します。

  • --remote-fs-mountpoint は、リモートファイルシステム共有をマウントする必要があるファイルシステムの場所です (デフォルト: /var/lib/rhui/remote_share)
  • --remote-fs-server は、共有ファイルシステムが使用するリモートマウントポイントです。たとえば、nfs.example.com:/path/to/share (デフォルト: nfs.example.com:/export) です。

これらのデフォルト値が使用される場合、RHUA の /export ディレクトリーと各 CDS の /var/lib/rhui/remote_share ディレクトリーは同じになります。たとえば、yumdocker、および ostree リポジトリーがすでに同期されている場合は、published サブディレクトリーの構造は以下のようになります。

[root@rhua ~]# ls /export/published/
docker  ostree  yum

[root@cds01 ~]# ls /var/lib/rhui/remote_share/published/
docker  ostree  yum

予想される使用法は、各 CDS がパッケージのコピーを保持することです。クラウドプロバイダーは、RHUA がパッケージを書き込んで各 CDS が読み取る共有ストレージ (Gluster Storage など) の形式を使用できます。

注記

ストレージソリューションは、RHUA および CDS にマウントするための NFS エンドポイントを提供する必要があります。ローカルストレージが実装されている場合、クラスターが機能するために共有ストレージが必要になります。RHUA にローカルストレージを提供する場合は、RHUA が rhua.example.com:/path/to/nfs/share エンドポイントが設定された NFS サーバーとして機能するように設定します。

各 CDS で行われる唯一の標準以外のロジックは、エンタイトルメント証明書チェックです。このチェックにより、クライアントが yum リポジトリーまたは ostree リポジトリーに対して要求を行うのが、クラウドプロバイダーがこれらのリポジトリーにアクセスする権限を付与するようになります。このチェックでは、以下の条件を確認します。

  • エンタイトルメント証明書がクラウドプロバイダーの認証局 (CA) 証明書により署名されている。この検証を容易にするため、CA 証明書はその設定の一部として CDS にインストールされている。
  • 要求された URI は、クライアントのエンタイトルメント証明書にあるエンタイトルメントと一致します。

CA の検証に失敗すると、クライアントには SSL エラーが表示されます。詳細は、/var/log/httpd/ にある CDS の Apache ログを参照してください。

[root@cds01 ~]# ls -1 /var/log/httpd/
access_log
cds.example.com_access_ssl.log
cds.example.com_error_ssl.log
crane_access_ssl.log
crane_error_ssl.log
default_error.log
error_log
重要

Apache の設定は、CDS のインストール時に /etc/httpd/conf.d/cds_ssl.conf ファイルで処理されます。

複数のクライアントがリポジトリーに対して更新に問題がある場合は、RHUI で問題があることを示す可能性があります。詳細は、Yum generates 'Errno 14 HTTP Error 401: Authorization Required' while accessing RHUI CDS を参照してください。

1.3.3. HAProxy

複数の CDS が使用される場合は、負荷分散ソリューションを準備して、クライアント HTTPS 要求をすべてのサーバーに分散する必要があります。RHUI には HAProxy が同梱されていますが、インストール時に使用する負荷分散ソリューション (クラウドプロバイダーからのソリューションなど) を選択するのはユーザー次第です。HAProxy が使用されている場合は、挿入するノードの数を決定する必要もあります。詳細は、HAProxy の設定 を参照してください。

クライアントは CDS に直接移動するように設定されていません。リポジトリーファイルは、RHUI ロードバランサーである HAProxy を参照するように設定されます。HAProxy は特に高可用性環境に適した TCP/HTTP リバースプロキシーです。HAProxy は以下の作業を行います。

  • 静的に割り当てられた Cookie (クッキー) に応じて HTTP リクエストをルーティングします。
  • HTTP Cookie を使用してサーバー永続性を維持しながら、複数のサーバーに負荷を分散します。
  • メインサーバーが失敗した場合にバックアップサーバーに切り替えます。
  • サービス監視専用の特別なポートへの接続を許可します。
  • 既存の接続を破損することなく接続の受け入れを停止します。
  • 両方向で HTTP ヘッダーを追加、変更、および削除します。
  • 特定のパターンに一致するリクエストをブロックします。
  • アプリケーション Cookie に応じて、正しいアプリケーションサーバーへのクライアント接続を永続化します。
  • HTML ページとして、アプリケーションから傍受された URI からの認証ユーザーに詳細なステータスを報告します。

RHEL 7 では、ロードバランサー技術はベースオペレーティングシステムに含まれています。ロードバランサーは別のノードにインストールする必要があります。

注記

既存のロードバランサーを使用する場合は、プールに転送される filename cds-lb-hostname のロードバランサーでポート 5000 と 443 が設定されていること、およびクラスター内のすべての CDS がロードバランサーのプールにあることを確認してください。第 8 章の手順に従う必要はありません。

正確な設定は、使用する特定のロードバランサーソフトウェアによって異なります。ロードバランサーの設定方法を理解するには、一般的な HAProxy 設定から取られる以下の設定を参照してください。

[root@rhui3proxy ~]# cat /etc/haproxy/haproxy.cfg
# This file managed by Puppet
global
  chroot  /var/lib/haproxy
  daemon
  group  haproxy
  log  10.13.153.2 local0
  maxconn  4000
  pidfile  /var/run/haproxy.pid
  stats  socket /var/lib/haproxy/stats
  user  haproxy

defaults
  log  global
  maxconn  8000
  option  redispatch
  retries  3
  stats  enable
  timeout  http-request 10s
  timeout  queue 1m
  timeout  connect 10s
  timeout  client 1m
  timeout  server 1m
  timeout  check 10s

listen crane00
  bind 10.13.153.2:5000
  balance roundrobin
  option tcplog
  option ssl-hello-chk
  server cds3-2.usersys.redhat.com cds3-2.usersys.redhat.com:5000 check
  server cds3-1.usersys.redhat.com cds3-1.usersys.redhat.com:5000 check

listen https00
  bind 10.13.153.2:443
  balance roundrobin
  option tcplog
  option ssl-hello-chk
  server cds3-2.usersys.redhat.com cds3-2.usersys.redhat.com:443 check
  server cds3-1.usersys.redhat.com cds3-1.usersys.redhat.com:443 check

グローバル、デフォルト、およびリッスンの設定の詳細は、Red Hat Enterprise Linux 7 ロードバランサーの管理 を参照してください。

クライアントが正常に接続できない場合は、/var/log/httpd/ の下にある CDS の httpd ログを確認して、要求が CDS に到達したことを確認することが重要であることに注意してください。リクエストが CDS に届かない場合は、DNS や一般的なネットワーク接続に問題がある可能性があります。

1.3.4. リポジトリー、コンテナー、およびコンテンツ

リポジトリーは、ソフトウェアパッケージ (RPM) のストレージの場所です。RHEL は、yum コマンドを使用して、RPM の検索、ダウンロード、インストール、および設定を行います。RPM には、アプリケーションの実行に必要なすべての依存関係が含まれます。RPM は、リポジトリーのソフトウェアの更新もダウンロードします。

RHEL 7 は、リソース管理用のコントロールグループ (cgroup)、プロセス分離用の名前空間、SELinux によるセキュリティーなどのコアな技術を使用して Linux コンテナーを実装します。これにより、セキュアなマルチテナントが可能になり、セキュリティーの悪用の可能性が低減します。Linux コンテナーは、セキュリティーを強化する一方で、迅速なアプリケーションデプロイメント、単純なテスト、メンテナーンス、およびトラブルシューティングを可能にします。Docker で RHEL 7 を使用すると、スタッフの効率を高め、サードパーティーのアプリケーションを迅速にデプロイし、よりアジャイルな開発環境を有効にし、リソースをより密接に管理できます。

RHEL 7 で Linux コンテナーを使用するには、2 つの一般的なシナリオがあります。ホストコンテナーをアプリケーションサンドボックスのツールとして使用するか、またはイメージベースのコンテナーの拡張機能を使用できます。イメージからコンテナーを起動すると、書き込み可能な階層がこのイメージの上部に追加されます。コンテナーをコミットするたびに (docker commit コマンドを使用)、変更を保存する新しいイメージ層が追加されます。

RHUI に関連するコンテンツは、RHUA ノードおよび CDS ノードで使用する Red Hat CDN からダウンロードしたソフトウェア (RPM など) です。RPM は、特定のアプリケーションおよびツールの実行に必要なファイルを提供します。クライアントには、rpm パッケージが提供する SSL コンテンツ証明書と鍵のセットによるアクセスが付与されます。これは、生成された yum リポジトリーファイルのセットも提供します。

詳細は、What Channels Can Be Delivered at Red Hat's Certified Cloud & Service Provider (CCSP) Partners? を参照してください。

1.4. コンテンツプロバイダーのタイプ

クラウドコンピューティング環境には、パブリッククラウド、プライベートクラウド、ハイブリッドクラウドの 3 つのタイプがあります。本ガイドでは、パブリッククラウドおよびプライベートクラウドに焦点を当てています。パブリッククラウド、プライベートクラウド、ハイブリッドクラウドの使用の影響を理解していることを前提としています。

1.5. ユーティリティーおよびコマンドラインインターフェイスコマンド

Red Hat Update Infrastructure Management Tool を使用して実行できる機能の一覧は、付録A Red Hat Update Infrastructure Management Tool のメニューおよびコマンド を参照してください。

標準のシェルプロンプトからも実行できる関数の一覧は、付録B Red Hat Update Infrastructure コマンドラインインターフェイス を参照してください。

1.6. コンポーネントの通信

すべての RHUI コンポーネントは、ポート 443 での HTTPS 通信プロトコルを使用します。

表1.3 Red Hat Update Infrastructure の通信プロトコル

Source宛先プロトコル目的

Red Hat Update Appliance

Red Hat コンテンツ配信ネットワーク

HTTPS

Red Hat からパッケージをダウンロードします。

ロードバランサー

コンテンツ配信サーバー

HTTPS

クライアントの yum、docker、または ostree 要求を転送します。

クライアント

ロードバランサー

HTTPS

クライアント上の yum、docker、または ostree で使用され、コンテンツ配信サーバーからパッケージをダウンロードします。

バグの報告

第2章 インストールに必要な情報

以下のチェックリストを使用して、Red Hat Update Centre (RHUA) ノードおよびコンテンツ配信サーバー (CDS) ノードをインストールする前に必要なすべての情報を収集します。

表2.1 Red Hat Update Infrastructure 要件チェックリスト

必要な情報情報使用リソースおよび注意事項

Red Hat 認証情報

 

Red Hat カスタマーポータル

 

RHUA および各 CDS のネットワークおよびファイアウォール要件

CDS に、Red Hat Update Infrastructure 内の通信に使用されるホスト名とは異なるクライアント向けホスト名を指定できます。クライアントに表示されるホスト名を使用している場合は、各 CDS のクライアント向け FQDN と対応する IP アドレスを書き留めておきます。

 

Red Hat コンテンツ配信ネットワークにアクセスするためのプロキシー

インストール時に自動的に設定される Red Hat Update Infrastructure のプロキシー設定。これらは、リポジトリーを設定する /etc/yum.conf ファイルの CDS ノードに設定されます。

コンテンツリポジトリーのサイズ

Red Hat Update Infrastructure で必要な RPM パッケージのストレージ領域

特定のストレージ要件については、Preparing your Environment for Installation を参照するか、コマンドラインインターフェイスから du コマンドを使用して、そのサイズを判断してください。

クライアントプロファイル

クライアントプロファイルは、クライアントで利用可能な Red Hat Update Infrastructure コンテンツと、クライアントがそのコンテンツをダウンロードする CDS を決定します。

 

*すべてのリポジトリーは /var/lib/pulp ディレクトリーにあります。このディレクトリーは、そのディレクトリー用に新しいマウントポイントを作成する必要がある場合にのみ作成します。作成しないと、インストールプロセス中にシステムが自動的に作成します。

注記

データ量が多いことが予想される場合は、インストールに別のストレージボリュームを使用することを検討してください。

注記

各 RHUI サーバー (RHUA ノードまたは CDS ノード) には、必要なサイズの個別のファイルシステムが必要です。必要に応じてコンテンツリポジトリーを拡張することができる LVM、SAN、または NAS ストレージなどの技術を使用することが重要になります。現在の rhel-7-server-rpms リポジトリーは 12 GB で、現在の rhel-6-server-rpms リポジトリーは 29 GB です。これらのリポジトリーは製品と同様に拡張されます。これらのリポジトリーは、任意の環境のパッケージをすべて保持するために必要な大規模サイズの例になります。

バグの報告

第3章 Red Hat Update Infrastructure のインストールの前提条件

クラウドプロバイダーは、以下の技術的な前提条件を提供します。

  • クライアントのレビューを含む、Red Hat Certified Cloud & Service Provider (CCSP) 認定の初期段階の完了。

    • 仮想化、イメージの作成、およびインスタンスのプロビジョニングテクノロジー、ツール、およびプロセス
    • Red Hat ソフトウェアの測定およびレポートの消費についての提案プロセス。
    • エラータ更新を Red Hat ソフトウェアに通知するための提案プロセス
    • イメージのライフサイクルの管理や、古くなったイメージを提案して、Red Hat ソフトウェアをお客様から利用できるようにするための提案的なプロセスです。

      詳細は、Red Hat Certified Cloud and Service Provider Certification Browse Knowledgebase を参照してください。

  • 通常、自己署名証明書は Red Hat Update Infrastructure (RHUI) デプロイメントに使用されます。サードパーティーの認証局が署名した SSL 証明書を使用する場合は、クライアントから取得され、Red Hat によって確認されています。
注記

Red Hat コンサルタントは、自己署名証明書の開発を支援することができ、クライアントのカスタマーのユーザーエクスペリエンスには影響しません。

  • クライアントは、以下に示すように、すべての Red Hat Update Centres (RHUA)、外部ロードバランサー、およびコンテンツ配信サーバー (CDS) をインストールするためのシステム、仮想マシン、またはテナントインスタンスを提供します。
  • RHEL 7 にアクセスし、(ISO またはサブスクリプションで) RHUI ビットが利用可能であることを確認します。
  • RHUI の最小インストールには、以下のように設定された RHUA、ロードバランサー、および CDS (物理または仮想) の 2 つのサーバーが含まれます。

    • Red Hat Enterprise Linux (RHEL) 7.6 以降 (最小限 のインストールが推奨)
    • SELinux が有効
    • AMD64 プロセッサーアーキテクチャーの CPU
    • 最小 4GB のメモリー (Gluster Storage が使用されている場合、CDS の場合は最小 16 GB のメモリー)
    • オペレーティングシステム用に 10 GB ディスク
    • RHEL のメジャーリリースごとに 50 GB ディスク
    • GlusterFS ブリック専用の 500 GB のローカルブロックデバイスを持つ各 CDS ノード (Gluster Storage が使用される場合)
    • MongoDB の場合は 50GB (RHUI に多数の RHEL リポジトリーを保持する場合は 100 GB)。この容量をルートファイルシステムに追加するか、この容量のボリュームをアタッチして /var/lib/mongodb にマウントします。
  • openssl を使用した認定の生成には、以下のようにサーバー (新規または既存) を設定する必要があります。

    • 最小限 のインストールが推奨されている RHEL 7.6 以降
    • SELinux が有効になっている
    • AMD64 プロセッサーアーキテクチャーの CPU
    • 2 GB メモリー
    • オペレーティングシステム用に 6 GB ディスク
  • イメージ認定は、指定した RHEL ゲストテンプレートで実行されます。

    • オペレーティングシステム用に最小 10 GB ディスク
    • iptables on
    • SELinux が有効になっている
    • パスワード認証が有効になっている場合は、最も強力なハッシュを使用する必要があります。
    • デフォルトのログオン
  • クライアントのネットワークが RHUI に対して適切に設定されている必要があります。

    • すべての RHUA、CDS、および外部ロードバランサー (存在する場合) に IP アドレスが割り当てられている。
    • DNS レコード (順方向および逆方向) は、すべての IP アドレス (たとえば、rhua.company.comcds1.company.comcds2.company.com、および certs.company.com) に対して作成されています。
注記

サーバーに複数のネットワークインターフェイスカード (NIC) がある場合、RHUA と CDS の完全修飾ドメイン名 (FQDN) を、RHUA と CDS 間の通信に使用される NIC の IP に解決する必要があります。

RHUI が DNS を使用して CDN にアクセスする。ほとんどの場合、インスタンスは、クラウドのインフラストラクチャーの一部としてホストされる適切な DNS サーバーと通信するように事前設定する必要があります。独自の DNS サーバーを実行するか、クライアント DNS 設定を更新すると、yum Could not contact any CDS load balancers のようなエラーが表示される可能性があります。この場合は、DNS サーバーが要求に対してクラウドの DNS サーバーに転送されているか、DNS クライアントが名前解決のためにクラウドの DNS サーバーにフォールバックするように設定されているかを確認します。

複数の HAProxy ノードを使用するには、rhui-installer (このガイドでは cds.example.com) の実行時に --cds-lb-hostname パラメーターの値として使用されるホスト名のラウンドロビン DNS エントリーが必要です。これは、すべての HAProxy の IP アドレスに解決されます。ノード。DNS Round Robin の設定方法 により、ラウンドロビン DNS を設定する方法があります。RHUI のコンテキストでは、これらは HAProxy ノードの IP アドレスになり、rhui-installer を呼び出すときに --cds-lb-hostname として指定されたホスト名にマップされます。

詳細は、HAProxy の設定 を参照してください。

  • 必要なネットワークポートがすべて開きます。

表3.1 必要なネットワークポート設定

接続ポート用途

RHUA から cdn.redhat.com

443/TCP

コンテンツの配信

RHUA から CDS へ

22/TCP

SSH の初期設定

RHUA から HAProxy サーバー

22/TCP

SSH の初期設定

CD から RHUA へ

8140/TCP

Puppet

HAProxy から RHUA へ

8140/TCP

Puppet

CDS または HAProxy へのクライアント

443/TCP

 

CDS または HAProxy へのクライアント

5000/TCP

Docker

HAProxy から CDS へ

443/TCP

負荷分散

HAProxy から CDS へ

5000/TCP

Docker 負荷分散

GlusterFS ポート

24007/TCP、49152-4/TCP

ストレージ

NFS ポート

2049/TCP

ファイルシステム

  • RHUA と Red Hat CDN の間のネットワークプロキシー設定が適切に設定されます。
  • yum.conf を介して、CDS とクライアントとの間でネットワークプロキシー設定が適切に設定されます。
  • 複数の HAProxy ノードが使用される場合のラウンドロビン DNS エントリー

バグの報告

第4章 Red Hat Update Infrastructure の登録およびサブスクリプションの割り当て

4.1. Red Hat Enterprise Linux をインストールする

手順

  1. Red Hat Enterprise Linux を Red Hat Update Centre (RHUA)、各コンテンツ配信サーバー (CDS)、および HAProxy ロードバランサー (使用する場合) にインストールします。インストールの詳細は、Red Hat Enterprise Linux 7 インストールガイド を参照してください。
注記

後のインストールおよびサブスクリプション登録プロセス中に、各ノードに適切なサブスクリプションをアタッチします。サブスクリプションの詳細は、Red Hat Enterprise Linux 7 システム管理者のガイド の第 6 章を参照してください。

4.2. Red Hat Update Infrastructure の登録

手順

  1. RHUA インスタンスとして使用するシステムを登録します。

    [root@rhua ~]# subscription-manager register --type=rhui --username <admin-example> --password <secret>
    Registering to: subscription.rhsm.redhat.com:443/subscription
    The system has been registered with ID: <a12b34c5-6d78-9ef1-2345-ghi678jk91l2m>
    注記

    すでに登録されている RHUA としてシステムを使用していて、RHUA にすでにサブスクリプションが添付されている場合は、次のように表示されます。This system is already registered.Use --force to override when you try to register it using # subscription-manager register --type=rhui.その場合は、コマンドライン引数に --force を追加して、サブスクリプションを上書きできます。

    この場合の代替方法は、システムの登録を解除し (#subscription-manager unregister)、再度登録 (#subscription-manager register --type=rhui) することです。

  2. 既存の外部の登録済みのシステムが使用されていない限り使用される各 CDS ノードを登録します。

    [root@cds1 ~]# subscription-manager register --type=rhui --username <admin-example> --password <secret>
    Registering to: subscription.rhsm.redhat.com:443/subscription
    The system has been registered with ID: <a12b34c5-6d78-9ef1-2345-ghi678jk91l2m>
  3. 既存の外部の登録済みのシステムが使用されていない限り使用される各 HAProxy ノードを登録します。

    [root@haproxy1 ~]# subscription-manager register --type=rhui --username <admin-example> --password <secret>
    Registering to: subscription.rhsm.redhat.com:443/subscription
    The system has been registered with ID: <a12b34c5-6d78-9ef1-2345-ghi678jk91l2m>

    新しいシステムが カスタマーポータル で利用可能になり、新しい RHUA インスタンスにはサブスクリプションが適用されていません。

4.3. Red Hat Update Appliance に対するサブスクリプションの割り当て

手順

  1. RHUA に追加可能なサブスクリプションを確認します。

    [root@rhua ~]# subscription-manager list --available
    +-------------------------------------------+
        Available Subscriptions
    +-------------------------------------------+
    Subscription Name:   Red Hat Enterprise Linux Atomic Host for Certified Cloud
                         and Service Providers (via Red Hat Update Infrastructure)
    Provides:            Red Hat Enterprise Linux Atomic Host Beta from RHUI
                         Red Hat Enterprise Linux Atomic Host from RHUI
    SKU:                 RH00731
    Contract:            11312089
    Pool ID:             8a85f9815a6c4c9d015a6c6acb373ed9
    Provides Management: No
    Available:           19
    Suggested:           1
    Service Level:       Premium
    Service Type:        L1-L3
    Subscription Type:   Standard
    Ends:                02/22/2018
    System Type:         Physical
    
    Subscription Name:   Red Hat Update Infrastructure and RHEL Add-Ons for
                         Providers
    Provides:            dotNET on RHEL (for RHEL Server) from RHUI
                         Red Hat Enterprise Linux Server from RHUI
                         Red Hat Software Collections (for RHEL Server) from RHUI
                         Red Hat Enterprise Linux for SAP from RHUI
                         Red Hat Enterprise Linux Resilient Storage (for RHEL
                         Server) from RHUI
                         Red Hat Enterprise Linux Scalable File System (for RHEL
                         Server) from RHUI
                         Red Hat Enterprise Linux Server - Extended Update Support
                         from RHUI
                         dotNET on RHEL Beta (for RHEL Server) from RHUI
                         Red Hat Enterprise Linux for SAP Hana from RHUI
                         RHEL Software Test Suite (for RHEL Server) from RHUI
                         Red Hat Enterprise Linux High Availability (for RHEL
                         Server) from RHUI
                         Red Hat Update Infrastructure
                         Red Hat Enterprise Linux Load Balancer (for RHEL Server)
                         from RHUI
    SKU:                 RC1116415
    Contract:            11314314
    Pool ID:             8a85f9815a71f0bd015a72445adf0223
    Provides Management: No
    Available:           20
    Suggested:           1
    Service Level:       Premium
    Service Type:        L1-L3
    Subscription Type:   Standard
    Ends:                02/23/2018
    System Type:         Physical
  2. サブスクリプションの pool ID を使用して、サブスクリプションを割り当てます。SKU とサブスクリプション名は 2 つあるため、各 <Pool ID> に対して subscription-manager attach --pool=<Pool ID> を実行する必要があります。

    # subscription-manager attach --pool=<Pool ID>
    Successfully attached a subscription for: <Subscription_Name>
    
    # subscription-manager attach --pool=<Pool ID>
    Successfully attached a subscription for: <Subscription_Name>

4.4. CDS ノードへのサブスクリプションの割り当て

手順

  1. CDS ノードに追加できるサブスクリプションを確認します。

    [root@<cds1> ~]# subscription-manager list --available
    +-------------------------------------------+
        Available Subscriptions
    +-------------------------------------------+
    Subscription Name:   <Your_Subscription_Name>
  2. Red Hat Update Infrastructure and RHEL Add-Ons for Providers サブスクリプションのプール ID を使用します。このサブスクリプションは、Red Hat Enterprise Linux および Gluster Storage へのアクセスを提供します。

    # subscription-manager attach --pool=<Pool_ID>
    Successfully attached a subscription for: Red Hat Update Infrastructure and RHEL Add-Ons for Providers

4.5. HAProxy ノードへのサブスクリプションの割り当て

手順

  1. HAProxy ノードに追加できるサブスクリプションを確認します。

    [root@<haproxy1> ~]# subscription-manager list --available
    +-------------------------------------------+
        Available Subscriptions
    +-------------------------------------------+
    Subscription Name:   <Your_Subscription_Name>
  2. Red Hat Update Infrastructure and RHEL Add-Ons for Providers サブスクリプションのプール ID を使用します。このサブスクリプションは、Red Hat Enterprise Linux および HAProxy へのアクセスを提供します。

    # subscription-manager attach --pool=<Pool_ID>
    Successfully attached a subscription for: Red Hat Update Infrastructure and RHEL Add-Ons for Providers

4.6. 必要なリポジトリーを有効にします。

注記

rhel-7-server-rhui-rpms リポジトリーはベース Red Hat Enterprise Linux リポジトリーで、必要なパッケージを指定する必要があります。rhel-7-server-rhui-rpmsrhel-7-server-rpms リポジトリーと同じで、-type=rhui コマンドを使用してシステムを登録すると自動的に使用されます。

RHUA ノードおよび CDS ノードには、ベースパッケージと、rhel-7-server-rpms 以外のすべてのリポジトリーが無効になっている Red Hat Enterprise Linux インストールが必要です。この要件は、サーバーの直接の操作に直接必要でないサードパーティーの設定またはソフトウェアもインストールできないことを意味します。この制限には、ハードニングやその他の Red Hat セキュリティーソフトウェアが含まれます。

手順

  1. 有効なリポジトリーの一覧を表示して、システムが正しくサブスクライブされていることを確認します。

    # yum repolist enabled
    Loaded plugins: search-disabled-repos
    rhel-7-server-rhui-rpms
    
    repo id                                           repo name                                                        status
    !local-rhui3                                      local-rhui3                                                         101
    !rhui-REGION-client-config-server-7/x86_64        Red Hat Update Infrastructure 2.0 Client Configuration Server 7       6
    !rhui-REGION-rhel-server-releases/7Server/x86_64  Red Hat Enterprise Linux Server 7 (RPMs)                         13,578
    !rhui-REGION-rhel-server-rh-common/7Server/x86_64 Red Hat Enterprise Linux Server 7 RH Common (RPMs)                  209
    repolist: 13,894
  2. RHUA のすべてのリポジトリーを無効にし、関連するリポジトリーを有効にします。

    [root@<rhua> ~]# subscription-manager repos --disable=*; subscription-manager repos --enable=rhel-7-server-rhui-rpms
  3. RHUI3 リポジトリーを有効にします。

    [root@<rhua> ~]# subscription-manager repos --enable=rhel-7-server-rhui-3-rpms
  4. CDS ノードのすべてのリポジトリーを無効にし、関連するものを有効にします。

    [root@<cds$> ~]# subscription-manager repos --disable=*; subscription-manager repos --enable=rhel-7-server-rhui-rpms --enable=rh-gluster-3-for-rhel-7-server-rhui-rpms
  5. RHUI3 リポジトリーを有効にします。

    [root@<cds$> ~]# subscription-manager repos --enable=rhel-7-server-rhui-3-rpms
  6. HAProxy ノードのすべてのリポジトリーを無効にし、関連するリポジトリーを有効にします。

    [root@<haproxy$> ~]# subscription-manager repos --disable=*; subscription-manager repos --enable=rhel-7-server-rhui-rpms
  7. RHUI3 リポジトリーを有効にします。

    [root@<haproxy$> ~]# subscription-manager repos --enable=rhel-7-server-rhui-3-rpms

バグの報告

第5章 共有ストレージ

Red Hat UpdateRow (RHUA) およびコンテンツ配信サーバー (CDS) には、両方がアクセス可能な共有ストレージボリュームが必要です。Red Hat Gluster Storage は Red Hat Enterprise Linux (RHEL) 7 で提供されていますが、その他のネットワークファイルシステム (NFS) ソリューションも使用できます。

5.1. Gluster Storage

5.1.1. 共有ストレージの作成

注記

glusterfs-server は、適切なサブスクリプションをお持ちの場合に限り利用できます。

インストールおよび管理の詳細については、Red Hat Gluster Storage のドキュメント を参照してください。特に、スプリットブレイン管理については、Red Hat Gluster Storage 3.4 管理ガイドの セクション 11.15 を参照してください。

警告

Red Hat Gluster Storage 3.4 以降では、arbiter ブリックを使用しない双方向レプリケーションは非推奨とみなされます。Arbiter ブリックを使用せずに双方向のレプリケーションを使用する既存のボリュームは、本リリースで引き続きサポートされます。この設定を含む新規ボリュームはサポートされません。Red Hat は、将来のバージョンの Red Hat Gluster Storage でサポートを完全に削除するために、arbiter ブリックやプランなしで双方向のレプリケーションを使用することを推奨しません。この変更は、アービターブリックを使用しない複製および分散複製ボリュームに影響します。

arbiter ブリックのない双方向レプリケーションは、スプリットブレイン条件から十分な保護を提供しないため非推奨になりました。分散レプリケーションの設定でも、双方向レプリケーションでは、結合するノードを使用せずに競合するファイルの正しいコピーが選択されていることを確認できません。

Red Hat は、3 ノードの Gluster Storage ボリュームを使用することを推奨します。

3 方向のレプリケーションに関する情報は、Red Hat Gluster Storage 3.4 管理ガイドの セクション 5.6.2 の Creating Three-way Replicated Volumes および セクション 5.7.2Red Hat Gluster Storage 3.4 Administration Guide を参照してください。

共有ストレージに関する懸念は、raw ディスクが原因でディスク使用量が 100% に近づくとブロックストレージサイズを拡張できなくなることです。通常、Gluster Storage は物理サーバーで機能し、そのブリックは内部ストレージです。物理サーバーの場合、ブリックのディスクは、内部の物理ディスク全体に割り当てられている場合は拡張できません。一般的なストレージの使用では、ブリックは論理ボリュームマネージャー (LVM) に配置する必要があります。

以下の手順では、3 つのノードの Gluster Storage を使用して LVM に共有ボリュームを作成し、必要なパッケージをインストールする方法を説明します。別のストレージソリューションを使用している場合は、製品ドキュメントを参照してください。

手順

  1. すべての CDS ノードで以下の手順を実行します。この例は、cds1 を示しています。

    [root@cds1 ~]# yum install glusterfs-server glusterfs-cli rh-rhua-selinux-policy
  2. 新しいディスクに物理ボリュームを初期化します。

    # pvcreate /dev/vdb
  3. /dev/vdb にボリュームグループを作成します。

    # vgcreate vg_gluster /dev/vdb
  4. LVM に論理ボリュームを作成します。

    # lvcreate -n lv_brick1 -l 100%FREE vg_gluster
  5. デバイスをフォーマットします。

    mkfs.xfs -f -i size=512 /dev/mapper/vg_gluster-lv_brick1
  6. mount ディレクトリーを作成し、ディスクをマウントし、glusterd を有効にして、glusterd を起動します。

    # mkdir -p /export/xvdb; mount /dev/mapper/vg_gluster-lv_brick1 /export/xvdb; mkdir -p /export/xvdb/brick; systemctl enable glusterd.service; systemctl start glusterd.service
  7. 各 CDS ノードの /etc/fstab に以下のエントリーを追加します。

    /dev/mapper/vg_gluster-lv_brick1 /export/xvdb xfs defaults 0 0
  8. cds1 など、CDS ノードでのみ以下の手順を実行します。

    [root@cds1 ~]# gluster peer probe cds2.example.com
    peer probe: success.
    [root@cds1 ~]# gluster peer probe cds3.example.com
    peer probe: success.
    注記

    DNS 解決が機能していることを確認します。以下に、名前解決エラーを示します。

    [root@cds1 ~]# gluster peer probe <cds[23].example.com hostnames>
     peer probe: failed: Probe returned with Transport endpoint is not connected
    重要

    コミュニケーションやポートの問題がある場合は、peer probe: failed: Probe returned with Transport endpoint is not connected エラーが発生して Gluster ピアプルーブで失敗する場合があります。この障害を回避するには、firewalld サービスを無効にします。ファイアウォールを無効にしない場合は、セクション 3.1、Red Hat Gluster ストレージ管理ガイド 3.4 のポートアクセス の確認で説明されているように正しいポートを許可できます。

  9. 次に進む前に、ピア接続が成功したことを確認します。同様の出力が表示されるはずです。

    [root@cds1 ~]# gluster peer status
    Number of Peers: 2
    Hostname: cds2.v3.example.com
    Uuid: 6cb9fdf9-1486-4db5-a438-24c64f47e63e
    State: Peer in Cluster (Connected)
    Hostname: cds3.v3.example.com
    Uuid: 5e0eea6c-933d-48ff-8c2f-0228effa6b82
    State: Peer in Cluster (Connected)
    [root@cds1 ~]# gluster volume create rhui_content_0 replica 3 \
    cds1.example.com:/export/xvdb/brick cds2.example.com:/export/xvdb/brick \
    cds3.example.com:/export/xvdb/brick
    volume create: rhui_content_0: success: please start the volume to access data
    [root@cds1 ~]# gluster volume start rhui_content_0
    volume start: rhui_content_0: success

5.1.2. ストレージボリュームの拡張

ディスクのボリュームの容量が満杯に近づいている場合は、同じサイズの新規ディスクを各 CDS ノードに追加し、それぞれの CDS ノードで次のコマンドを実行すると、ディスクのボリュームを拡張できます。ディスクを表すデバイスファイルの名前は使用するテクノロジーによって異なりますが、最初のディスクが /dev/vdb の場合は、2 番目のディスクは /dev/vdc になります。以下の手順の device ファイルを、実際のデバイス名に置き換えます。

手順

  1. 新しいディスクに物理ボリュームを初期化します。

    # pvcreate /dev/vdc
  2. 論理ボリュームグループを拡張します。

    # vgextend vg_gluster /dev/vdc
  3. 新しい物理ボリュームの空きディスク容量だけ論理ボリュームを拡張します。

    # lvextend vg_gluster/lv_brick1 /dev/vdc
  4. ファイルシステムを拡張します。

    # xfs_growfs /dev/mapper/vg_gluster-lv_brick1
  5. RHUA ノードで df を実行して、マウントした Gluster Storage ボリュームのサイズが変更することを確認します。

5.2. NFS ストレージの作成

RHUA ノードまたは専用マシンで、RHUI が管理するコンテンツ用 NFS サーバーを設定できます。NFS を使用してストレージをセットアップするには、次の手順を使用します。

重要

専用マシンを使用すると、CDS ノード (主に RHUI クライアント) が RHUA ノードに関連している場合に機能を継続できます。Red Hat は、専用のマシンに NFS サーバーを設定することを推奨します。

手順

  1. NFS サーバーをホストするノードに、RHUA ノード (異なる場合) およびすべての CDS ノードに nfs-utils パッケージをインストールします。

    # yum install nfs-utils
  2. NFS サーバーの /etc/exports ファイルを編集します。RHUI コンテンツを保持する適切なディレクトリーを選択し、RHUA ノードおよびすべての CDS ノードがこれにアクセスできるようにします。たとえば、/export ディレクトリーを使用して、example.com ドメイン内のすべてのシステムで使用できるようにするには、/etc/exports に次の行を入力します。

    /export *.example.com(rw,no_root_squash)
  3. /export で定義されている RHUI コンテンツのディレクトリーを作成します。

    # mkdir /export
  4. NFS サービスを開始して有効にします。

    # systemctl start nfs
    # systemctl start rpcbind
    # systemctl enable nfs-server
    # systemctl enable rpcbind
    注記

    既存の NFS サーバーを使用していて、NFS サービスが実行されている場合は、start コマンドの代わりに restart コマンドを使用します。

  5. 設定のテストCDS ノードで次のコマンドを実行します。これは、NFS サーバーが filer.example.com という名前のマシンに設定されていることを前提としています。

    # mkdir /mnt/nfstest
    # mount filer.example.com:/export /mnt/nfstest
    # touch /mnt/nfstest/test

    エラーメッセージは取得しないでください。

  6. このテストの後にクリーンアップするには、test ファイルを削除し、リモート共有のマウント解除して、test ディレクトリーを削除します。

    # rm /mnt/nfstest/test
    # umount /mnt/nfstest
    # rmdir /mnt/nfstest

    これで NFS サーバーがセットアップされました。RHEL 7 で NFS サーバーを設定する方法は、セクション 8.7 NFS サーバーの設定を参照してください。

バグの報告

第6章 Red Hat Update Infrastructure のインストール

以下のセクションでは、Red Hat Update Infrastructure のインストール方法を説明します。

6.1. RSA 鍵ペアを生成します。

重要

Red Hat Update Centre (RHUA) ノードで RSA 鍵ペアを生成し、公開鍵をコンテンツ配信サーバー (CDS) および HAProxy ノードにコピーして、rhui-manager が CDS ノードおよび HAProxy ノードを設定できるようにする必要があります。

6.1.1. SSH プロトコルのバージョン 2 用の RSA 鍵ペア

以下の手順に従って、SSH プロトコルのバージョン 2 用の RSA 鍵ペアを生成します。

手順

  1. RSA 鍵ペアを生成します。

    [USER@rhua ~]$ ssh-keygen -t rsa
    Generating public/private rsa key pair.
    Enter file in which to save the key (/home/USER/.ssh/id_rsa):
  2. Enter キーを押して、新規作成される鍵のデフォルトの場所 (~/.ssh/id_rsa) を確認します。
  3. passphrase フィールドを空白のままにしておきます。鍵ペアの生成中にパスフレーズを指定すると、CDS のインストールと登録に失敗します。

    Your identification has been saved in /home/USER/.ssh/id_rsa.
    Your public key has been saved in /home/USER/.ssh/id_rsa.pub.
    The key fingerprint is:
    e7:97:c7:e2:0e:f9:0e:fc:c4:d7:cb:e5:31:11:92:14 USER@rhua.example.com
    The key's randomart image is:
    +--[ RSA 2048]----+
    |             E.  |
    |            . .  |
    |             o . |
    |              . .|
    |        S .    . |
    |         + o o ..|
    |          * * +oo|
    |           O +..=|
    |           o*  o.|
    +-----------------+
  4. デフォルトで、~/.ssh/ ディレクトリーのパーミッションは、rwx------ または 8 進数表記の 700 に設定されます。これは、<$USER> のみがコンテンツを表示できるようにする設定です。必要に応じて、次のコマンドで確認できます。

    [USER@rhua ~]$ ls -ld ~/.ssh
    drwx------. 2 USER USER 54 Nov 25 16:56 /home/USER/.ssh/
  5. 公開鍵を HAProxy ノードおよび CDS ノードにコピーします。

    [USER@rhua ~]$ ssh-copy-id user@<haproxy1>
    [USER@rhua ~]$ ssh-copy-id user@<cds1>
    [USER@rhua ~]$ ssh-copy-id user@<cds2>

    これにより、最近変更した ~/.ssh/id*.pub 公開鍵がインストールされていない場合は、その公開鍵をコピーします。または、公開鍵のファイルを指定します。

    [USER@rhua ~]$ ssh-copy-id -i ~/.ssh/id_rsa.pub user@hostname

    これにより、~/.ssh/id_rsa.pub の内容が、接続するマシンの ~/.ssh/authorized_keys ファイルにコピーされます。ファイルが存在する場合は、鍵がその最後に追加されます。

6.1.2. SSH プロトコルのバージョン 2 用の ECDSA 鍵ペア

SSH プロトコルのバージョン 2 用の ECDSA 鍵ペアを生成するには、以下の手順に従います。

手順

  1. ECDSA 鍵ペアを生成します。

    [USER@rhua ~]$ ssh-keygen -t ecdsa
    Generating public/private ecdsa key pair.
    Enter file in which to save the key (/home/USER/.ssh/id_ecdsa):
  2. Enter キーを押して、新規作成された鍵用のデフォルトの場所 (~/.ssh/id_ecdsa) を確認します。
  3. passphrase フィールドを空白のままにしておきます。鍵ペアの生成中にパスフレーズを指定すると、CDS のインストールと登録に失敗します。

    [USER@rhua ~]$
    Your identification has been saved in /home/USER/.ssh/id_ecdsa.
    Your public key has been saved in /home/USER/.ssh/id_ecdsa.pub.
    The key fingerprint is:
    fd:1d:ca:10:52:96:21:43:7e:bd:4c:fc:5b:35:6b:63 USER@rhua.example.com
    The key's randomart image is:
    +--[ECDSA  256]---+
    |       .+ +o     |
    |       . =.o     |
    |        o o +  ..|
    |         + + o  +|
    |        S o o oE.|
    |           + oo+.|
    |            + o  |
    |                 |
    |                 |
    +-----------------+
  4. デフォルトで、~/.ssh/ ディレクトリーのパーミッションは、rwx------ または 8 進数表記の 700 に設定されます。これは、<$USER> のみがコンテンツを表示できるようにする設定です。必要に応じて、これを確認できます。

    [USER@rhua ~]$ ls -ld ~/.ssh
    drwx------. 2 USER USER 54 Nov 25 16:56 /home/USER/.ssh/
  5. 公開鍵を HAProxy ノードおよび CDS ノードにコピーします。

    [USER@rhua ~]$ ssh-copy-id user@<haproxy1>
    [USER@rhua ~]$ ssh-copy-id user@<cds1>
    [USER@rhua ~]$ ssh-copy-id user@<cds2>

    これにより、最近変更した ~/.ssh/id*.pub 公開鍵がインストールされていない場合は、その公開鍵をコピーします。または、公開鍵のファイルを指定します。

    [USER@rhua ~]$ ssh-copy-id -i ~/.ssh/id_ecdsa.pub USER@hostname

    これにより、~/.ssh/id_ecdsa.pub の内容が、接続するマシンの ~/.ssh/authorized_keys にコピーされます。ファイルが存在する場合は、鍵がその最後に追加されます。

6.2. 更新の適用

手順

  1. Red Hat Update Appliance (RHUA) パッケージをインストールする前に、利用可能なオペレーティングシステムの更新をすべてのノード (RHUA、コンテンツ配信サーバー [CDS]、HAProxy) に適用し、再起動します。
  2. すべての設定変更が永続化されていることを確認します。

    警告

    RHUA のホスト名が正しく設定されていることを確認してください。ホスト名が設定されておらず、その値が localhost.localdomain または localhost として報告される場合は、続行できなくなります。

6.3. Red Hat Update Infrastructure ISO のマウント

注記

このセクションはオプションで、サブスクリプションを使用して Red Hat Update Infrastructure 3.1.9 をインストールする場合は省略できます。

手順

  1. RHUI パッケージを RHUA ノード、CDS ノード、および HAProxy ノードにインストールするには、ISO を適切なディレクトリーにマウント (または ISO を CD に書き込み、CD を挿入して ISO をマウント) して、マウントポイントを入力します。

6.4. setup_package_repos スクリプトを実行します。

注記

このセクションはオプションで、サブスクリプションを使用して Red Hat Update Infrastructure 3.1.9 をインストールする場合は省略できます。

setup_package_repos スクリプトは、RHUI ISO イメージのルートディレクトリーにあります。

重要

setup_package_repos スクリプトは、RHUI パッケージが Red Hat Release 鍵で署名される必要がある yum 設定エントリーを作成します。

RHUA ノード、CDS ノード、および HAProxy ノードで次の手順を実行して、RHUI パッケージをインストールします。

手順

  1. 該当するシステムコンポーネントのマウントポイントからスクリプトを実行します。

    [root@rhua ~]# ./setup_package_repos
    [root@<cds1> ~]# ./setup_package_repos
    [root@<haproxy1> ~]# ./setup_package_repos

6.5. rhui-installer スクリプトのインストール

手順

  1. rhui-installer スクリプトのインストール

    [root@rhua ~]# yum install -y rhui-installer
    This script will install the RHUI packages on the current machine.
    - Ensuring we are in an expected directory.
    - Copying installation files.
    - Creating a Repository File
    - Importing the gpg key.
    - Installation repository will remain configured for future package installs.
    - Installation media can now be safely unmounted.
    
    Installation packages are now available on this system. If you are installing a RHUA, please run yum install -y rhui-installer; rhui-installer.
    If you are installing a CDS, please log into the RHUA and run rhui-manager to begin the installation. Do not run rhui-installer to install a CDS.

6.6. rhui-installer の実行

rhui-installer は、Red Hat Update Infrastructure の初期ログインパスワードを設定し、これを出力に表示します。これは、/etc/rhui-installer/answers.yaml ファイルでも記述されます。--rhui-manager-password オプションを使用して初期パスワードを上書きできます。後で初期パスワードを変更する場合は、rhui-manager ツールからしか変更できません。rhui-installer --help コマンドを実行して、rhui-installer オプションの完全なリストを確認します。

手順

  1. RHUA で rhui-installer を実行します。

    [root@rhua ~]# rhui-installer --remote-fs-type=glusterfs --remote-fs-server=cds1.example.com:rhui_content_0 --cds-lb-hostname=cds.example.com
    
    Installing         	Done                                           	[100%]
    
    [..............................................................................]
    
    Success!
    The initial credentials are admin / <system-generated password>
    
    Re-running the installer will not update your password.
    
    The full log is at /var/log/kafo/configuration.log

    以下は、コマンド引数の説明です。

    • --remote-fs-type=glusterfs は、リモートファイルシステムのタイプが GlusterFS であることを示しています。
    • --remote-fs-server=cds1.example.com は、リモートファイルシステムサーバーの名前が cds1.example.com であることを示しています。
    • rhui_content_0 は、cds1.example.com 上の GlusterFS ボリュームの名前を示しています。
    • --cds-lb-hostname=cds.example.com は cds1.example.com 上のロードバランサーの名前を示しています。

      注記

      インストール時に、cds-lb-hostname オプションは含まれず、rhui-installer RPM で提供されるアンサーファイルから事前に設定されます。ホスト名は cds.example.com へのアンサーファイルで事前設定され、この cds-lb-hostname が含まれる RHUI 環境用の証明書が作成されます。詳細は、18章新しいロードバランサーに移行するか、既存のロードバランサーの名前を変更します。 ロードバランサーの名前の変更の

      NFS を使用している場合、rhui-installer コマンドラインは異なります。次の内容ではなく、

      --remote-fs-type=glusterfs --remote-fs-server=cds1.example.com:rhui_content_0

      --remote-fs-server オプションのパラメーターとして、コロン記号で参加する NFS サーバー名とエクスポートされたディレクトリーを指定します。以下に例を示します。

      --remote-fs-server=filer.example.com:/export
  2. リモート共有がマウントされていることを確認します。

    [root@rhua ~]# mount | grep rhui
    
    cds1.example.com:rhui_content_0 on /var/lib/rhui/remote_share type fuse.glusterfs (rw,relatime,user_id=0,group_id=0,default_permissions,allow_other,max_read=131072)

6.7. 初期パスワードの変更

注記

rhui-installer を再実行しても、rhui-manager ログインパスワードは更新されません。

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
    
    Previous authentication credentials could not be found. Logging into the RHUI.
    
    If this is the first time using the RHUI, it is recommended to change the user's password in the User Management section of RHUI Tools.
  2. RHUI ユーザー名 (管理者) および RHUI パスワード (rhui-installer 出力で提供されます) を入力します。初期パスワードは /etc/rhui-installer/answers.yaml に保存されます。
  3. 初回ログインが正常に完了したら、パスワードを変更する必要があります。Red Hat Update Infrastructure Management Tool のホーム画面で u を押して、manage RHUI users を選択します。

                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
       r   manage repositories
       c   manage content delivery servers (CDS)
       l   manage HAProxy load-balancer instances
       s   synchronization status and scheduling
       e   create entitlement certificates and client configuration RPMs
       n   manage Red Hat entitlement certificates
       u   manage RHUI users
    
                                                       Connected: rhua.example.com
  4. p を押して、p change a user's password (followed by logout) を選択します。

    ------------------------------------------------------------------------------
    = Red Hat Update Infrastructure Management Tool =
    
    = User Manager =
    
      p   change a user's password (followed by logout)
    
                                                  	Connected: rhua.example.com
    
    ------------------------------------------------------------------------------
    rhui (users) => p
    Warning: After password change you will be logged out.
    Use ctrl-c to cancel password change.
    Username: admin
  5. 新しいパスワードを入力して、Enter を押します。新しいパスワードを再入力して、Enter を押します。

    New Password:
    Re-enter Password:
    
    Password successfully updated.
    ----------------------------------------------------------------------------------

6.8. エンタイトルメント証明書の自動更新の有効化

Red Hat Update Infrastructure エンタイトルメント証明書を自動的に更新するように設定します。自動更新は、エンタイトルメント証明書の期限が切れるたびに、または Red Hat Subscription Management サービスで取り消すと発生する可能性があります。

RHUA ノードの /etc/cron.hourly/synchronize-rhui-subscriptions にあるサブスクリプション同期サービスは、証明書の有効性を 1 時間ごとにチェックします。自動更新サービスが機能するようにするには、rhui-manager ユーザー名およびパスワードが /etc/rhui/rhui-subscription-sync.conf ファイルに設定されていることを確認してください。デフォルトでは、このファイルには以下の設定が含まれています。

username = admin
password =

「初期パスワードの変更」 の説明に従ってパスワードを変更すると、新しいパスワードが /etc/rhui/rhui-subscription-sync.conf ファイルに保存されます。パスワードを変更しなかった場合や、rhui-manager ユーザー名が admin でない場合は、このファイルを編集して rhui-manager パスワードを設定します。

重要

サブスクリプションの同期サービスは、Red Hat との契約が期限内で、サブスクリプションが有効になっている場合に限り利用できます。サービスはエンタイトルメント証明書を更新できますが、サブスクリプション自体は更新できません。

注記

サブスクリプション同期サービスは、そのアクションを /var/log/rhui-subscription-sync.log ファイルに記録します。

6.9. 追加パッケージのインストール

現在、RHUA にインストールできる追加パッケージは QpidPersistenceExtension のみです。デフォルトでは、同期するリポジトリーの数は限られています。正確な数は、/etc/default/pulp_workers ファイルの PULP_CONCURRENCY 変数で制御されます。これは、RHUI のインストール時に検出された CPU の数に応じて自動的に 3 または 8 に設定されていました。さらに多くのリポジトリーの同期をスケジュールすると、制限を超えるリポジトリーは、実行中の同期タスクが完了するまで待機状態のままになります。システムを再起動するか、Qpid を再起動すると、待機中のタスクは失われます。

手順

  1. 待機中のタスクが失われないように、待機中のタスクがある間は Qpid を再起動または再起動しないでください。多くの場合は、Qpid 永続拡張をインストールすることで、少なくとも待機中のタスクを維持できます。

    # yum install qpid-cpp-server-linearstore
  2. Qpid を再起動して、拡張を読み込みます。

    # systemctl restart qpidd

    待機中のタスクはディスクに保存され、再起動後に再開されます。

第7章 コンテンツ配信サーバーの追加または削除

7.1. コンテンツ配信サーバーの追加

Red Hat Update Infrastructure Management Tool は、Red Hat Update Infrastructure (RHUI) 内でコンテンツ配信サーバー (CDS) を設定するオプションを複数提供します。CDS の追加は、Red Hat Update Infrastructure 3.1.9 の Red Hat Update Infrastructure 3.1.8 とは異なります。Red Hat Update Infrastructure 3.1.8 で事前に設定された CDS を追加するのではなく、Red Hat Update Centre (RHUA) の Add ステップで CDS サービスもインストールします。

手順

  1. sshd が CDS ノードで実行されており、ポート 443 および 5000 が開いていることを確認します。
  2. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
  3. c を押して manage content delivery servers (CDS) を選択します。

                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
       r   manage repositories
       c   manage content delivery servers (CDS)
       l   manage HAProxy load-balancer instances
       s   synchronization status and scheduling
       e   create entitlement certificates and client configuration RPMs
       n   manage Red Hat entitlement certificates
       u   manage RHUI users
    
                                                       Connected: rhua.example.com
  4. a を入力して、register (add) a new Content Delivery Server instance を選択します。

    ------------------------------------------------------------------------------
    = Red Hat Update Infrastructure Management Tool =
    
    = Content Delivery Server (CDS) Management =
    
    l   list all known CDS instances managed by the RHUI
    a   register (add) a new CDS instance
    r   reinstall and reapply configuration to an existing CDS instance
    d   unregister (delete) a CDS instance from the RHUI
    
                                                  	Connected: rhua.example.com
    ------------------------------------------------------------------------------
    rhui (cds) => a
  5. 追加する CDS のホスト名を入力します。

    Hostname of the CDS instance to register:
    cds1.example.com
  6. CDS への SSH アクセスがあり、sudo 権限を持つユーザー名を入力します。

    Username with SSH access to <cds1.example.com> and sudo privileges:
    root
  7. CDS にログインするために SSH 秘密鍵への絶対パスを入力し、Enter を押します。

    Absolute path to an SSH private key to log into <cds1.example.com> as root:
    /root/.ssh/id_rsa
    .........................................................................
    The following CDS has been successfully added:
    
    Hostname:             <cds1.example.com>
    SSH Username:     root
    SSH Private Key:  /root/.ssh/id_rsa
    
    The CDS will now be configured:
    …………………………………………………………..
    The CDS was successfully configured.
  8. コンテンツ配信サーバーを追加できない場合は、ファイアウォールルールが RHUA と CDS 間のアクセスを許可していることを確認します。
  9. mount コマンドを実行して、Gluster Storage が読み取り/書き込みとしてマウントされているかどうかを確認します。

    [root@rhua ~]# mount | grep cds1.example.com
    
    cds1.example.com:rhui_content_0 on /var/lib/rhui/remote_share type fuse.glusterfs (rw,relatime,user_id=0,group_id=0,default_permissions,allow_other,max_read=131072)
  10. 設定に成功すると、残りの CDS に対してこれらの手順を繰り返します。コマンドラインインターフェイスを使用して CDS を追加することもできます。

    [root@rhua ~]# rhui cds add cds1.example.com root /root/.ssh/id_rsa -u

7.2. コンテンツ配信サーバーの登録解除

次の手順を使用して、使用しない CDS インスタンスの登録を解除 (削除) します。

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
  2. c を押して、manage content delivery servers (CDS) を選択します。

    -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
    r   manage repositories
    c   manage content delivery servers (CDS)
    l   manage HAProxy load-balancer instances
    s   synchronization status and scheduling
    e   create entitlement certificates and client configuration RPMs
    n   manage Red Hat entitlement certificates
    u   manage RHUI users
    
                                                          Connected: rhua.example.com
  3. d と入力して、unregister (delete) a CDS instance from the RHUI を選択します。

    ------------------------------------------------------------------------------
    = Red Hat Update Infrastructure Management Tool =
    
    = Content Delivery Server (CDS) Management =
    
    l   list all known CDS instances managed by the RHUI
    a   register (add) a new CDS instance
    r   reinstall and reapply configuration to an existing CDS instance
    d   unregister (delete) a CDS instance from the RHUI
    
                                                       Connected: rhua.example.com
    ------------------------------------------------------------------------------
     rhui (cds) => d
  4. 削除する CDS のホスト名を入力します。

    Hostname of the CDS instance to unregister:
    cds1.example.com
  5. HAProxy インスタンスの /etc/haproxy/haproxy.cfg ファイルを確認します。

    #  cat /etc/haproxy/haproxy.cfg

バグの報告

7.3. レガシー CA を許可するようにコンテンツ配信サーバーを設定

CDS ノードは通常、RHUI 3 で現在設定されている認証局 (CA) によって署名されたエンタイトルメント証明書のみを受け入れます。メインの CA を変更したり、CA 証明書の期限が切れた場合にクライアントが引き続き機能できるように、以前に作成したその他の CA を受け入れることができます。RHUI 3 は、従来の CA の概念に対応しています。ここでは、CDS ノードに他の CA 証明書をインストールして、使用できるようにできます。

手順

  1. すべての RHUI ノードがバージョン 3.1 以降を実行していることを確認します。RHUI を旧バージョンからインストールした場合は、まず rhui-manager で CDS ノードを再インストールする必要もあります。
  2. レガシーの CA 証明書を CDS ノードに移動し、/etc/pki/rhui/legacy-ca/ ディレクトリーに保存します。
  3. 証明書からサブジェクトのハッシュ値を取得し、シェル変数に保持します。

    #hash=`openssl x509 -hash -noout -in /etc/pki/rhui/legacy-ca/YOUR_CERT.crt`
  4. ハッシュと、シンボリックリンク名として 0 から始まる未使用の番号を持つ /etc/pki/tls/certs/ ディレクトリー内の証明書ファイルへのシンボリックリンクを作成します。

    #ln -s /etc/pki/rhui/legacy-ca/YOUR_CERT.crt /etc/pki/tls/certs/$hash.0

このアクションはすぐに有効になります。

注記

証明書の受け入れを停止する場合は、シンボリックリンクと証明書ファイルを削除して、httpd サービスを再起動します。

第8章 HAProxy ロードバランサーの追加

複数の HAProxy ノードを使用し、すべての HAProxy ノードの IP アドレスを解決する rhui-installer を実行する際 (「rhui-installer の実行」 を参照) に --cds-lb-hostname パラメーターの値として使用したホスト名のラウンドロビン DNS エントリーを設定していない場合、3章Red Hat Update Infrastructure のインストールの前提条件 で詳細を参照してください。

手順

  1. sshd が HAProxy ノードで実行されており、ポート 443 および 5000 が開いていることを確認します。
  2. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
  3. Red Hat Update Infrastructure Management Tool のホーム画面で、l を押して manage HAProxy load-balancer instances を選択します。

                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
       r   manage repositories
       c   manage content delivery servers (CDS)
       l   manage HAProxy load-balancer instances
       s   synchronization status and scheduling
       e   create entitlement certificates and client configuration RPMs
       n   manage Red Hat entitlement certificates
       u   manage RHUI users
    
                                                       Connected: rhua.example.com
  4. a を押して、register (add) a new HAProxy Load-balancer instance を選択します。

    ------------------------------------------------------------------------------
    = Red Hat Update Infrastructure Management Tool =
    
    = Load-balancer (HAProxy) Management =
    
    l   list all known HAProxy Load-balancer instances managed by the RHUI
    a   register (add) a new HAProxy Load-balancer instance
    r   reinstall and reapply configuration to an existing HAProxy Load-balancer instance
    d   unregister (delete) a HAProxy Load-balancer instance from the RHUI
    
                                                  	Connected: rhua.example.com
    ------------------------------------------------------------------------------
    
    rhui (loadbalancers) => a
  5. 追加する HAProxy のホスト名を入力します。

    Hostname of the HAProxy Load-balancer instance to register:
    haproxy1.example.com
  6. HAProxy ロードバランサーへの SSH アクセスがあり、sudo 権限を持つユーザー名を入力します。

    Username with SSH access to haproxy1.example.com and sudo privileges:
    root
  7. HAProxy ロードバランサーにログインするために SSH 秘密鍵に絶対的な部分を入力し、Enter を押します。

    Absolute path to an SSH private key to log into haproxy1.example.com as root:
    /root/.ssh/id_rsa
    .........................................................................
    
    The following HAProxy Load-balancer has been successfully added:
    
    Hostname:            <haproxy1.example.com>
    SSH Username:   root
    
    SSH Private Key:  /root/.ssh/id_rsa
    
    The HAProxy Load-balancer will now be configured:
    …………………………………………………………..
    
    The HAProxy Load-balancer was successfully configured.
  8. 設定に成功すると、残りの HAProxy ロードバランサーについてこの手順を繰り返します。コマンドラインインターフェイスを使用して HAProxy ロードバランサーを追加することもできます。

    # rhui haproxy add <haproxy1.example.com> root /root/.ssh/id_rsa -u

バグの報告

第9章 Red Hat リポジトリーの作成および同期

9.1. リポジトリーの作成

手順

  1. Red Hat Update Centre (RHUA) で、Red Hat Update Infrastructure Management Tool にログインします。

    [root@rhua ~]# rhui-manager
  2. Red Hat Update Infrastructure Management Tool のホーム画面で r を押して、manage repositories を選択します。

                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
       r   manage repositories
       c   manage content delivery servers (CDS)
       l   manage HAProxy load-balancer instances
       s   synchronization status and scheduling
       e   create entitlement certificates and client configuration RPMs
       n   manage Red Hat entitlement certificates
       u   upload content to a custom repository (RPM content only)
       ur  upload content from a remote web site (RPM content only)
       p   list packages in a repository (RPM content only)
    
    Connected: rhua.example.com
  3. a を押して、add a new Red Hat content repository を選択します。

    ----------------------------------------------------------------------------------
            	-= Red Hat Update Infrastructure Management Tool =-
    
    = Repository Management =-
    
    l   list repositories currently managed by the RHUI
    i   display detailed information on a repository
    a   add a new Red Hat content repository
    c   create a new custom repository (RPM content only)
    d   delete a repository from the RHUI
    u   upload content to a custom repository (RPM content only)
    ur  upload content from a remote web site (RPM content only)
    p   list packages in a repository (RPM content only)
    
    Connected: rhua.example.com
    ------------------------------------------------------------------------------
    
    rhui (repo) => a
  4. Red Hat Update Infrastructure Management Tool がエンタイトルメントのあるリポジトリーを判断するのを待ちます。これは数分の時間がかかる可能性があります。

    Connected: rhua.example.com
    
    ------------------------------------------------------------------------------
    
    rhui (repo) => a
    
    Loading latest entitled products from Red Hat...
    
    Determining undeployed products...
  5. Red Hat Update Infrastructure Management Tool は、選択方法を求めるプロンプトを表示します。

    ... product list calculated
    
    Import Repositories:
    
    1  - All in Certificate
    2  - By Product
    3  - By Repository
    
    Enter value (1-3) or 'b' to abort:
  6. 2 を押して、By Product メソッドを選択します。
  7. 追加する各リポジトリーの横にある番号を入力して、RHUA に Red Hat リポジトリーを追加します。表示されるリポジトリーは、エンタイトルメント証明書に含まれるが、まだ追加されていない Red Hat リポジトリーのみです。
  8. リポジトリーの選択が終了したら c を押します。Red Hat Update Infrastructure Management Tool は、デプロイするリポジトリーを表示し、確認を求めるプロンプトを表示します。
  9. y を押して先に進みます。画面メッセージは、デプロイメントが成功したたびに表示されます。
  10. l を押して RHUI 画面で現在管理されているリストリポジトリー にアクセスして、正しいリポジトリーがインストールされていることを確認します。

9.2. リポジトリーを同期します。

Red Hat コンテンツの初期同期には、通常 10 分から 20 分かかります。できるだけ早く同期を開始します。

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
  2. s を押して、同期の状態とスケジューリング を選択します。

                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
       r   manage repositories
       c   manage content delivery servers (CDS)
       l   manage HAProxy load-balancer instances
       s   synchronization status and scheduling
       e   create entitlement certificates and client configuration RPMs
       n   manage Red Hat entitlement certificates
       u   manage RHUI users
    
    Connected: rhua.example.com
  3. sr を押して、sync an individual repository immediatelyを選択します。

    ------------------------------------------------------------------------------
            	-= Red Hat Update Infrastructure Management Tool =-
    
    -= Synchronization Status =-
    
    dr  display repo sync summary
    vr  view the details of the last repository sync
    sr  sync an individual repository immediately
    
    Connected: rhua.example.com
    
    ------------------------------------------------------------------------------
  4. リポジトリーを選択し、c を押して確定します。
  5. y を押して先に進みます。
  6. dr を入力して、display repo sync summary を選択します。

    ------------------------------------------------------------------------------
    
    rhui (sync) => dr
    ------------------------------------------------------------------------------
            	-= Red Hat Update Infrastructure Management Tool =-
    
    -= Repository Synchronization Status =-
    
    Last Refreshed: 13:59:27
    
    (updated every 5 seconds, ctrl+c to exit)
    
    Next Sync                	Last Sync                	Last Result
    
    ------------------------------------------------------------------------------
    
    Red Hat Enterprise Linux 7 Server - Extras from RHUI (RPMs) (x86_64)
    
    02-29-2016 19:54         	02-29-2016 13:59         	Success
    
    Connected: rhua.example.com
    ------------------------------------------------------------------------------

関連情報

  • 詳細は、リンクを参照してください。

第10章 クライアントエンタイトルメント証明書およびクライアント設定 RPM

10.1. エンタイトルメント証明書の作成

手順

  1. RHUA で、Red Hat Update Infrastructure Management Tool にログインします。

    [root@rhua ~]# rhui-manager
  2. Red Hat Update Infrastructure Management Tool のホーム画面で e を押して、エンタイトルメント証明書およびクライアント設定 RPM の作成 を選択します。

                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
       r   manage repositories
       c   manage content delivery servers (CDS)
       l   manage HAProxy load-balancer instances
       s   synchronization status and scheduling
       e   create entitlement certificates and client configuration RPMs
       n   manage Red Hat entitlement certificates
       u   manage RHUI users
    
                                                       Connected: rhua.example.com
  3. e を押して generate an entitlement certificate を選択します。

    ------------------------------------------------------------------------------
            	-= Red Hat Update Infrastructure Management Tool =-
    
    -= Client Entitlement Management =-
    
    e   generate an entitlement certificate
    c   create a client configuration RPM from an entitlement certificate
    
                                                  	Connected: rhua.example.com
    ------------------------------------------------------------------------------
    
    rhui (client) => e
  4. プロンプトでリポジトリーの番号を入力して、エンタイトルメント証明書に含めるリポジトリーを選択します。リポジトリーの数を入力すると、そのリポジトリー名の横にチェックマークが付けられます。追加するすべてのリポジトリーがチェックされるまで続行します。

    重要

    単一の Red Hat Enterprise Linux バージョンのリポジトリーのみを 1 つのエンタイトルメントに追加します。複数の Red Hat Enterprise Linux バージョンにリポジトリーを追加すると、yum 設定ファイルが使用できなくなります。

  5. プロンプトで c を押して確定します。
  6. 証明書の名前を入力します。この名前は、Red Hat Update Infrastructure Management Tool 内で証明書を特定し、証明書およびキーファイルの名前を生成するのに役立ちます。

    Name of the certificate. This will be used as the name of the certificate file
    (name.crt) and its associated private key (name.key). Choose something that will
    help identify the products contained with it:
  7. 証明書を保存するパスを入力します。フィールドを空白のままにして、現在の作業ディレクトリーに保存します。
  8. 証明書が有効な日数を入力します。365 日の場合はフィールドを空白のままにしておきます。証明書に含まれるリポジトリーの詳細が表示されます。
  9. プロンプトで y を押して、情報を確認し、エンタイトルメント証明書を作成します。

    Repositories to be included in the entitlement certificate:
    
    Red Hat Repositories
    
    	Red Hat Enterprise Linux for SAP (RHEL 6 Server) (RPMs) from RHUI
    
    Proceed? (y/n) y
    .................................................+++
    Entitlement certificate created at /root/clientcert/rhuiclientexample.crt
    
    ------------------------------------------------------------------------------

10.1.1. コマンドラインインターフェイスからのエンタイトルメント証明書の作成

手順

  1. 以下のコマンドを使用して、CLI からエンタイトルメント証明書を作成します。

    # rhui-manager client cert --repo_label rhel-sap-for-rhel-6-server-rhui-rpms --name rhuiclientexample --days 365 --dir /root/clientcert
    ..........................................................................................+++
    ..........+++
    Entitlement certificate created at /root/clientcert/rhuiclientexample.crt
    注記

    ID ではなく、Red Hat リポジトリーのラベルを使用します。すべてのラベルの一覧を表示するには、rhui-manager client labels コマンドを実行します。証明書に保護されているカスタムリポジトリーが含まれている場合は、リポジトリーの ID を使用してください。

パラメーターの完全リストは、付録B Red Hat Update Infrastructure コマンドラインインターフェイス を参照してください。

10.2. クライアント設定 RPM の作成

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面で e を押して、create entitlement certificates and client configuration RPMs を選択します。

                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
       r   manage repositories
       c   manage content delivery servers (CDS)
       l   manage HAProxy load-balancer instances
       s   synchronization status and scheduling
       e   create entitlement certificates and client configuration RPMs
       n   manage Red Hat entitlement certificates
       u   manage RHUI users
    
                                                       Connected: rhua.example.com
  2. c を押して create a client configuration RPM from an entitlement certificate を選択します。
  3. 設定ファイルを保存するローカルディレクトリーの完全パスを入力します。

    Full path to local directory in which the client configuration files generated by this tool
    should be stored (if this directory does not exist, it will be created):
    
    /tmp
  4. RPM の名前を入力します。

    clientrpmtest
  5. 設定 RPM のバージョンを入力します。デフォルトのバージョンは 2.0 です。
  6. 設定 RPM のリリースを入力します。デフォルトのバージョンは 1 です。
  7. 特定のチャネルにアクセスするためにクライアントを認証するエンタイトルメント証明書への完全パスを入力します。

    Full path to the entitlement certificate authorizing the client to access
    specific channels:
    /root/clientcert/rhuiclientexample.crt
  8. エンタイトルメント証明書の秘密鍵への完全パスを入力します。

    Full path to the private key for the above entitlement certificate:
    /root/clientcert/rhuiclientexample.key
  9. クライアント設定に含める保護されていないカスタムリポジトリーを選択します。

    - 1 : unprotected_repo1
  10. 選択を確認する場合は c を押すか、他のコマンドの場合は ? を押します。

    Successfully created client configuration RPM.
    Location: /tmp/clientrpmtest-2.0/build/RPMS/noarch/clientrpmtest-2.0-1.noarch.rpm

10.2.1. コマンドラインインターフェイスからクライアント設定 RPM を作成します

手順

  1. 以下のコマンドを使用して、rhui-manager CLI で RPM を作成します。

    # rhui-manager client rpm --entitlement_cert /root/clientcert/rhuiclientexample.crt --private_key /root/clientcert/rhuiclientexample.key --rpm_name clientrpmtest --dir /tmp --unprotected_repos unprotected_repo1
    Successfully created client configuration RPM.
    Location: /tmp/clientrpmtest-2.0/build/RPMS/noarch/clientrpmtest-2.0-1.noarch.rpm
    注記

    コマンドラインを使用して、RHUI リポジトリーで使用するプロキシーサーバーの URL を指定するか、_none_ (下線を含む) を使用して、クライアントマシンのグローバルな yum 設定を上書きすることもできます。プロキシーを指定するには、--proxy パラメーターを使用します。

パラメーターの完全リストは、付録B Red Hat Update Infrastructure コマンドラインインターフェイス を参照してください。

10.3. クライアント RPM のインストール

手順

  1. RPM をクライアントマシンにコピーし、インストールします。

    [client1 ~]# yum localinstall <rpm>
  2. RPM がインストールされていることを確認します。

    [client1 ~]# yum list <rpm>
    注記

    クライアント RPM のインストール後に、yum で rhn-plugin プラグインおよび subscription-manager プラグインが無効になります。

  3. yum リポジトリーを表示して、リポジトリーが追加され、インストールにパッケージが利用できることを確認します。

    [client1 ~]# yum repolist
    Loaded plugins: search-disabled-repos, security
    rhui-rhel-sap-for-rhel-6-server-rhui-rpms                | 2.0 kB     00:00
    rhui-rhel-sap-for-rhel-6-server-rhui-rpms/primary        |  26 kB     00:00
    rhui-rhel-sap-for-rhel-6-server-rhui-rpms                                 77/77
    repo id                                   repo name                       status
    rhui-rhel-sap-for-rhel-6-server-rhui-rpms Red Hat Enterprise Linux for SA 77
    repolist: 77
  4. そのリポジトリーからパッケージをインストールします。

    [client1 ~]# yum install compat-locales-sap

10.4. EUS チャネルの使用

デフォルトでは、クライアントはメインのリリースチャンネル (例: 7Server または 6Server) からコンテンツを取得するように設定されます。EUS チャンネルを同期した場合は、リリースの具体的なバージョンを設定する必要があります。クライアント RPM のインストール後に、クライアントマシンには rhui-set-release ツールが利用できます。

手順

  1. yum releasever 変数を version に設定して、/etc/yum/vars/releasever ファイルを作成します。これにより、yum はこの特定のバージョンで EUS リポジトリーを使用するようになります。次のコマンドを実行してください。

    rhui-set-release --set <version>
  2. releasever 変数の設定を解除するには (ファイルを削除するには)、次のコマンドを実行します。

    rhui-set-release --unset
  3. 現在設定されているバージョンを出力するには、次のコマンドを実行します。

    rhui-set-release
    注記

    出力がない場合は、特定のバージョンが設定されていないことを意味します。

バグの報告

第11章 Red Hat Update Infrastructure Server のクライアントプロファイルの作成

11.1. GPG キーの生成

手順

  1. Red Hat Update Infrastructure (RHUI) クライアントプロファイルのカスタムパッケージ (クライアント設定 RPM を含む) の署名に使用できる GPG キーを作成します。

    • このプロファイルは、Red Hat Enterprise Linux (RHEL) 6 または RHEL 7 で実行する RHUI サーバーに使用されるため、4,096 ビット RSA キーが使用されます。特に Red Hat Update Appliance (RHUA) が仮想マシンの場合は、4,096 ビットの鍵を生成するのに十分なランダムデータを収集するのに大量の時間がかかることがあります。リポジトリーまたはコンテンツ配信サーバー (CDS) の同期により作成されるディスクアクティビティーにより、プロセスが速くなる場合があります。
    • クライアントプロファイル RPM (この場合は rhui-client-rhui) の名前 (後述) が、ユーザー ID のコメント部分として使用されます。各クライアントプロファイルには異なる署名鍵を使用することが推奨されます。異なる鍵のユーザー ID を識別するには、クライアントプロファイル名を使用します。

      # gpg --gen-key
      
      gpg (GnuPG) 2.0.14; Copyright (C) 2009 Free Software Foundation, Inc.
      
      This is free software; you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.
      
      Please select what kind of key you want:
      
      1. RSA and RSA (default)
      2. DSA and Elgamal
      3. DSA (sign only)
      4. RSA (sign only)
      
      Your selection? 4
      
      RSA keys may be between 1024 and 4096 bits long.
      
      What keysize do you want? (2048) 4096
      Requested keysize is 4096 bits
      
      Please specify how long the key should be valid.
      
      0 = key does not expire
       = key expires in n days
      w = key expires in n weeks
      m = key expires in n months
      y = key expires in n years
      
      Key is valid for? (0) 0
      Key does not expire at all.
      
      Is this correct? y
      
      GnuPG needs to construct a user ID to identify your key.
      
      Real name: $YOURNAME
      
      Email address: $USER@$HOST.com
      
      Comment: rhui-client-rhui
      
      You selected this user ID:
      
      “$USERID (rhui-client-rhui) <$USER@$HOST.com>"
      
      Change (N)ame, (C)omment, (E)mail or (O)kay/(Q)uit? o
      
      You need a Passphrase to protect your secret key.
  2. 高品質のパスワードを入力し、安全な場所に記録します。

    gpg: key EDD092F4 marked as ultimately trusted
    
    public and secret key created and signed.
    
    gpg: checking the trustdb
    
    gpg: 3 marginal(s) needed, 1 complete(s) needed, PGP trust model
    
    gpg: depth: 0   valid:   1   signed:   0   trust:  0-, 0q, 0n, 0m, 0f, 1u
    
    pub    4096R/EDD092F4  2015-11-25
    
    Key fingerprint = 1139 932A 26E2 981A 1341 D636 0DDB B5F6 EDD0 925F4
    
    uid Red Hat $USERID (rhui-client-rhui) <user@redhat.com>
    
    Note that this key cannot be used for encryption. You may want to use the command “--edit-key” to generate a subkey for this purpose.
  3. 次のキーを作成します。この時間には、キータイプとしてオプション 3、DSA (署名のみ) を選択し、1024 ビットをキーサイズとして入力します。これらのオプションは、RHEL6 および RHEL7 の RPM に署名するために使用できるキーを作成します。rhui-client-all をユーザー ID のコメント部分として使用します。
  4. 2 つのキーをエクスポートします。

    # mkdir /root/rpm-gpg
    # gpg --export --armor rhui-client-rhui >> /root/rpm-gpg/rhui-client-rhui
    # gpg --export --armor rhui-client-all >> /root/rpm-gpg/rhui-client-all

    GPG では、鍵の検索時に、デフォルトで部分文字列マッチが使用されます。ユーザー ID の一意の部分 (この場合はクライアントプロファイルの RPM 名) のみを指定する必要があります。Red Hat Update Infrastructure Management Tool がクライアント設定パッケージを作成するときに、従来の RPM-GPG-KEY- 接頭辞が GPG 鍵ファイル名に追加されます。

11.2. カスタムリポジトリーの設定

更新されたクライアント設定パッケージまたは他の Red Hat 以外のソフトウェアを RHUI サーバーに配信するために使用できるカスタムリポジトリーを作成できます。64 ビット RHUI サーバー (例: client-rhui-x86_64) の保護されたリポジトリーは、RHUI サーバーに新しい Red Hat 以外のパッケージ (更新済みのクライアント設定パッケージなど) を配布するための優先手段になります。

Red Hat コンテンツリポジトリーと同様、保護されているすべてのカスタムリポジトリーが、プロセッサーアーキテクチャーでのみ異なる (i386 と AMD64) は、$basearch yum 変数を使用して、エンタイトルメント証明書内の単一のエンタイトルメントに統合されます。

証明書に問題がある場合には、RHUI サーバーの保護されていないリポジトリーを、更新された RPM を RHUI サーバーに配布するためのフォールバック方法として使用できます。

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
  2. Repository Management 画面で c を押して、create a new custom repository (RPM content only) を選択します。

    ------------------------------------------------------------------------------
                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Repository Management =-
    
       l   list repositories currently managed by the RHUI
       i   display detailed information on a repository
       a   add a new Red Hat content repository
       ad  add a new Red Hat docker container
       c   create a new custom repository (RPM content only)
       d   delete a repository from the RHUI
       u   upload content to a custom repository (RPM content only)
       ur  upload content from a remote web site (RPM content only)
       p   list packages in a repository (RPM content only)
    
    Connected: rhua.example.com
    ------------------------------------------------------------------------------
  3. リポジトリーの一意の ID を入力します。英数字、_(アンダースコア)、および-(ハイフン) のみが許可されます。一意の ID にスペースは使用できません。たとえば、repo1repo_1、および repo-1 はすべて有効なエントリーです。

    Unique ID for the custom repository (alphanumerics, _, and - only):
  4. リポジトリーの表示名を入力します。この名前は、Red Hat Update Infrastructure Management Tool 内でリポジトリーを識別するのに使用されます。
  5. リポジトリーをホストするパスを指定します。このパスは、RHUI がホストする全リポジトリーで一意でなければなりません。たとえば、このステップのパスを some/unique/name として指定すると、リポジトリーは //server/pulp/repos/some/unique/name に配置されます。
  6. リポジトリーのメタデータに使用するチェックサムタイプとして sha256 を選択します。

    注記

    RHEL 6 または RHEL 7 用のカスタムリポジトリーを作成する場合は sha256 を使用します。RHEL 5 クライアントのリポジトリーを作成する場合は sha1 を使用します。

  7. 新規リポジトリーを保護するかどうかを選択します。この質問に no と回答すると、すべてのクライアントがリポジトリーにアクセスできます。yes と回答すると、適切なエンタイトルメント証明書を持つクライアントのみがリポジトリーにアクセスできます。

    注記

    名前が示すように、保護されていないリポジトリーのコンテンツは、クライアントのエンタイトルメント証明書を必要とせずに要求するシステムで利用できます。保護されていないリポジトリーを使用してコンテンツを配信する場合は、更新されたクライアント設定 RPM などのコンテンツを配布する場合は注意してください。これにより、保護されたリポジトリーへのアクセスが提供されます。

    保護されていないリポジトリーの使用は、緊急時のガラス破りの行動です。

    新規リポジトリーの保護を選択した場合、Red Hat Update Infrastructure Management Tool はエンタイトルメントパスを要求します。また、リポジトリーの相対パスに基づいてエンタイトルメントパスを提案します。

    クライアントエンタイトルメント証明書には、アクセス可能なダウンロード URL が含まれます。RHUI は証明書のコンテンツを分析し、要求されたリポジトリーが許可された URL のいずれかと一致するかどうかを判断します。これにより、クライアントが認証を許可するかどうかが決まります。たとえば、エンタイトルメント証明書が /some/unique/name へのアクセスを許可し、リクエストが //server/pulp/repos/some/unique/name/os/repodata にあるリポジトリーに対して行われた場合、パスは権利を付与するダウンロード URL の 1 つで始まるため、RHUI はリクエストを承認し、認証を付与します。URL は正しい情報でのみ開始する必要があります。完全一致する必要はありません。

    注記

    pulp-admin で作成した /some/unique/name リポジトリーがカスタムグループに追加されていない場合は、Red Hat 更新インフラストラクチャー管理ツールに /some/unique/name が表示されません。Red Hat Update InfrastructureManagementTool で同じ ID /some/unique/name のリポジトリーを作成しようとして、/some/unique/name リポジトリーが pulp-admin で作成されたことに気付かない場合は、次のメッセージが表示されます。ID /some/unique/name のリポジトリーはすでに存在します。

    yum が変数の値を認識している限り、エンタイトルメントには変数を含めることもできます。使用する最も一般的な変数は $basearch$releasever で、要求を行うクライアントの詳細が入力されます。たとえば、資格証明書が /unique-name/$ basearch/bar へのアクセスを許可し、リクエストが //server/pulp/repos/unique-name/x86_64/bar にあるリポジトリーに対して行われた場合、RHUI は変数が入力されたときにパスが一致するため、認証を要求して許可します。

    Red Hat Update Infrastructure Management Tool は、リポジトリーのパスを提供したときに使用した変数に基づいて使用するパスを提案します。フィールドが空白のままにして、推奨されるパスを受け入れます。

    Red Hat Update Infrastructure Management Tool は、GNU Privacy Guard(GPG) 署名が、そのリポジトリーにあるコンテンツに対して有効になっているかどうかを尋ねます。y を押すと、コンテンツが Red Hat によって署名されるかどうかを尋ねます。yes と回答すると、リポジトリー設定に Red Hat GPG キーが含まれます。その内容がカスタムの GPG キーで署名されるかどうかを尋ねます。yes と回答すると、リポジトリー設定に含める公開 GPG キーへのパスの入力が求められます。パブリック GPG キーへの複数のパスの入力を継続できます。

    Should the repository require clients to perform a GPG check and verify packages are signed by a GPG key? (y/n) y
    
    Will the repository be used to host any Red&nbsp;Hat GPG signed content? (y/n) y
    
    Will the repository be used to host any custom GPG signed content? (y/n) y
    
    Enter the absolute path to the public key of the GPG key pair:
    /root/rpm-gpg/rhui-client-rhui.gpg
    
    Would you like to enter another public key? (y/n) y
    
    Enter the absolute path to the public key of the GPG key pair:
    /root/rpm-gpg/rhui-client-all.gpg
    
    Would you like to enter another public key? (y/n) n
  8. 新しいリポジトリーの詳細が表示されます。プロンプトで y を押して情報を確認し、リポジトリーを作成します。

11.3. クライアントノードへのクライアント設定 RPM のインストール

手順

  1. 更新が必要な各クライアントノードに、クライアント設定 RPM をインストールします。

    # yum install /path/to/client_custom.rpm
  2. クライアント設定の RPM は、rhui-$ORIGINALNAME と呼ばれる yum リポジトリーを設定します。yum update コマンドを使用して、各ノードを更新します。

    # yum update
    注記

    yum update コマンドを実行すると、有効になっているすべての yum リポジトリーから更新がプルされます。rhui-rhui-3 yum リポジトリーからのみ更新をプルするには、以下のコマンドを使用します。

    # yum --disablerepo=* --enablerepo=rhui-rhui-3 update

バグの報告

第12章 クライアントイメージおよびテンプレートの作成

作成される Red Hat Enterprise Linux (RHEL) イメージの正確な性質は、環境内のテクノロジースタックにより異なります。いずれの場合も、インスタンス化時に特定の基準を満たすアーティファクト (イメージ、テンプレートなど) を作成することが目的です。

12.1. イメージの要件

認定クラウドイメージには以下の要件が適用されます。そのほとんどはデフォルトの挙動または設定です。

  • Red Hat パッケージは変更、再構築、または交換しないでください。
  • SELinux を有効にし、Enforcing モードにしてください。
  • これを使用すると、iptables は SSH 以外のすべてのポート (およびクラウドインフラストラクチャーを適切に運用するために必要なその他のポート) へのアクセスをブロックする必要があります。
  • ローカルパスワードには、その RHEL バージョンのデフォルト (Red Hat Enterprise Linux 7 の場合は SHA-512) と同じ強力なハッシュアルゴリズムを使用する必要があります。
  • ディスクサイズは最低 6GB である必要があります。
  • ファイルシステムの種類は xfs (Red Hat Enterprise Linux 7) にする必要があります。
  • リモートアクセスには sshd を有効にする必要があります。
  • Syslog 設定は、オペレーティングシステムのデフォルトから変更しないでください。

詳細は、Cloud Image Certification Policy Guide を参照してください。

12.2. Red Hat Update Infrastructure の統合

手順

  1. RHUI エンタイトルメント RPM および GPG キーを対象の RHEL クライアントシステムに転送して、イメージを Red Hat Update Infrastructure (RHUI) と統合します。
  2. 適切なクライアント設定 RPM をインストールします。

    # yum install <rhui-client-rhel7>
  3. Red Hat リリース GPG キー (/etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release) をカスタムリポジトリーキーと共にエンタイトルメント RPM にインポートします。
  4. エンタイトルメント RPM GPG キーをインポートします。

    #rpm --import <rhui-client-rhui>
  5. 更新は、Red Hat サブスクリプションマネージャー (rhm) ではなく RHUI から行われます。enabled=0を反映するために ./rhsm.conf を編集して rhsm を無効にします。
  6. 必要に応じて (ただし強く推奨されます)、yum update を実行して、利用可能な更新をすべて適用します。

12.3. テンプレートの準備

イメージをテンプレートとして使用できるように、イメージをサニタイズする必要があります。このスクリプトを使用すると、仮想マシンイメージをサニタイズして、テンプレートとして使用できるようにします。Red Hat Enterprise Linux 6 イメージおよび Red Hat Enterprise Linux 7 イメージと互換性があります。

注記

一部の環境では、スクリプトを変更する必要がある場合があります。使用前にこのスクリプトを慎重に確認し、イメージに加える変更が、使用環境と互換性があることを確認してください。

手順

  1. 次のスクリプトを実行します。

    #!/bin/bash
    
    # RHEL 7
    if ! [[ `runlevel | cut -d " " -f 2` =~ ^[1S]$ ]]; then
    echo "Please *boot* to runlevel 1"
    exit 3
    fi
    
    # Kill udev
    killall -9 udevd
    
    # Clean out /root
    rm -rf /root/*
    rm -f /root/.bash_history
    rm -rf /root/.ssh
    
    # SSH host keys
    rm -f /etc/ssh/ssh_host_*
    # Remove all files in /var that are not owned by an RPM
    
    for FILE in `find /var -type f`; do
    rpm -qf --quiet "$FILE" || rm -f "$FILE"
    
    done
    
    # Remove empty directories in /var that are not owned by an RPM
    
    until [ "$REMOVED_DIR" = false ]; do
         REMOVED_DIR=false
         for DIR in `find /var -type d -empty`; do
        if ! rpm -qf --quiet "$DIR"; then
             REMOVED_DIR=true
             rmdir "$DIR"
        fi
     done
    
    done
    
    # Truncate any remaining files in /var/log
    for FILE in `find /var/log -type f`; do
       echo -n > "$FILE"
    
    done
    
    # Make sure the RPM GPG key has been imported
    rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release 2> /dev/null
    
    # Remove MAC addresses from /etc/sysconfig/network-scripts/ifcfg-*
    for FILE in /etc/sysconfig/network-scripts/ifcfg-*; do
    
       sed -i /^HWADDR/d "$FILE"
    
    done
    
    # Remove auto-generated udev rules for CD-ROM and network devices
    rm -f /etc/udev/rules.d/70-persistent-{cd,net}.rules
    
    # Clean out /tmp
    find /tmp -mindepth 1 -delete
  2. スクリプトをコピーして、システムを /mktemplate.sh し、再起動して、runlevel 1 に移動します。

    注記

    (たとえば、init 1 で) 再起動する代わりに runlevel 1 に変更しないでください。runlevel 1 に変更すると、システムの起動時に実行していないデーモンがシングルユーザーモード (特に rsyslog) で実行していたままになります。

  3. システムがシングルユーザーモードで再起動したら、次のコマンドを実行します。

    # unset HISTFILE
    # chmod 0755  /mktemplate.sh
    # /mktemplate.sh
    # rm -f /mktemplate.sh
    # poweroff

バグの報告

第13章 認定済みのクラウドおよびサービスプロバイダー認定ワークフロー

認定クラウドプロバイダー契約では、作成したテナントインスタンスのイメージ (テンプレート) を Red Hat が認定し、エンドカスタマーが完全にサポートされる設定を維持する必要があります。Red Hat Enterprise Linux および Red Hat Enterprise Linux 7 のイメージを認定する方法は 2 つあります。推奨される方法は、Certified Cloud and Service Provider (CCSP) イメージ認定ワークフローを使用することです。

詳細は、RedHat 認定クラウドおよびサービスプロバイダー認定ワークフローガイド を参照してください。

Red Hat が認証を確認した後、合格したかどうかが判断され、Red Hat 認定の Web サイト Certified Service and Product Catalogs に認定が送信されます。

バグの報告

第14章 コンテンツの管理

Red Hat Update Infrastructure (RHUI) は、RHUI インストールを更新するリポジトリーを作成し、使用するように設定できます。Red Hat Update Infrastructure Management Tool はリポジトリーを作成し、エンタイトルメント証明書およびクライアント設定 RPM を生成することができます。RPM は、Red Hat UpdateRow (RHUA) ノードおよび各コンテンツ配信サーバー (CDS) ノードにインストールされます。将来の更新は、yumupdate コマンドを使用してダウンロードおよびインストールできます。

14.1. 利用可能なチャンネル

CCSP (Certified Cloud and Service Provider) パートナーは、サービス経由で配信されるチャンネルとパッケージを制御します。利用可能なチャネルに関する最新情報については、RHUI を介して RedHat の CertifiedCloud and Service Provider (CCSP) パートナーを通じて配信できる Red Hat Enterprise Linux リポジトリー を参照してください。リポジトリーは、以下で使用できます。

  • Red Hat Enterprise Linux 7
  • Red Hat Enterprise Linux 7 for SAP Applications
  • Red Hat Enterprise Linux for SAP HANA
  • Red Hat Enterprise Linux 6
  • Red Hat Enterprise Linux 6 for SAP Applications
  • Red Hat Enterprise Linux 6 for SAP HANA
  • Red Hat Enterprise Linux 5
  • Red Hat Enterprise Linux 5 延長ライフサイクルサポート

必要なチャンネルがない場合は、CCSP にお問い合わせください。利用可能な内容は、Certification Catalog を参照してください。

重要

RHUI 3.1 は、RHEL 9 コンテンツの配信をサポートしていません。RHEL 9 コンテンツを配信するには、RHUI 4 以降を使用する必要があります。

14.2. Linux ソフトウェアリポジトリーの管理

リポジトリーは、Linux ディストリビューションのダウンロード可能なソフトウェアが含まれるサーバーノードです。yum を使用して、リポジトリーから RHUA ノードおよび CDS ノードへの RPM の検索、インストール、制御を行います。

14.2.1. 利用可能なリポジトリーの一覧表示

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
  2. r を押して、リポジトリーの管理 を選択します。
  3. l を押して、list repositories currently managed by the RHUI を選択します。

                                                  	Connected: rhua.example.com
    
    ------------------------------------------------------------------------------
    rhui (repo) => l

14.2.2. リポジトリー情報の表示

Repository Management 画面では、特定のリポジトリーに関する情報を表示できます。

手順

  1. Repository Management 画面で、i を押します。この出力には、Red Hat Update Infrastructure が管理するすべてのリポジトリーが含まれます。
  2. プロンプトでリポジトリーの番号を入力して、表示するリポジトリーを選択します。リポジトリーの数を入力すると、そのリポジトリー名の横にチェックマークが付けられます。また、リポジトリーの範囲を選択することもできます (例: 1 ~ 5)。
  3. 表示するリポジトリーがすべて確認されるされるまで続行します。
  4. プロンプトで c を押して確認します。

    Name:            		RHEL RHUI Server 7 Containers (7Server-x86_64)
    Type:	            	Red Hat
    Relative Path:   	content/dist/rhel/rhui/server/7/7Server/x86_64/containers/
    GPG Check:       	Yes
    Custom GPG Keys: 	(None)
    Red Hat GPG Key: 	Yes
    Package Count:   	0
    Last Sync:       		Never
    Next Sync:       	11-30-2015 19:38

14.2.3. Red Hat リポジトリーの追加

手順

  1. 新しい Red Hat リポジトリーを追加する前に、エンタイトルメントが適用された製品用に特定のリポジトリーを読み込みます。

詳しくは、「リポジトリーの作成」 を参照してください。

14.2.4. Red Hat リポジトリーの削除

Red Hat Update Infrastructure Management Tool が Red Hat リポジトリーを削除すると、RHUA および適用可能なすべての CDS ノードからリポジトリーが削除されます。

注記

リポジトリーのコンテンツはディスク上に残り、ディスク領域を消費します。このコンテンツは、孤立したコンテンツユニットまたは略して孤立 (orphan) と呼ばれています。詳細は、「孤立したコンテンツユニット」 を参照してください。

手順

  1. Repository Management 画面で d を押して、Red Hat リポジトリーを削除します。RHUI が現在管理しているリポジトリーの一覧が表示されます。
  2. プロンプトでリポジトリーの数を入力して、削除するリポジトリーを選択します。リポジトリーの数を入力すると、そのリポジトリー名の横にチェックマークが付けられます。また、リポジトリーの範囲を選択することもできます (例: 1 ~ 5)。
  3. 削除するリポジトリーがすべて確認されるまで続行します。
  4. プロンプトで c を押して確定します。

    注記

    リポジトリーの削除後、削除されたリポジトリーを参照するクライアント設定 RPM は yum では使用できません。

14.2.5. リポジトリーの RPM パッケージの一覧表示

Red Hat Update Infrastructure Management Tool 内のリポジトリーの一覧を表示する際に、パッケージ数が 100 未満のリポジトリーのみがそのコンテンツを表示します。100 を超えるパッケージでは、パッケージ数のみが表示されます。

手順

  1. リポジトリーに含まれるパッケージの数にかかわらず、完全なリストを表示するには、Home 画面で r を押して Repository Management 画面にアクセスします。
  2. p を押して、list packages in a repository (RPM content only) を選択します。
  3. 表示するリポジトリーの数を選択します。Red Hat Update Infrastructure Management Tool により、結果をフィルターリングするかどうかを尋ねられます。行を空白のままにして、フィルターなしで結果を確認します。
  4. または、結果をフィルターリングする RPM 名の最初の数文字を入力します。

14.2.6. カスタムリポジトリーを作成します。

Red Hat 以外の新しいパッケージを RHUI サーバーに配布する場合は、保護済みのリポジトリーまたは 64 ビットの RHUI サーバーを使用します。たとえば、更新されたクライアント設定パッケージを配布する場合は、client-rhui-x86_64 を使用します。

Red Hat コンテンツリポジトリーと同様、保護されているすべてのカスタムリポジトリーが、プロセッサーアーキテクチャーでのみ異なる (i386 と AMD64) は、$basearch yum 変数を使用して、エンタイトルメント証明書内の単一のエンタイトルメントに統合されます。

証明書の検証によりアクセスできない場合は、保護されていないサーバーリポジトリーを使用して RPM を RHUI サーバーに配信できます。

手順

  1. Repository Management 画面で c を押して、create a new custom repository (RPM content only) 画面にアクセスします。
  2. リポジトリーの一意の ID を入力します。英数字、_(アンダースコア)、および-(ハイフン) のみが許可されます。一意の ID にスペースは使用できません。たとえば、repo1repo_1、および repo-1 はすべて有効なエントリーです。
  3. リポジトリーの表示名を入力します。この名前は、Red Hat Update Infrastructure Management Tool 内でリポジトリーを識別するのに使用されます。
  4. リポジトリーをホストするパスを指定します。パスは、Red Hat Update Infrastructure がホストする全リポジトリーで一意である必要があります。たとえば、このステップのパスを some/unique/name として指定すると、リポジトリーは //<server>/pulp/repos/some/unique/name に配置されます。
  5. リポジトリーのメタデータに使用するチェックサムタイプとして sha256 を選択します。
  6. 新しいリポジトリーを保護するかどうかを選択します。この質問に no と回答すると、すべてのクライアントがリポジトリーにアクセスできます。yes と回答すると、適切なエンタイトルメント証明書を持つクライアントのみがリポジトリーにアクセスできます。

    注記

    名前が示すように、保護されていないリポジトリーのコンテンツは、クライアントのエンタイトルメント証明書を必要とせずに要求するシステムで利用できます。保護されていないリポジトリーを使用してコンテンツを配信する場合は、更新されたクライアント設定 RPM などのコンテンツを配布する場合は注意してください。これにより、保護されたリポジトリーへのアクセスが提供されます。

    保護されていないリポジトリーの使用は、緊急時のガラス破りの行動です。

  7. 新規リポジトリーの保護を選択した場合、Red Hat Update Infrastructure Management Tool はエンタイトルメントパスを要求します。また、リポジトリーの相対パスに基づいてエンタイトルメントパスを提案します。

    クライアントエンタイトルメント証明書には、アクセス可能なダウンロード URL が含まれます。RHUI は証明書のコンテンツを分析し、要求されたリポジトリーが許可された URL のいずれかと一致するかどうかを判断します。これにより、クライアントが認証を許可するかどうかが決まります。たとえば、エンタイトルメント証明書が /some/unique/name へのアクセスを付与し、//server/pulp/repos/some/unique/name/os/repodata にあるリポジトリーに対して要求が行われる場合、RHUI は要求を承認し、そのパスはエンタイトルメントのあるダウンロード URL のいずれかで始まるため認証を付与します。URL は正しい情報でのみ開始する必要があります。完全一致する必要はありません。

    yum が変数の値を認識している限り、エンタイトルメントには変数を含めることもできます。使用する最も一般的な変数は $basearch$releasever で、要求を行うクライアントの詳細が入力されます。たとえば、エンタイトルメント証明書が /unique-name/$basearch/bar へのアクセスを付与し、要求が //server/pulp/repos/unique-name/x86_64/bar にあるリポジトリーに行われる場合、RHUI はその要求を承認し、変数が入力されたときにそのパスが一致するため、認証を付与します。

    Red Hat Update Infrastructure Management Tool は、リポジトリーのパスを提供したときに使用した変数に基づいて使用するパスを提案します。フィールドが空白のままにして、推奨されるパスを受け入れます。

    Red Hat Update Infrastructure Management Tool は、GNU Privacy Guard(GPG) 署名が、そのリポジトリーにあるコンテンツに対して有効になっているかどうかを尋ねます。y を押すと、コンテンツが Red Hat によって署名されるかどうかを尋ねます。yes と回答すると、リポジトリー設定に Red Hat GPG キーが含まれます。その内容がカスタムの GPG キーで署名されるかどうかを尋ねます。yes と回答すると、リポジトリー設定に含める公開 GPG キーへのパスの入力が求められます。パブリック GPG キーへの複数のパスの入力を継続できます。

    Should the repository require clients to perform a GPG check and verify packages are signed by a GPG key? (y/n) y
    
    Will the repository be used to host any Red Hat GPG signed content? (y/n) y
    
    Will the repository be used to host any custom GPG signed content? (y/n) y
    
    Enter the absolute path to the public key of the GPG key pair:
    
    /tmp/rhuitest1.gpg
    
    Would you like to enter another public key? (y/n) y
    
    Enter the absolute path to the public key of the GPG key pair:
    /root/rpm-gpg/rhui-client-rhui.gpg
    
    Would you like to enter another public key? (y/n) n
  8. 新しいリポジトリー表示の詳細。プロンプトで y を押して情報を確認し、リポジトリーを作成します。

14.2.7. ローカルパッケージをカスタムリポジトリーにアップロードする

複数のパッケージを同時にアップロードし、一度に複数のリポジトリーにアップロードできます。パッケージは RHUA に即時にアップロードされますが、CDS ノードが次回同期するまで CDS ノードでは使用できません。

手順

  1. Repository Management 画面で u を押して、特定のリポジトリーに新しいパッケージをアップロードします。使用可能なすべてのカスタムリポジトリーのリストが表示されます。

    注記

    Red Hat リポジトリーにパッケージをアップロードすることはできません。

  2. プロンプトでリポジトリーの番号を入力して、パッケージを追加するカスタムリポジトリーを選択します。これにより、そのリポジトリーの名前の横にチェックマークが付けられます。パッケージを追加するすべてのリポジトリーがチェックされるまで続けます。
  3. プロンプトで c を押して確定します。
  4. アップロードする RPM の場所を指定します。これは、単一の .rpm ファイルか、複数の .rpm ファイルを含むディレクトリーになります。ディレクトリーを指定すると、そのディレクトリー内の .rpm ファイルがすべてアップロードされます。アップロードする新しいパッケージの詳細が表示されます。
  5. プロンプトで y を押して、情報を確認し、パッケージをアップロードします。

    The following RPMs will be uploaded:
    
    origin-1.0-1.noarch.rpm
    parent-1.0-1.noarch.rpm
    patb-0.1-2.x86_64.rpm
    rh-amazon-rhui-client-rhs30-2.2.124-1.el7.noarch.rpm
    
    Proceed? (y/n) y

14.2.8. リモートパッケージをカスタムリポジトリーにアップロードする

リモートサーバーに保存されているパッケージを、手動でダウンロードせずにアップロードすることができます。パッケージは、HTTP、HTTPS、または FTP でアクセスできる必要があります。

手順

  1. リポジトリー管理 画面のプロンプトで u を押します。使用可能なすべてのカスタムリポジトリーのリストが表示されます。

    注記

    Red Hat リポジトリーにパッケージをアップロードすることはできません。

  2. プロンプトで、パッケージをアップロードするカスタムリポジトリーの番号を入力します。これにより、そのリポジトリーの名前の横にチェックマークが付けられます。パッケージをアップロードするすべてのリポジトリーにチェックマークが付くまで続けます。
  3. プロンプトで c を押して確定します。
  4. URL を入力します。これは、Web サーバーまたは FTP サーバー上の単一のパッケージの場所、または Web サーバー上の HTML ページの場所にすることができます。後者は、URL がインデックスページのないディレクトリーである場合、Web サーバーによって生成されたディレクトリーリストにすることもできます。HTML コンテンツが検出されると、そこからリンクされているすべてのパッケージが取得され、ローカルキャッシュに保存されます。それ以外の場合は、指定された単一のパッケージが取得されてキャッシュされます。
  5. 取得が完了するのを待ってから、プロンプトで y を押して情報を確認し、パッケージをアップロードします。

    Retrieving http://mt-02.local/aGVsbG8K/
    Found 2 RPMs to download
    
    Retrieving
    http://mt-02.local/aGVsbG8K/origin-0.1-1.noarch.rpm [1/2]
    
    Retrieving
    http://mt-02.local/aGVsbG8K/parent-1.0-1.noarch.rpm [2/2]
    
    The following RPMs will be uploaded:
    
    origin-0.1-1.noarch.rpm
    parent-1.0-1.noarch.rpm
    
    Proceed? (y/n) yes

14.2.9. カスタムリポジトリーからパッケージを削除

手順

  1. Repository Management 画面で p を押して、リポジトリーのパッケージを一覧表示します (RPM コンテンツのみ)。パッケージを削除するカスタムリポジトリーの数を入力し、Enter を押します。

    rhui (repo) => p
    
    Choose a repository:
      1  - HP Packages for Testing
    Enter value (1-1) or 'b' to abort: 1
    
    Enter the first few characters (case insensitive) of an RPM to filter the results
    (blank line for no filter):
    
    
    Only filtered results that contain less than 100 packages will have their
    contents displayed. Results with more than 100 packages will display
    a package count only.
    
    Packages:
      hprest-1.5-79.x86_64.rpm
      hpsum-7.6.0-86.rhel7.x86_64.rpm
      ilorest-2.2.2-6.x86_64.rpm         <========== Goal, delete this package
      sum-8.2.0-53.rhel7.x86_64.rpm
  2. pulp-admin コマンドを使用して、repo_id を含むリポジトリー情報を一覧表示します。

    # pulp-admin --username admin --password "redhat" repo list --snip--
    Id:                              custom_repo1
    Display Name:           HP Packages for Testing
    Description:               HP Packages for Testing
    Content Unit Counts:
      Rpm: 4
  3. パッケージ情報を一覧表示します。

    # pulp-admin --username admin --password "redhat" rpm repo content rpm --repo-id "custom_repo1" --str-eq="filename=ilorest-2.2.2-6.x86_64.rpm"
    
    Arch:         x86_64
    Buildhost:    bls11u3x64001.sde.rdlabs.hpecorp.net
    Checksum:     570b98fff1943819e554ff5d643f674a1aa00fc1b362900badfdc4bd0943ce06
    Checksumtype: sha256
    Description:  Command line interface for managing HPE ProLiant Servers  Authors:
                  --------     Hewlett Packard Enterprise
    Epoch:        0
    Filename:     ilorest-2.2.2-6.x86_64.rpm
    License:      Copyright 2016 Hewlett Packard Enterprise Development LP
    Name:         ilorest
    Provides:     config(ilorest) = 2.2.2-6-0, ilorest = 2.2.2-6-0, ilorest(x86-64)
                  = 2.2.2-6-0, ilorest_chif.so()(64bit)
    Release:      6
    Requires:     /bin/sh, /bin/sh, libc.so.6()(64bit),
                  libc.so.6(GLIBC_2.2.5)(64bit), libc.so.6(GLIBC_2.3)(64bit),
                  libdl.so.2()(64bit), libdl.so.2(GLIBC_2.2.5)(64bit),
                  libz.so.1()(64bit), rtld(GNU_HASH)
    Vendor:       Hewlett Packard Enterprise Company
    Version:      2.2.2
  4. カスタムリポジトリーからパッケージを削除します。

    # pulp-admin --username admin --password "redhat" rpm repo remove rpm --repo-id "custom_repo1" --str-eq="filename=ilorest-2.2.2-6.x86_64.rpm"
    This command may be exited via ctrl+c without affecting the request.
    
    [\]
    Running...
    
    Units Removed:
      ilorest-2.2.2-6-x86_64
  5. メタデータを更新し、リポジトリーを公開します。

    # pulp-admin  --username admin --password "redhat" rpm repo update --repo-id "custom_repo1"
    # pulp-admin --username admin --password "redhat"  rpm repo publish run --repo-id "custom_repo1"
  6. 「孤立したコンテンツユニット」 の説明に従って、リポジトリーから関連付けられていない孤立した RPM を削除して、ディスク領域を確保します。

14.2.10. エラータメタデータのカスタムリポジトリーへのインポート

カスタムリポジトリーのパッケージのエラータメタデータが含まれる updateinfo.xml ファイルまたは updateinfo.xml.gz ファイルがある場合は、メタデータをインポートして、リポジトリーを使用するクライアントシステムが個々の更新の詳細情報を受け取ることができます。この情報には、エラータ ID、バグ番号、バグまたセキュリティーの修正の説明、および参照が含まれます。クライアントはこのデータを使用して更新を選択的に適用できます。コマンドラインインターフェイスからメタデータのみをインポートできます。

手順

  1. 次のコマンドを実行して、指定した updateinfo ファイルから指定したカスタムリポジトリーにデータをインポートします。

    # rhui-manager repo add_errata --repo_id my_repo --updateinfo ~/Downloads/ac4c9d01646b2100cf292a6b67672ad5
    -updateinfo.xml.gz
    注記

    このコマンドは、特に updateinfo ファイルに多数の更新が含まれる場合に、完了するまでに時間がかかる場合があります。/root/.rhui/rhui.log ファイルに進捗が記録されます。

    警告

    updateinfo ファイルからエラータをインポートしたら、再度インポートすることはできません。これは、データベースキーとしてのエラータ ID の一意性に違反します。追加のエラータエントリーで updateinfo ファイルを再インポートすると、古いエントリーは変更されず、追加エントリーが追加されます。以前に追加したエラータを置き換える必要がある場合は、updateinfo ファイルをインポートする前に MongoDB で直接削除してください。

14.2.11. パッケージグループのメタデータをカスタムリポジトリーにインポートする

カスタムリポジトリーの comps.xml ファイルまたは comps.xml.gz ファイルがある場合は、これをリポジトリーにインポートして、クライアントがパッケージグループまたは言語パックを表示し、インストールできるようにします。インポートはコマンドラインインターフェイスでのみ実行されます。

手順

  1. 次のコマンドを実行して、指定した comps ファイルから指定のカスタムリポジトリーにデータをインポートします。

    # rhui-manager repo add_comps --repo_id my_repo --comps ~/Downloads/a27718cc28ec6d71432e0ef3e6da544b7f9d93f6bb7d0a55aacd592d03144b70-comps.xml

14.2.12. 代替コンテンツソース設定 RPM の作成

RHUI を、Red Hat Satellite や別の RHUI インストールなどの別のシステム管理製品の代替コンテンツソースとして使用する場合は、RHUI に代替のコンテンツソース設定 RPM を作成することができます。RPM は、Red Hat コンテンツ配信ネットワークの代わりに RHUI からパッケージを取得するように Pulp を設定する他のシステム管理製品にインストールすることが意図されています。

この RPM は、コマンドラインインターフェイスからのみ作成できます。これを作成するには、リポジトリーが少なくとも 1 つ必要です。また、「エンタイトルメント証明書の作成」 の説明どおりに、リポジトリーのエンタイトルメント証明書とキーが必要です。または、追加するリポジトリーのラベルが分かっている必要があります。

手順

  1. 以前生成されたエンタイトルメント証明書を使用して別のコンテンツソース設定 RPM を作成するには、以下のようなコマンドを実行します。

    # rhui-manager client content_source --entitlement_cert /tmp/mycrt.crt --private_key /tmp/mycrt.key --rpm_name altcs --dir /tmp
  2. 1 つ以上のラベルを使用して代替コンテンツソース設定 RPM を作成し、適切な証明書がその場で作成されるようにするには、次のようなコマンドを実行します。

    # rhui-manager client content_source --cert --repo_label rhel-7-server-rhui-rpms,rhel-7-server-rhui-optional-rpms --rpm_name altcs --dir /tmp
  3. アクセス可能な全リポジトリーのラベル一覧を取得するには、次のコマンドを実行します。

    # rhui-manager client labels

14.3. 孤立したコンテンツユニット

RHUI は、Red Hat Update Infrastructure Management Tool がリポジトリーを削除する際に、孤立したコンテンツユニット (孤立 (orphan) とも呼ばれる) を削除しません。詳細は、「Red Hat リポジトリーの削除」 を参照してください。

孤立したファイルは、リポジトリーで参照されなくなりましたが、ファイルシステム上に留まり、ディスク領域を消費します。設定設定またはリポジトリーの削除により、パッケージファイルが孤立する可能性があります。これらのコンテンツユニットの削除が分からない場合は、孤立した場所を削除するのではなく、ディスク容量を増やすことを検討してください。

RHUA および CDS で孤立を削除して、ディスク領域を再利用できます。以下の手順では、RHUI からの orphans を削除します。以下の手順を使用する前に、完全バックアップを実行します。

手順

  1. RHUA から次のコマンドを実行し、孤立したパッケージを表示します。

    [root@rhua ~]# pulp-admin -u admin -p admin orphan list
  2. 次のコマンドを実行して利用可能な引数を表示します。

    [root@rhua ~]# pulp-admin -u admin -p admin orphan list --help
    Command: list
    Description: display a list of orphaned units
    
    Available Arguments:
    
      --type    - restrict to one content type such as "rpm", "errata",
                  "puppet_module", etc.
      --details - include a detailed list of the individual orphaned units, ignored
                  when content type is not specified
  3. 孤立したオブジェクトを削除するために 3 つのフラグがあります。

            --type=<type> to remove all the orphaned content units of a particular type
            --id=<id> to remove a particular orphaned content unit
            --all to remove all the orphaned content units on the server

    孤立を削除する方法の一例を次に示します。

    [root@rhua ~]# pulp-admin orphan remove --all
  4. 次のコマンドを実行して、引数の一覧を表示します。

    [root@rhua ~]# pulp-admin -u admin -p admin orphan remove --help
    Command: remove
    Description: remove one or more orphaned units
    
    Available Arguments:
    
      --bg      - if specified, the client process will end immediately (the task
                  will continue to run on the server)
      --type    - restrict to one content type such as "rpm", "errata",
                  "puppet_module", etc.
      --unit-id - ID of a content unit; if specified, you must also specify a type
      --all     - remove all orphaned units, ignoring other options

14.4. コンテンツ配信サーバーノードの管理

CD ノードは、コンテンツ配信ネットワーク (CDN) の主なコンポーネントで、クライアントに高可用性を提供します。地理的に分散した方法でサーバーを実行すると、応答時間も改善します。

Content Delivery Server (CDS) Management 画面は、CDS ノードの一覧表示、追加、再インストール、および削除に使用されます。

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面で c を押して、Content Delivery Server (CDS) Management 画面にアクセスします。

                 -= Red Hat Update Infrastructure Management Tool =-
    
    -= Home =-
    
       r   manage repositories
       c   manage content delivery servers (CDS)
       l   manage HAProxy load-balancer instances
       s   synchronization status and scheduling
       e   create entitlement certificates and client configuration RPMs
       n   manage Red Hat entitlement certificates
       u   manage RHUI users
    
                                                       Connected: rhua.example.com
  2. Content Delivery Server (CDS) Management 画面で l を押して、RHUI が管理する CDS ノードを一覧表示します。

    ------------------------------------------------------------------------------
           	-= Red Hat Update Infrastructure Management Tool =-
    
    -= Content Delivery Server (CDS) Management =-
    
    l   list all known CDS instances managed by the RHUI
    a   register (add) a new CDS instance
    r   reinstall and reapply configuration to an existing CDS instance
    d   unregister (delete) a CDS instance from the RHUI
    
                                    	Connected: ip-10-99-206-124.ec2.internal
    ------------------------------------------------------------------------------
    rhui (cds) =>l
    
    -= RHUI Content Delivery Servers =-
    
    Hostname:         	cds1.example.com
    SSH Username:     	root
    SSH Private Key:  	/root/.ssh/cds.rsa
    
    Hostname:         	cds2.example.com
    SSH Username:     	root
    SSH Private Key:  	/root/.ssh/cds.rsa
    
    Hostname:         	cds3.example.com
    SSH Username:     	root
    SSH Private Key:  	/root/.ssh/cds.rsa
    ------------------------------------------------------------------------------

14.5. コンテナーの使用

Red Hat Enterprise Linux 7 システムまたは Red Hat Atomic Host システムの Red Hat Update Infrastructure 3.1.9 は、Docker を使用して Linux コンテナー内のアプリケーションのデプロイメントを自動化します。Docker の使用には、以下の利点があります。

  • 必要なストレージとメモリー内の領域は仮想マシンに比べて少なくて済みます。コンテナーはアプリケーションの実行に必要なものだけを保持するため、Docker コンテナーを使用すると、オペレーティングシステム全体を含む仮想マシンよりも保存と共有が効率的になります。
  • パフォーマンスの向上: 完全に独立したオペレーティングシステムを実行していないため、コンテナーは通常、新しい VM のオーバーヘッドを運ぶアプリケーションよりも高速に実行されます。
  • セキュア - 通常、Docker コンテナーには独自のネットワークインターフェイス、ファイルシステム、およびメモリーがあるため、そのコンテナーで実行されているアプリケーションは、ホストコンピューター上の他のアクティビティーから分離して保護できます。
  • 柔軟: コンテナーのアプリケーションに含まれるアプリケーションのランタイム要件により、Docker コンテナーは複数の環境で実行できます。

docker 形式の Linux コンテナーは、SELinux が有効になっているホストでの実行に対応しています。/var/lib/docker ディレクトリーが、B-tree ファイルシステム (Btrfs) を使用するボリュームにあると、SELinux はサポートされません。

注記

docker API は httpd インスタンス上のルートフォルダー (/) を引き継ぎ、別のポートで実行される必要があります。ポート 5000 は現在使用されていますが、これは今後ユーザーが設定できます。RHUA は、docker コンテンツに使用する認証局を見つける際に、docker クライアントがホスト名およびポートを使用するため、ポートを認識している必要があります。

コンテナーの詳細は、Get Started with Docker Formatted Container Images および Red Hat Enterprise Linux Atomic Host 7: Getting Started with Containers を参照してください。

14.6. コンテンツ配信サーバーの Docker コンテンツの管理

14.6.1. Red Hat Update Infrastructure の Docker コンテンツ

Docker コンテンツには、コンテナー、イメージ、およびプラットフォームイメージが含まれます。現時点で、docker コンテンツには利用可能なエンタイトルメントの適用がありません。このような機能を準備するには、最初に docker クライアントが X.509 証明書をサポートする必要があります。RHUI への影響は、ダウンロードまたは公開済みの docker コンテンツが CDS のレジストリーで公開されていることです。

コンテナーはアプリケーションのサンドボックスです。各コンテナーは、必要な設定データを保持するイメージに基づいています。イメージからコンテナーを起動すると、書き込み可能な階層がこのイメージの上部に追加されます。コンテナーをコミットするたびに (docker commit コマンドを使用)、変更を保存する新しいイメージ層が追加されます。

イメージは、変更されることのない読み取り専用レイヤーです。変更はすべて最上位の書き込み可能なレイヤーで行われ、新規イメージを作成することによってのみ保存できます。各イメージは、複数の親イメージに依存します。

プラットフォームイメージは、親のないイメージです。プラットフォームイメージは、コンテナー化されたアプリケーションの実行に必要なランタイム環境、パッケージ、およびユーティリティーを定義します。プラットフォームイメージは読み取り専用であるため、その上部にスタックされたコピーイメージに変更が反映されます。

14.6.2. Red Hat Update Infrastructure へのコンテナーの追加

次の手順を実行して、RHUI 経由の Docker が使用されるクライアントマシンに Docker コンテナーを追加します。docker にアクセスするには、Red Hat Enterprise Linux Extras リポジトリーへのアクセスが必要です。

注記

以前のリリースでは、RHUI は常に registry.access.redhat.com からコンテナーを同期していました。バージョン 3.1.3 以降では、RHUI は registry.redhat.io をデフォルトのオプションとして使用しますが、Quay.io などの他のレジストリーからコンテナーを同期することもできます。

レジストリーは、多くの場合、すべてのコンテナーまたはプライベートコンテナーに認証を必要とします。registry.redhat.io の場合、Red Hat の認証情報または レジストリーサービスアカウント の認証情報は常に使用する必要があります。RHUI は、コンテナーを同期できるようにするために有効な資格情報を必要とします。RHUI に認証情報を提供する方法には、どちらも以下の手順で説明されています。

手順

  1. クライアントを登録し、4章Red Hat Update Infrastructure の登録およびサブスクリプションの割り当て の手順を使用してサブスクリプションを取得します。
  2. または、Subscription Management ツールを使用してシステムを登録し、docker パッケージをインストールすることもできます。必要なソフトウェアリポジトリーも有効にします。(pool_id を、RHEL 7 サブスクリプションのプール ID に置き換えます。) 以下に例を示します。

    # subscription-manager register --username=rhnuser --password=rhnpasswd
    # subscription-manager list --available    Find valid RHEL pool ID
    # subscription-manager attach --pool=pool_id
    # subscription-manager repos --enable=rhel-7-server-extras-rpms
    # subscription-manager repos --enable=rhel-7-server-optional-rpms

    現在の RHEL 7 リリースおよび RHEL 7 Atomic Host リリースにはそれぞれ Docker の異なるバージョンが含まれます。

    • docker: このパッケージには、RHEL の現在のリリースのデフォルトである Docker のバージョンが含まれます。Red Hat Enterprise Linux で利用可能な Kubernetes および OpenShift の現行バージョンと互換性があるより安定したバージョンの Docker が必要な場合は、このパッケージをインストールします。
    • docker-latest: このパッケージには、新しいバージョンの Docker が含まれており、Docker の新機能と連携する場合に使用できます。このバージョンは、Red Hat Enterprise Linux の現在のリリースで利用可能な Kubernetes および OpenShift のバージョンと互換性がありません。

      docker パッケージおよび docker-latest パッケージの内容と docker-latest パッケージを有効にする方法は、Red Hat Enterprise Linux リリースノート の Atomic Host および Containers セクションを参照してください。

  3. デフォルトの docker パッケージをインストールして使用します (まだインストールされていない場合は、いくつかの依存パッケージも一緒にインストールします)。

    # yum install docker device-mapper-libs device-mapper-event-libs

    Docker および Red Hat Enterprise Linux および Atomic Host の詳細は、Getting Started with Containers のセクション 1.3 Docker および Red Hat Enterprise Linux および Atomic Host の詳細は、Getting Started with Containers の Getting Started with Containers を参照してください。

  4. 必要に応じて、RHUI 設定でコンテナーレジストリーの認証情報を設定します。これを行うには、/etc/rhui/rhui-tools.conf ファイルを編集します。RHUI 3.1.3 以降をクリーンインストールしている場合、最後の数行には、docker 固有のオプションと便利なコメントが含まれる [docker] セクションが含まれます。以前のバージョンから更新した場合、このセクションは /etc/rhui/rhui-tools.conf.rpmnew ファイルの最後にあり、rhui-tools.conf ファイルにコピーできます。次のように、docker セクションの行のコメントを解除します。

    [docker]
    …
    docker_username: your_RH_login
    docker_password: your_RH_password

    通常、registry.redhat.io とは異なる レジストリー から同期する場合は、それに応じて docker_url オプションと docker_auth オプションの値も変更します。

    または、設定ファイルにパスワードを表示したくない場合は、docker_password でコメントアウトされた行をコメントにしたまま、ログインのみを設定します。次に、新規コンテナーを追加するときに手動でパスワードを入力します。

  5. Red Hat Update Infrastructure Management Tool から、r を押して Repository Management 画面にアクセスします。

    -= Red Hat Update Infrastructure Management Tool =-
    
    -= Repository Management =-
    
    l   list repositories currently managed by the RHUI
    i   display detailed information on a repository
    a   add a new Red Hat content repository
    ad  add a new Red Hat docker container
    c   create a new custom repository (RPM content only)
    d   delete a repository from the RHUI
    u   upload content to a custom repository (RPM content only)
    ur  upload content from a remote web site (RPM content only)
    p   list packages in a repository (RPM content only)
    
    Connected: rhua.example.com
  6. ad を押して、新しい Red Hat docker コンテナーを追加します。

    rhui (repo) => ad
    
    Enter the URL of the registry, for example http://registry.redhat.io
  7. 上記のコンテナーがデフォルト以外のレジストリーにある場合は、レジストリー URL を入力します。デフォルトのレジストリーを使用するには、何も入力せずに Enter キーを押します。
  8. レジストリーにコンテナーの名前を入力します。

    jboss-eap-6/eap64-openshift
  9. コンテナーの一意の ID を入力します。

    注記

    hui-manager は、コンテナーの名前をレジストリーから Pulp で使用できる形式に変換できます。これは、スラッシュとドットをアンダースコアに置き換えて行います。このような変換名を許可するには、Enter を押すか、または任意の名前を入力します。

    jboss-eap-6_eap64-openshift
  10. コンテナーの表示名を入力します。
  11. RHUI 設定でログインまたはパスワードを設定していない場合は、プロンプトが表示される場合があります。続行するのに必要な情報を入力します。
  12. 概要が表示されます。

    The following container will be added:
      Registry URL:              http://registry.redhat.io
      Container Id:              jboss-eap-6_eap64-openshift
      Display Name:              jboss-eap-6_eap64-openshift
      Upstream Container Name:   jboss-eap-6/eap64-openshift
    Proceed? (y/n)
  13. y を押して続行するか、n を押してキャンセルします。

    y
    Successfully added container JBoss_EAP_Container
  14. ^ を押して、Red Hat Update Infrastructure Management Tool のホーム画面に戻ります。
注記

間違った認証情報を使用すると、コンテナーは追加されますが、同期することができません。この場合、コンテナーを RHUI から削除し、正しい認証情報で再び追加します。

重要

認証情報は、RHUI に追加する各コンテナーのメタデータとして保存されます。パスワードを変更すると、資格情報が無効になり、コンテナーの同期を継続できなくなります。コンテナーのメタデータのパスワードを変更するには、RHUA ノードの次のコマンドを使用して MongoDB でパスワードを変更します。

# mongo pulp_database --eval 'db.repo_importers.update({"config.basic_auth_password":"YOUR_OLD_PASSWORD"}, {$set:{config:{basic_auth_password:"YOUR_NEW_PASSWORD"}}}, {multi:true})'

または、RHUI から影響を受けるコンテナーをすべて削除し、新しいパスワードで再び追加します。

パスワードを変更するとき、古いパスワードを持っている場合は、/etc/rhui/rhui-tools.conf ファイルでパスワードを変更することを忘れないでください。

14.6.3. Docker リポジトリーの同期

手順

  1. s を押して、Synchronization Status 画面にアクセスします。
  2. sr を押して、個々のリポジトリーを即時に同期します。
  3. 同期するリポジトリーの数を入力します。
  4. c を押して選択を確認します。他のコマンドの場合は ? と入力します。
  5. y を押して続行するか、n を押してキャンセルします。

    The following repositories will be scheduled for synchronization:
      jboss-eap-6_eap64-openshift
    Proceed? (y/n) y
    Scheduling sync for jboss-eap-6_eap64-openshift...
    ... successfully scheduled for the next available timeslot.
  6. ^ を押して、Red Hat Update Infrastructure Management Tool のホーム画面に戻ります。

14.6.4. Docker クライアント設定の生成

クライアント設定 RPM は、RHUI から docker コンテナーをプルする必要のある RHUI クライアントを対象としています。RPM にはロードバランサーの証明書が含まれます。RPM をインストールする際に、以下を行います。

  • ロードバランサーを docker レジストリーとして追加します。
  • docker 設定を変更します。

手順

  1. e を押して Client Entitlement Management 画面にアクセスします。
  2. d を押して docker クライアント設定 RPM を作成します。
  3. 生成されるクライアント設定ファイルを保存するローカルディレクトリーへの完全パスを入力します。このディレクトリーが存在しない場合は作成されます。

    /root/
  4. RPM の名前を入力します。

    dockertest
  5. 設定 RPM のバージョン番号を入力します。デフォルトは 2.0 です。
  6. 設定 RPM のリリース番号を入力します。デフォルトは 1 です。
  7. Docker コンテンツを提供するポートを入力します。デフォルトは 5000 です。

    Successfully created client configuration RPM.
    Location: /root/dockertest-2.0/build/RPMS/noarch/dockertest-2.0-1.noarch.rpm

14.6.5. クライアントへの RPM のインストール

手順

  1. RPM が保存されるディレクトリーに移動します。

    [root@rhua noarch]# cd /root/dockertest-2.0/build/RPMS/noarch/
  2. RPM をクライアントにコピーします。

    # scp dockertest-2.0-1.noarch.rpm <hostname_of_cli:path_on_cli>
  3. クライアントに切り替え、RPM をインストールします。

    [root@cli01 ~]# yum install dockertest-2.0-1.noarch.rpm
    
    Loaded plugins: amazon-id, rhui-lb, search-disabled-repos
    Examining dockertest-2.0-1.noarch.rpm: dockertest-2.0-1.noarch
    Marking dockertest-2.0-1.noarch.rpm to be installed
    Resolving Dependencies
    --> Running transaction check
    ---> Package dockertest.noarch 0:2.0-1 will be installed
    --> Processing Dependency: docker-common for package: dockertest-2.0-1.noarch
    rhel-7-server-rhui-extras-rpms                                                                    | 3.4 kB
    
    --> Running transaction check
    ---> Package docker-common.x86_64 2:1.10.3-59.el7 will be installed
    --> Finished Dependency Resolution
    
    Dependencies Resolved
    
    =========================================================================================================================
     Package                  Arch              Version                      Repository                                 Size
    =========================================================================================================================
    Installing:
     dockertest               noarch            2.0-1                        /dockertest-2.0-1.noarch                  1.7 k
    Installing for dependencies:
     docker-common            x86_64            2:1.10.3-59.el7              rhel-7-server-rhui-extras-rpms             63 k
    
    Transaction Summary
    =========================================================================================================================
    Install  1 Package (+1 Dependent package)
    
    Total size: 64 k
    Total download size: 63 k
    Installed size: 4.7 k
    Is this ok [y/d/N]: y
    Downloading packages:
    docker-common-1.10.3-59.el7.x86_64.rpm                                                            |  63 kB  00:00:01
    Running transaction check
    Running transaction test
    Transaction test succeeded
    Running transaction
    
    Installed:
      dockertest.noarch 0:2.0-1
    
    Dependency Installed:
      docker-common.x86_64 2:1.10.3-59.el7
    
    Complete!

14.6.6. クライアントでの docker pull コマンドのテスト

docker pull コマンドは、コンテナーのコンテンツを使用します。以下の手順では、クライアントで docker pull コマンドをテストする方法を説明します。

手順

  1. docker サービスを開始します。

    [root@cli01 ~]# systemctl start docker
  2. docker pull コマンドを実行します。

    [root@cli01 ~]# docker pull jboss-eap-6_eap64-openshift
    
    Using default tag: latest
    Trying to pull repository cds.example.com:5000/jboss-eap-6_eap64-openshift ...
    latest: Pulling from cds.example.com:5000/jboss-eap-6_eap64-openshift
    30cf2e26a24f: Pull complete
    99dd41655d8a: Pull complete
    05d9aa366d71: Pull complete
    39feddb214c9: Pull complete
    76786100be04: Pull complete
    d48e1afdcad8: Pull complete
    Digest: sha256:5331cae5edaeede56c7e14bede8608229a89f73067d7373af246cabe4b8d4a24
    Status: Downloaded newer image for cds.example.com:5000/jboss-eap-6_eap64-openshift:latest
  3. docker pull コマンドが失敗した場合は、rhui-manager container synchronization ステータスを確認します。同期がまだ実行されていない可能性があり、同期するまで待機する必要があります。

    Using default tag: latest
    Trying to pull repository cds.example.com:5000/jboss-eap-6_eap64-openshift ...
    unknown: Not Found
    Trying to pull repository docker.io/library/jboss-eap-6_eap64-openshift ...
    Pulling repository docker.io/library/jboss-eap-6_eap64-openshift
    Error: image library/jboss-eap-6_eap64-openshift not found
    Error: image library/jboss-eap-6_eap64-openshift not found

14.7. Atomic Host および OSTree コンテンツ

Red Hat Enterprise Linux Atomic Host は、Linux コンテナーの実行に最適化された Red Hat Enterprise Linux 7 の様々なタイプです。軽量で効率的なシステムとして構築され、クラウド環境用のコンテナーランタイムシステムとしての使用を特別に最適化します。RHEL Atomic Host には、コンテナーを実行するための多くのツールがプリインストールされています (dockeratomicetcdflannel)。オールインワンの kubernetes インストールは引き続きサポートされますが、Red Hat は Kubernetes クラスターをサポートしなくなりました。

RHEL Atomic Host は、rpm-OSTree と呼ばれるオープンソースツールを使用して、RPM コンテンツで設定される、起動可能で、不変の、バージョン管理されたファイルシステムツリーを管理します。Red Hat は、パッケージからこれらのツリーを構築し、rpm-ostree ツールはアトミックに複製します。これにより、アトミック更新に関するアップグレードおよびメンテナーンスストラテジーが作成されます。yum の代わりに rpm-ostree を使用してソフトウェアをアップグレードおよび維持すると、RHEL Atomic Host は他の RHEL 7 バリアントとは異なる方法で管理されます。

特に RHEL Atomic Host を使用する場合、オペレーティングシステムのコンテンツは読み取り専用モードでマウントされます。ローカルシステム設定用の書き込み可能なディレクトリーは /etc//var/ だけです。更新は以下の方法で行われます。新規の起動可能なファイルシステムツリーが生成されます。これは、現在のファイルシステムツリーとストレージを共有します。新しいシステムツリーをダウンロードすると、古いツリーは並行して保持されます。つまり、ファイルシステムのツリーの最初のアップグレード前のバージョンは、必要に応じてアトミックに復元できます。

コンテナーやデータを含むアップグレード後も維持されるユーザーファイルを /var/ ディレクトリーに置く必要があります。オペレーティングシステム自体は /usr/ ディレクトリーに保存され、読み取り専用です。コマンド ls-l/ を使用してルートディレクトリーで長いファイルリストを実行すると、従来のルートレベルディレクトリーの多くがこれら 2 つの場所のいずれかへのシンボリックリンクであることがわかります。たとえば、/home/ ディレクトリーは、/var/home/ ディレクトリーへのシンボリックリンクです。このディレクトリーは、アップグレード後も存続します。

デフォルトのパーティション設定では、Red Hat Enterprise Linux にあるように、デフォルトのループバックではなく、ストレージバックエンドとして直接 LVM を使用して、コンテナーで利用可能なほとんどの領域が示されます。ストレージは docker-storage-setup デーモンによって管理されます。このデーモンは、インストール中に 2 つの論理ボリュームを作成します。これらは、ファイルシステムコンテンツ用の root と、イメージとコンテナー用の docker-pool です。

RHEL Atomic Host は SELinux を使用してマルチテナント環境で強力な保護を提供します。iptables サービスはファイアウォールとして利用できます。iptables はデフォルトでオフになっています。

Red Hat Atomic Host に関する詳細は、Red Hat Enterprise Linux Atomic Host 7 インストールと設定ガイド を参照してください。

14.7.1. Atomic Host リポジトリーの追加

手順

  1. 「リポジトリーの作成」 の手順 1 から 5 に従って、新しい Red Hat コンテンツリポジトリーを追加します。
  2. 2 を押して、By Product メソッドを選択します。

    Import Repositories:
      1  - All in Certificate
      2  - By Product
      3  - By Repository
    Enter value (1-3) or 'b' to abort:
  3. リポジトリーの横にある番号を入力して、リストから atomic リポジトリーを選択します。

    Red Hat Enterprise Linux Atomic Host (Trees) from RHUI
  4. c を押します。Red Hat Update Infrastructure Management Tool は、デプロイされるリポジトリーを表示し、確認を求めるプロンプトを表示します。
  5. y を押して先に進みます。リポジトリーがデプロイされると、メッセージが出力されます。
  6. l を押して、list repositories currently managed by the RHUI 画面にアクセスするには、そのリポジトリーがインストールされていることを確認します。

14.7.2. OSTree リポジトリーの同期

手順

  1. s を押して、Synchronization Status 画面にアクセスします。
  2. sr を押して、個々のリポジトリーを即時に同期します。
  3. 同期するリポジトリーの数を入力します。
  4. c を押して選択を確認します。他のコマンドの場合は ? と入力します。
  5. y を押して続行するか、n を押してキャンセルします。

    The following repositories will be scheduled for synchronization:
      Red Hat Enterprise Linux Atomic Host (Trees) from RHUI (Version 7.3.4)
    Proceed? (y/n) y
    Scheduling sync for Red Hat Enterprise Linux Atomic Host (Trees) from RHUI (Version 7.3.4)...
    ... successfully scheduled for the next available timeslot.
    ------------------------------------------------------------------------------------------------------------------------------
    rhui (sync) =>
  6. ^ を押して、Red Hat Update Infrastructure Management Tool のホーム画面に戻ります。

14.7.3. RHUA でのクライアント設定パッケージの生成

手順

  1. 「エンタイトルメント証明書の作成」 の手順に従って、OSTree リポジトリーの資格証明書を生成します。最近追加した OSTree リポジトリーを証明書に追加します。
  2. Red Hat Update Infrastructure Management Tool のホーム画面で e を押して、エンタイトルメント証明書およびクライアント設定 RPM の作成 を選択します。
  3. Client Entitlement Management 画面で o を押して、create an atomic client configuration package を選択します。

    -= Red Hat Update Infrastructure Management Tool =-
    
    -= Client Entitlement Management =-
    
    e   generate an entitlement certificate
    c   create a client configuration RPM from an entitlement certificate
    d   create a docker client configuration RPM
    o   create an atomic client configuration package
    
                                          Connected: rhua.example.com
  4. 設定ファイルを保存するローカルディレクトリーの完全パスを入力します。

    Full path to local directory in which the client configuration files generated by this tool
    should be stored (if this directory does not exist, it will be created):
    
    /tmp
  5. .tar ファイルの名前を入力します。

    Name of the tar file (excluding extension):
    testcerttar
  6. 特定のチャネルにアクセスするためにクライアントを認証するエンタイトルメント証明書への完全パスを入力します。

    Full path to the entitlement certificate authorizing the client to access
    specific channels:
    /tmp/testcert.crt
  7. エンタイトルメント証明書の秘密鍵への完全パスを入力します。

    Full path to the private key for the above entitlement certificate:
    /tmp/testcert.key
  8. docker コンテンツを提供するポートを入力します。Port 5000 がデフォルトになります。

    Port to serve Docker content on (default 5000):
    
    Successfully created client configuration package.
    Location: /tmp/testcerttar.tar.gz

14.7.4. Atomic Host の設定

手順

  1. 生成された .tar.gz ファイルを Atomic Host にコピーします。
  2. tar ファイルを展開します。
  3. install.sh スクリプトを実行します。

    [root@atomiccli01 ~]# ./install.sh

14.7.5. Atomic Host での ostree pull コマンドのテスト

ostree pull コマンドは、コンテナーからコンテンツを消費します。

手順

  1. ostree pull コマンドを実行します。

    [root@atomiccli01 ~] ostree pull rhui-rhel-atomic-host-rhui-ostree:rhel-atomic-host/7/x86_64/standard
    
    GPG: Verification enabled, found 1 signature:
    
      Signature made Mon 10 Apr 2017 04:46:45 PM UTC using RSA key ID 199E2F91FD431D51
      Good signature from "Red Hat, Inc. <security@redhat.com>"
    
    809 metadata, 4395 content objects fetched; 308693 KiB transferred in 108 second
  2. ostree pull コマンドがエラーを返した場合は、OSTree リポジトリーの Synchronization ステータスを確認してください。同期がまだ実行されていない可能性があり、同期するまで待機する必要があります。

バグの報告

第15章 証明書および鍵の管理

15.1. Red Hat Update Appliance 証明書

Red Hat Update Infrastructure (RHUI) の Red Hat Update Appliance (RHUA) は、以下の証明書およびキーを使用します。

  • コンテンツ証明書および秘密鍵
  • エンタイトルメント証明書および秘密鍵
  • SSL 証明書および秘密鍵
  • クラウドプロバイダー認証局 (CA) の証明書

RHUA は、コンテンツ証明書とエンタイトルメント証明書で設定されます。RHUA はコンテンツ証明書を使用して Red Hat コンテンツ配信ネットワーク (CDN) に接続します。また、Red Hat CA 証明書を使用して Red Hat CDN への接続を確認します。RHUA は Red Hat CDN に接続する唯一のコンポーネントであるため、この証明書がデプロイされた唯一の RHUI コンポーネントになります。複数の RHUI インストールが同じコンテンツ証明書を使用できることに注意してください。たとえば、Amazon EC2 クラウドは、(リージョンごとに) RHUI インストールを複数実行しますが、各 RHUI インストールは同じコンテンツ証明書を使用します。

クライアントはエンタイトルメント証明書を使用して RHUI のパッケージへのアクセスを許可します。環境ヘルスチェックを実行するには、RHUA は各 CDS に対して yum 要求を試みます。成功するには、yum リクエストに有効なエンタイトルメント証明書を指定する必要があります。

AWS リージョンの詳細については、グローバルインフラストラクチャー を参照してください。

15.2. コンテンツ配信サーバー証明書

RHUI の各 CDS ノードは以下の証明書およびキーを使用します。

  • SSL 証明書および秘密鍵
  • クラウドプロバイダーの CA 証明書

CDS に必要な唯一の証明書は SSL 証明書で、クライアントと CDS 間の HTTPS 通信を許可します。SSL 証明書は特定のホスト名にスコープ設定されているため、各 CDS ノードには一意の SSL 証明書が必要になります。CDS への接続時に SSL エラーが発生する場合は、証明書のコモンネームが、インストールされている CDS の完全修飾ドメイン名 (FQDN) に設定されていることを確認してください。

CA 証明書は、yum 要求の一部としてクライアントが送信したエンタイトルメント証明書がクラウドプロバイダーにより署名されたことを確認するために使用されます。これにより、不正なインスタンスが RHUI 内で不正に使用するための独自のエンタイトルメント証明書を生成することを回避できます。

15.3. クライアント証明書

RHUI の各クライアントは、以下の証明書およびキーを使用します。

  • エンタイトルメント証明書および秘密鍵
  • クラウドプロバイダーの CA 証明書

エンタイトルメント証明書とその秘密鍵により、CDS からクライアントへの情報の暗号化が有効になります。各クライアントは、CDS に接続する際にエンタイトルメント証明書を使用して、パッケージをダウンロードするパーミッションがあることを証明します。すべてのクライアントは単一のエンタイトルメント証明書を使用します。

クラウドプロバイダーの CA 証明書は、接続時に CDS の SSL 証明書を検証するために使用されます。これにより、悪意のあるインスタンスが CDS を偽装して、悪意のある可能性のあるパッケージをクライアントに導入することがなくなります。

CA 証明書は、資格証明書ではなく、CDS の SSL 証明書を検証するために使用されます。CDS ノードの逆は true です。CDS の SSL 証明書と秘密鍵は、クライアントから CDS へのデータを暗号化するために使用されます。CDS 上にある CA 証明書は、CDS ノードがクライアントによって送信されたエンタイトルメント証明書を信頼する必要があることを確認するために使用されます。

15.4. 証明書の表示および管理

Red Hat は、元のエンタイトルメント証明書を発行すると、要求したリポジトリーへのアクセスが許可されます。クライアントエンタイトルメント証明書を作成する場合、クライアントを細分化し、クライアントごとに個別の証明書を作成する方法を決定する必要があります。次に、各証明書を使用して、適切なゲストイメージへのインストール用に個別の RPM を作成できます。

15.4.1. 証明書の対象製品を一覧表示

Entitlements Manager 画面は、現在の Red Hat コンテンツ証明書でエンタイトルメントの付いた製品の一覧を表示し、新しい証明書をアップロードするのに使用されます。

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
  2. プロンプトで n を押して、Entitlements Manager 画面にアクセスします。
  3. Entitlements Manager 画面で l を押して、現在のコンテンツ証明書に関するデータを一覧表示します。Red Hat Update Infrastructure Management Tool は、証明書に関する以下の情報を表示します。

    rhui (entitlements) => l
    
    Red Hat Entitlements
    
    Valid
    RHEL RHUI Atomic 7 Ostree Repo
    Expiration: 08-04-2025 	Certificate: content_cert.pem
    
    RHEL RHUI Server 7 7server Extras Debug
    Expiration: 08-04-2025 	Certificate: content_cert.pem
    
    RHEL RHUI Server 7 7server Extras OS
    Expiration: 08-04-2025 	Certificate: content_cert.pem
    
    RHEL RHUI Server 7 7server Extras Source Srpms
    Expiration: 08-04-2025 	Certificate: content_cert.pem
    
    RHEL RHUI Server 7 Containers
    Expiration: 08-04-2025 	Certificate: content_cert.pem
    
    RHEL RHUI Server 7 Debug
    Expiration: 08-04-2025 	Certificate: content_cert.pem
    
    RHEL RHUI Server 7 OS
    Expiration: 08-04-2025 	Certificate: content_cert.pem
    ---------------------------------------------------------------

15.4.2. List custom repository entitlements

手順

  1. Red Hat Update Infrastructure Management Tool のホーム画面に移動します。

    [root@rhua ~]# rhui-manager
  2. プロンプトで n を押して、Entitlements Manager 画面にアクセスします。
  3. プロンプトで c を押して、カスタムリポジトリーの資格に関するデータを一覧表示します。

    rhui (entitlements) => c
    
    Custom Repository Entitlements
    For each entitlement URL listed, the corresponding repositories that are
    configured with that entitlement are listed.
    
    /protected/$basearch/os
    
     Name: Repo 1
    URL: protected/i386/os
    
    Name: Repo 2
    URL: protected/x86_64/os

15.4.3. コンテンツ証明書のアップロード

現在の証明書の有効期限が近づいている場合、Red Hat は新しいコンテンツ証明書を発行する必要がある場合があります。これは通常 2 年ごとに発生します。Red Hat は、証明書のエンタイトルメントを変更する必要がある場合もあります。これは、証明書の有効期限が切れるよりも頻繁に発生する可能性があります。2 つ以上のコンテンツ証明書が同じ資格を提供する場合、有効期限が最も遠い証明書が使用されます。

Red Hat が新しいコンテンツ証明書を発行する場合は、RHUI にアップロードする必要があります。新しいコンテンツ証明書がアップロードされると、RHUA で更新され、Red Hat リポジトリーの同期に使用されます。

新しい証明書をダウンロードして RHUI にアップロードしなくても、証明書が自動的に更新されるようにすることができます。これを行うには、「エンタイトルメント証明書の自動更新の有効化」 の手順に従ってください。

重要

rhsmcertd サービスが実行され、有効になっていることを確認してください。

有効になる前に新しいコンテンツ証明書をアップロードしないでください。これを行うと、有効な日付に達するまで Synchronization が失敗します。

重要

新しい証明書をインストールする前に、すべての CDS ノードが実行されていることを確認してください。そうでない場合、コンテンツ証明書の更新プロセス (rhui-manager cert upload コマンドによって開始される) は失敗します。

手順

  1. 次のいずれかの方法を使用して、すべての CDS ノードが実行されているかどうかを確認します。

    1. システム内の各 CDS ノードにログインして、その Web サーバーが稼働しているかどうかを確認します。

      1. systemctl status httpd コマンドを実行します。
      2. ログインできない場合、または返されるステータスが inactive の場合、その特定の CDS は実行されていません。
    2. HAProxy ノードにログインして、HAProxy が管理対象 CDS ノードに関して定期的に収集する統計を表示します。

      1. echo show stat | nc -U /var/lib/haproxy/stats コマンドを実行します。
      2. コマンドがホスト名に対して DOWN を返す場合、その CDS は実行されていません。
  2. Red Hat Update Infrastructure Management Tool は、コンテンツ証明書とその秘密鍵が同じファイルに含まれていることを想定しています。別のキーを持つ既存のコンテンツ証明書がある場合は、シェルプロンプトで cat コマンドを使用して 1 つのファイルを作成できます。

    # cat file1 file2 > file3
  3. Entitlements Manager 画面で u を押して、新規または更新された Red Hat コンテンツ証明書をアップロードします。

    rhui (entitlements) => u
    重要

    コンテンツ証明書は、Red Hat Update Infrastructure Management Tool が /etc/pki/rhui にインストールされているシステムに保存されます。セキュリティー上の理由から、このディレクトリーには root 権限が必要です。適切なパーミッションがないと、Red Hat Update Infrastructure Management Tool は先に進めません。

  4. 新しいコンテンツ証明書への完全パスを入力します。アップロードする新規証明書の詳細が表示されます。
  5. プロンプトで y を押して、情報を確認し、パッケージをアップロードします。Red Hat Update Infrastructure Management Tool は、現在の証明書を一覧表示します。

バグの報告

第16章 ステータスコード、ログファイル、および設定ファイル

表16.1 ステータスコード

ステータスコード説明

0

成功

1

リポジトリーの同期エラー

32

エンタイトルメント CA 証明書の有効期限に関する警告

64

エンタイトルメント CA 証明書の有効期限エラー

表16.2 ログファイル

Componentファイルまたはディレクトリー使用方法

Red Hat Update Appliance

/root/.rhui/rhui.log* (rhui-manager が root として実行されていることを前提)

Red Hat Update Infrastructure Management Tool のログ

 

/var/log/kafo/configuration.log

RHUI のインストールロギング情報

 

/var/log/messages

直近の 4 つのバージョンは、現在書き込まれたファイルに加えて保持されます。

 

/var/log/httpd/*

Apache ログ

 

/var/log/messages

Qpid ログ

 

/var/log/rhui-subscription-sync.log

サブスクリプションの同期ログ

コンテンツ配信サーバー

/var/log/httpd/*

Apache ログ

 

/var/log/httpd/ssl_access_log

ロギングの例 – Successful yum repolist: the CDS nodes log this client activity

クライアント

/var/log/yum.log

yum コマンドログ

 

/var/log/messages

クライアント syslog

 

yum コマンドのコンソール出力

 

表16.3 設定ファイル

Componentファイルまたはディレクトリー使用方法

Red Hat Update Appliance

/etc/pulp/*

Pulp 設定ファイル

 

/etc/rhui/rhui-tools.conf

rhui-manager 設定ファイル

 

/etc/qpid/qpidd.conf

設定ファイル

 

/etc/pki/rhui/*

Red Hat Update Infrastructure の証明書

 

/etc/pki/pulp/*

コンテンツの証明書

 

/etc/rhui-installer/answers.yaml

RHUA の設定に使用

 

/etc/rhui/rhui-subscription-sync.conf

サブスクリプション同期スクリプトの設定

 

/etc/pulp/admin/admin.conf/etc/pulp/server.conf/etc/pulp/server.conf/etc/pulp/server.conf/etc/pulp/vhosts80/ostree.conf/etc/pulp/vhosts80/rpm.conf

ゾーンの設定ファイル

コンテンツ配信サーバー

/etc/pulp/repo_auth.confetc/pulp/rhui_repo_auth.conf

ゾーンの設定ファイル

コンテンツ配信サーバー

/etc/pki/cds/*

CDS の証明書

HAProxy

/etc/haproxy/haproxy.cfg

HAProxy 設定ファイル

バグの報告

第17章 Red Hat Update Infrastructure のバックアップおよび復元

本章では、Red Hat Update Infrastructure のバックアップおよび復元の手順を説明します。Pulp および MongoDB のバックアップに関する詳細は、Pulp Backups および MongoDB Backup Methods を参照してください。

17.1. Red Hat Update Appliance のバックアップ作成

以下の手順に従って、Red Hat Update Appliance サーバーをバックアップします。停止サービスは、クライアントが Red Hat Update Appliance サーバーではなく、コンテンツ配信サーバー (CDS) にのみ接続されているため、パッケージの更新またはインストールをクライアントインスタンスで無効にしません。自動モニターリングソリューションが導入されている場合には、バックアッププロセス中に監視が失敗する可能性があります。

手順

  1. Red Hat Update Centre にデプロイされているリポジトリーの数によっては、/var/lib/pulp ディレクトリーのサイズが大きくなる場合があります。特定のストレージ要件については、Preparing your Environment for Installation を参照するか、コマンドラインインターフェイスから du コマンドを使用して、そのサイズを判断してください。
  2. pulp-server サービスを停止します。

    # systemctl stop pulp_workers; systemctl stop pulp_resource_manager; systemctl stop pulp_celerybeat
  3. 上記のコマンドで stopstatus に置き換え、各サービスが停止したことを確認します。
  4. 以下のファイルは、バックアップ時に現在の属性を保持することが重要です。

    • /etc/httpd/conf.d/05-pulp-https.conf
    • /etc/httpd/conf.d/pulp*
    • /etc/httpd/conf.d/ssl.conf
    • /etc/pki/katello-certs-tools/*
    • /etc/pki/pulp/*
    • /etc/pki/rhui/*
    • /etc/pulp/*
    • /etc/puppet/*
    • /etc/rhui/*
    • /etc/rhui/rhui-tools.conf
    • /etc/rhui-installer/*
    • /etc/qpid/qpidd.conf
    • /var/lib/mongodb/pulp_database*
    • /var/lib/pulp/*
    • /var/log/pulp/*
    • /var/log/httpd/*
    • /var/lib/puppet/*

      次のコマンドを使用してファイルをバックアップします。

      # cp -a source_files_path destination_files_path
  5. 生成されたクライアントエンタイトルメント証明書およびクライアント設定 RPM をバックアップできます。
  6. pulp-server サービスを再起動します。

    # systemctl start pulp_workers; systemctl start pulp_resource_manager; systemctl start pulp_celerybeat
  7. 上記のコマンドで startstatus に置き換え、各サービスが開始したことを確認します。

17.2. Red Hat Update Appliance エンタイトルメントの復元

手順

  1. 「Red Hat Update Infrastructure の登録」 および 「Red Hat Update Appliance に対するサブスクリプションの割り当て」 に従って、新しい Red Hat Update Appliance インスタンスを準備します。これらの手順が完了したら、次の復元手順に進みます。
  2. pulp-server サービスを停止します。

    # systemctl stop pulp_workers; systemctl stop pulp_resource_manager; systemctl stop pulp_celerybeat
  3. 上記のコマンドで stopstatus に置き換え、各サービスが停止したことを確認します。

    重要

    復元に含まれるファイルは、現在の属性を保持することが重要です。

  4. 次のコマンドを使用して、ファイルを元の場所に復元します。

    # cp -a source_files_path destination_files_path
  5. pulp-server サービスを再起動します。

    # systemctl start pulp_workers; systemctl start pulp_resource_manager; systemctl start pulp_celerybeat
  6. 上記のコマンドで startstatus に置き換え、各サービスが開始したことを確認します。

17.3. コンテンツ配信サーバーのバックアップを作成

以下の手順に従って、CDS をバックアップします。停止を軽減するために、CDS が複数ある場合は、 CD を一度に 1 つだけバックアップします。クライアントインスタンスは、実行中の他の CDS インスタンスに自動的にフェイルオーバーします。

手順

  1. Red Hat Update Centre にデプロイされているリポジトリーの数によっては、/var/lib/pulp ディレクトリーのサイズが大きくなる場合があります。特定のストレージ要件については、Preparing your Environment for Installation を参照するか、コマンドラインインターフェイスから du コマンドを使用して、そのサイズを判断してください。
  2. httpd サービスを停止します。

    # systemctl stop httpd
  3. 上記のコマンドで stopstatus に置き換え、各サービスが停止したことを確認します。
  4. 以下のファイルは、バックアップ時に現在の属性を保持することが重要です。

    • /etc/httpd/conf.d/*.conf
    • /var/lib/pulp/*
    • /var/log/pulp/*
    • /var/log/httpd/*
    • /etc/pki/rhui/*
    • /etc/pulp/*
    • /var/lib/puppet/*

      次のコマンドを使用してファイルをバックアップします。

      # cp -a source_files_path destination_files_path
  5. 上記のファイルのほかにも、生成されたクライアントエンタイトルメント証明書とクライアント設定 RPM のバックアップを作成することが推奨されます。
  6. サービスを再起動します。

    # systemctl start httpd
  7. 上記のコマンドで startstatus に置き換え、各サービスが開始したことを確認します。

17.4. コンテンツ配信サーバーの復元

手順

  1. 「コンテンツ配信サーバーの追加」 の手順に従って、新しい CDS インスタンスを準備します。これらの手順が完了したら、次の復元手順に進みます。
  2. httpd サービスを停止します。

    # systemctl stop httpd
  3. 上記のコマンドで stopstatus に置き換え、各サービスが停止したことを確認します。

    重要

    復元に含まれるファイルは、現在の属性を保持することが重要です。

  4. 次のコマンドを使用して、ファイルを元の場所に復元します。

    # cp -a source_files_path destination_files_path
  5. httpd サービスを再起動します。

    # systemctl start httpd
  6. 上記のコマンドで startstatus に置き換え、各サービスが開始したことを確認します。

17.5. HAProxy サーバーのバックアップ

以下の手順に従って、HAProxy サーバーのバックアップを作成します。

手順

  1. 以下のファイルは、バックアップ時に現在の属性を保持することが重要です。

    • /etc/haproxy/haproxy.cfg
    • /etc/pki/rhui/*
    • /var/lib/puppet/*
  2. 次のコマンドを使用してファイルをバックアップします。

    # cp -a source_files_path destination_files_path
  3. 上記のファイルのほかにも、生成されたクライアントエンタイトルメント証明書とクライアント設定 RPM のバックアップを作成することが推奨されます。

17.6. HAProxy サーバーの復元

手順

  1. 8章HAProxy ロードバランサーの追加 の手順をすべて実行して、新規の HAProxy インスタンスを準備します。これらの手順が完了したら、次の復元手順に進みます。

    重要

    復元に含まれるファイルは、現在の属性を保持することが重要です。

  2. 次のコマンドを使用して、ファイルを元の場所に復元します。

    # cp -a source_files_path destination_files_path

バグの報告

第18章 新しいロードバランサーに移行するか、既存のロードバランサーの名前を変更します。

この手順に従って、すでに実行されている Red Hat Update Infrastructure (RHUI) 環境でロードバランサーのホスト名を変更します。

手順

  1. pulp サービスを停止します。

    # systemctl stop pulp_\*
  2. コンテンツ配信サーバー (CDS) の証明書ファイルを Red Hat Update Appliance (RHUA) から削除します。

    # rm -f /etc/puppet/rhui-secrets/cds-cert.*
  3. rhui-manager を新規ロードバランサーのホスト名で実行します。以下に例を示します。

    # rhui-installer --cds-lb-hostname=hap02.example.com
    注記

    回答ファイルに示されている初期値またはデフォルト値が必要ない場合は、その他の必要な引数を使用してください。

  4. インタラクティブモード (rhui-manager - l - a - …​) または CLI のいずれかで、新しいロードバランサーを RHUI 環境に追加します。CLI の場合は、以下の例を使用します。

    # rhui haproxy add hap02.example.com ec2-user /root/.ssh/id_rsa_rhua -u
    注記

    古いロードバランサーを同時に登録解除することを検討してください。

  5. インタラクティブモード (rhui-manager - c - r - …​) または CLI のいずれかで、すべての CDS ノードに CDS 設定を再適用します。CLI の場合は、以下の例を使用します。

     # rhui cds reinstall cds01.example.com
  6. 更新されたクライアント設定 RPM を作成します。これはインタラクティブモード (rhui-manager - e - c - …​`) または CLI で実行できます。CLI の場合は、以下の例を使用します。

    # rhui-manager client rpm --private_key /root/rhui.key --entitlement_cert /root/rhui.crt --rpm_version 2.1 --rpm_name rhui-repos --dir /root/
    注記

手順

  1. すべてのクライアントでクライアント設定 RPM を更新します。

バグの報告

付録A Red Hat Update Infrastructure Management Tool のメニューおよびコマンド

Red Hat Update Appliance からアクセスできる Red Hat Update Infrastructure Management Tool 内の 7 つの画面には、Red Hat Update Infrastructure のさまざまなコンポーネントを設定および更新できるメニューオプションがあります。以下の表は、Red Hat Update Infrastructure Management Tool で利用可能なオプションを示しています。

表A.1 Red Hat Update Infrastructure Management Tool のメニューおよびコマンド

スクリーンScreen コマンドメニューオプションメニューオプションコマンド

manage repositories

r

  

Repository Management

 

list repositories currently managed by the RHUI

l

  

display detailed information on a repository

i

  

add a new Red Hat content repository

a

  

add a new Red Hat docker container

ad

  

create a new custom repository (RPM content only)

c

  

delete a repository from the RHUI

d

  

upload content to a custom repository (RPM content only)

u

  

upload content from a remote web site (RPM content only)

ur

  

list packages in a repository (RPM content only)

p

manage content delivery servers (CDS)

c

  

Content Delivery Server (CDS) Management

 

list all known CDS instances managed by the RHUI

l

  

register (add) a new CDS instance

a

  

reinstall and reapply configuration to an existing CDS instance

r

  

unregister (delete) a CDS instance from the RHUi

d

manage HAProxy load-balancer instances

l

  

Load-balancer (HAProxy) Management

 

list all known HAProxy Load-balancer instances managed by the RHUI

l

  

register (add) a new HAProxy Load-balancer instance

a

  

reinstall and reapply configuration to an existing HAProxy Load-balancer instance

r

  

unregister (delete) a HAProxy Load-balancer instance from the RHUI

d

synchronization status and scheduling

s

  

Synchronization Status

 

display repo sync summary

dr

  

view the details of the last repository sync

vr

  

sync an individual repository immediately

sr

create entitlement certificates and client configuration RPMs

e

  

Client Entitlement Management

 

generate an entitlement certificate

e

  

create a client configuration RPM from an entitlement certificate

c

  

create a docker client configuration RPM

d

  

create an atomic client configuration package

o

manage Red Hat entitlement certificates

n

  

Entitlements Manager

 

list Red Hat content certificate entitlements

l

  

list custom repository entitlements

c

  

upload a new or updated Red Hat content certificate

u

manage RHUI users

u

  

User Manager

 

change a user's password

p

バグの報告

付録B Red Hat Update Infrastructure コマンドラインインターフェイス

RHUI の管理タスクの大部分はインストールにあります。インストール後は、Red Hat CDN から定期的に更新パッケージを取得し、クライアントでそのパッケージを自動的に利用できるようにします。

Red Hat Update Infrastructure Management Tool (rhui-manager コマンドで実行する) と呼ばれるコマンドラインインターフェイスは、インストールを容易にします。このツールは、RHUI の各コンポーネント (RHUA、CDS、およびロードバランサー) に必要な設定要素の対話式プロンプトを提供します。このツールは、Red Hat が提供するコンテンツ証明書を取得して、Red Hat CDN に接続するときに使用し、クライアントが RHUI に接続するために使用する内部のクラウド固有の証明書を生成する手段も提供します。Red Hat Update Infrastructure Management Tool を使用すると、クラウドプロバイダーはクライアント RHEL インスタンスにインストールされるクライアント設定バンドルを生成することができます。このバンドルにより、クライアントは RHUI インストールから更新を取得できるようになります。

Red Hat Update Infrastructure Management Tool はインタラクティブシェルを使用して実行するように設計されています。標準のシェルプロンプトからも一部の機能を実行できます。Red Hat Update Infrastructure Management Tool は、主に 5 つのコマンドを使用します。各コマンドのサブコマンドでは、サブコマンドが -h および --help 以外のオプションを想定している場合は、オプションの一覧が提供されます。

すべてのオプションおよびコマンドを表示します。

[root@rhua ~]# rhui-manager --help
Usage: rhui-manager [options]

OPTIONS
   -h/--help  show this help message and exit
   --debug    enables debug logging
   --config   absolute path to the configuration file; defaults to /etc/rhui/rhui-tools.conf
   --server   location of the RHUA server (overrides the config file)
   --username if specified, previously saved authentication credentials are ignored and this username is used to login
   --password used in conjunction with --username

 COMMANDS
   cert          : Red Hat content certificate management
   packages      : package manipulation on repositories
   repo          : repository listing and manipulation
   status        : RHUI status and health information
   client        : Red Hat client management

以下のサブセクションでは、関連付けられたコマンドのサブコマンドとオプションを詳しく説明します。

B.1. cert

  • info: 現在のコンテンツ証明書に関する情報を表示します。

    • (このサブコマンドにはオプションがありません。)
  • upload: 新しいコンテンツ証明書をアップロードします。

    • --cert - 新しいコンテンツ証明書への完全パスです (必須)。
    • --key - 新しいコンテンツ証明書のキーへの完全パスです。

[root@rhua ~]# rhui-manager cert upload --cert /tmp/extra_rhui_files/rhcert.pem
Red Hat Entitlements

  Valid
    Beta RHEL RHUI Everything 7 Debug
    Expiration: 05-17-2026     Certificate: rhcert.pem

    Beta RHEL RHUI Everything 7 OS
    Expiration: 05-17-2026     Certificate: rhcert.pem

B.2. packages

  • list: リポジトリーに含まれるパッケージの一覧を表示します。

    • --repo_id- パッケージを一覧表示するリポジトリーの ID(必須)
  • upload: パッケージ、またはパッケージのディレクトリーをカスタムリポジトリーにアップロードします。

    • --repo_id - パッケージをアップロードするカスタムリポジトリーの ID (必須)
    • --packages - アップロードする RPM の .rpm ファイルまたはディレクトリーへのパス (必須)
  • リモート: RPM コンテンツをリモート URL からカスタムリポジトリーにアップロードします

    • --repo_id - パッケージをアップロードするカスタムリポジトリーの ID (必須)
    • --url-RPM コンテンツ用に抽出されるパッケージまたは Web ページのリモート URL (必須)

[root@rhua ~]# rhui-manager packages upload --repo_id my_custom_repo --packages /tmp/webalizer-2.21-6.2.x86_64.rpm
Uploading /tmp/webalizer-2.21-6.2.x86_64.rpm...
/tmp/webalizer-2.21-6.2.x86_64.rpm successfully uploaded

B.3. repo

  • sync: リポジトリーを同期します。

    • --repo_id - 表示するリポジトリーを特定します (必須)。
  • add_by_repo: リポジトリー ID で Red Hat リポジトリーを RHUA に追加します。

    • --repo_ids - 追加するリポジトリー ID をコンマ区切りで表示します (必須)。
  • unused: 利用可能ですが、RHUA と同期していない製品の一覧です。

    • -by_repo_id - リポジトリー ID 別に未使用の製品を一覧表示します。
  • list: RHUI のすべてのリポジトリーを一覧表示します。

    • --ids_only - リポジトリー ID のみを表示します。
    • --redhat_only - Red Hat リポジトリーのみを一覧表示します。
    • --delimiter - リポジトリーを区切るために使用される文字です。デフォルトは newline です。
  • add: Red Hat リポジトリーを RHUA に追加します。

    • --product_name - RHUA を追加する製品です (必須)。
  • add_errata: エラータメタデータをリポジトリーに関連付けます。

    • --repo_id - メタデータを関連付けるリポジトリー ID (必須)
    • --updateinfo - 適用する updateinfo ファイル (必須)
  • add_comps: メタデータ (group/category/environment/langpacks) をリポジトリーに関連付けます。

    • --repo_id - メタデータを関連付けるリポジトリー ID (必須)
    • --comps - 適用するファイルをコンパイルします (必須)。
  • info: 個々のリポジトリーに関する情報を表示します。

    • --repo_id - 表示するリポジトリーを特定します (必須)。
  • create_custom: カスタムリポジトリーを作成します。

    • repo_id - 追加するリポジトリーを特定します (必須)。
    • path - CDS が提供するコンテンツへのパスです。デフォルトは repo_id です。
    • display_name - カスタムリポジトリーの名前の表示です。
    • entitlement - エンタイトルメント証明書で使用されるパスです。yum の変数置換を使用できます。
    • legacy_md - SHA1 が存在する場合、リポジトリーは SHA1 を使用します。そうでない場合は、デフォルト値 (SHA256) が使用されます。
    • redhat_content - リポジトリーは Red Hat GPG 署名コンテンツをホストします。
    • protected - エンタイトルメント証明書でコンテンツを保護します。
    • gpg_public_keys - 提供されるコンテンツに署名するために使用される公開鍵のコンマ区切りの一覧です。ファイル名にはコンマを含めることはできません。
  • delete: リポジトリーを削除します。

    • repo_id - 削除するリポジトリーを特定します (必須)。

[root@rhua ~]# rhui-manager repo list
ID                             :: Repository Name

Red Hat Repositories
--------------------
rhel-rhui-server-7-rh-gluster-samba-3.1-os-7Server-x86_64 :: RHEL RHUI Server 7 Rh-gluster-samba 3.1 OS (7Server-x86_64)

Custom Repositories
--------------------
my_custom_repo                 :: My Custom Repo

B.4. status

  • (このコマンドにはサブコマンドがありません。)

    • --code - 指定すると、結果の数値コードのみが表示されます。

[root@rhua ~]# rhui-manager status
RHEL RHUI Server 7 Rh-gluster-samba 3.1 OS (7Server-x86_64) ........... Never


Entitlement CA certificate expiration date = 2038-01-18T10:30:32Z  .... [  OK  ]
0

B.5. クライアント

  • rpm: クライアント設定 rpm を作成します。

    • --private_key - エンタイトルメントの秘密鍵を指定します。
    • --entitlement_cert - エンタイトルメント証明書
    • --rpm_version - クライアント設定 rpm のバージョン番号を指定します。
    • --rpm_release - rpm パッケージのリリースデフォルトは 1 です。
    • --rpm_name - クライアント設定 rpm の名前 (必須)
    • --dir - が作成されるディレクトリーです (必須)。
    • --unprotected_repos - 追加する未保護のリポジトリーのコンマ区切りリストです。
    • --cert - 指定した場合は、クライアント設定 rpm を構築する前に証明書も生成します。
    • --repo_label - 追加するリポジトリーを特定します。リポジトリーラベルのコンマ区切り文字列。
    • --name - rpm 名とは異なる証明書名を特定します。
    • --days - 証明書が有効である日数です。
    • --proxy - yum リポジトリーファイルで proxy オプションが必要な場合の url/string
  • labels: クライアント証明書の作成に必要なラベルを一覧表示します。

    • (このサブコマンドにはオプションがありません。)
  • cert: rhui クライアントのコンテンツ証明書を作成します。

    • --repo_label - 追加するリポジトリーを特定します。リポジトリーラベルのコンマ区切り文字列 (必須)
    • --name - 証明書名を特定します (必須)。
    • --days - 証明書が有効である日数です (必須)。
    • --dir - 証明書が保存されるディレクトリーです (必須)。
  • content_source: 代替のソース設定 rpm を作成します。

    • --private_key - エンタイトルメントの秘密鍵を指定します。
    • --entitlement_cert - エンタイトルメント証明書
    • --rpm_version - クライアント設定 rpm のバージョン番号を指定します。
    • --rpm_name - クライアント設定 rpm の名前 (必須)
    • --dir - が作成されるディレクトリーです (必須)。
    • --unprotected_repos - 追加する未保護のリポジトリーのコンマ区切りリストです。
    • --cert - 指定した場合は、クライアント設定 rpm を構築する前に証明書も生成します。
    • --ca_cert - サーバーの認証局への完全パスです。
    • --repo_label - 追加するリポジトリーを特定します。リポジトリーラベルのコンマ区切り文字列。
    • --name - rpm 名とは異なる証明書名を特定します。
    • --days - 証明書が有効である日数です。

# rhui-manager client cert --repo_label rhel-7-server-rhui-rpms,rhel-7-server-rhui-optional-rpms,my_custom_repo --name rhel7 --days 365 --dir /tmp
......+++
.....................................+++
Entitlement certificate created at /tmp/rhel7.crt
注記

ID ではなく、Red Hat リポジトリーラベルを使用します。すべてのラベルの一覧を表示するには、rhui-manager client labels コマンドを実行します。証明書に保護されているカスタムリポジトリーが含まれている場合は、リポジトリーの ID を使用してください。上記の例は、Red Hat リポジトリーラベルとカスタムリポジトリー ID の使用方法を示しています。

バグの報告

付録C Resolve Common Problems in Red Hat Update Infrastructure

以下の表は、Red Hat Update Infrastructure 3.1.8 の既知の問題を示しています。Red Hat Update Infrastructure 3.1.9 で上記の問題が発生した場合は、Bugzilla で問題を報告してください。一般的な問題の詳細は、Troubleshooting Red Hat Update Infrastructure Issuesを参照してください。

表C.1 Red Hat Update Infrastructure の一般的な問題

Category問題解決方法

ISO ダウンロード/Red Hat Update Infrastructure 証明書

RHUI 証明書を使用してカスタマーポータルから Red Hat Update Infrastructure ISO をダウンロードすることができません。

Red Hat Network アカウントに RHUI のエンタイトルメントが設定され、有効になっていることを確認します。

ISO のダウンロードに使用する 証明書の信頼性 を確認します。

証明書が RHUI コンシューマー証明書であることを確認してください。Installation Guide の手順に従って適切な RHUI コンシューマーコンテンツ証明書を作成します。

Red Hat Update Infrastructure 証明書

rhui-manager を使用してエンタイトルメント証明書のアップロード中にエラーメッセージが表示されます。

詳細は、While uploading entitlement certificate on RHUA using "rhui-manager," it fails with "IndexError: list index out of range" を参照してください。

インストール/設定

Red Hat Upate Appliance と CDS の間の通信に問題が発生している。

RHUA および CDS に完全修飾ドメイン名 (FQDN) が設定されており、解決可能であることを確認します。

Bug 726420 – Quick note on proxy URL で説明されているように HTTP プロキシーを適切に設定します。

同期

リポジトリーを Red Hat と同期することができません。

RHUI SKU がアカウントにあることを確認します。

適切なコンテンツ証明書が RHUA に読み込まれていることを確認します。

一時的な CDN の問題を検索します。

環境内の HTTP プロキシーを確認し、While syncing repositories to RHUA, it fails with "RepoError: Cannot retrieve repository metadata (repomd.xml) for repository.Please verify its path and try again" when proxy used エラーが発生しないことを確認してください。

RHUA は、通常、qpid 証明書の有効期限が切れているため、CDS と同期できません。詳細は、CDS sync fails with error "sslv3 alert certificate expired" due to expired qpid CA certificates on RHUI 参照してください。

Red Hat Update Appliance/コンテンツ配信ネットワーク通信

Red Hat Update Appliance がコンテンツ配信ネットワークと通信していません。

/etc/pki/rhui/redhat (.pem ファイル) のコンテンツ証明書を使用して RHUA と CDN との間の接続とアクセスをテストします。

# cd /etc/pki/rhui/redhatwget --certificate=8a85f98146a087b80146afacb3362499.pem --ca-certificate=/etc/rhsm/ca/redhat-uep.pem

link:https://cdn.redhat.com/content/dist/rhel/rhui/server/6/6Server/x86_64/os/repodata/repomd.xml

curl (1) の man ページ: NSS PEM PKCS#11 モジュール (lib-nsspem.so) が利用可能な場合は、PEM ファイルを読み込むことができます。現在のディレクトリーからファイルを使用する場合は、ニックネームとの混同を避けるために先頭に接頭辞 ./ を付けます。

各 CDS では、/etc/pki/pulp/content のエンタイトルメント証明書を使用して、# curl --cert ./rhui-ec2-20120619.pem を使用して RHUA コンテンツの可用性をテストすることができます。

RHUA でホストされるリポジトリーの URL は常に https://fqdn/pulp/repos で始まります。次の方法で残りの URL は除外できます。/var/lib/pulp/repos の下にある RHUA のファイルパスを確認にあること。[2] 1.6 で終わる OID にはパスが含まれるため、openssl コマンドを使用してコンテンツ証明書を直接調べること。

クライアントとコンテンツ配信サーバーの通信

curl を使用して、コンテンツ配信サーバーノードとのクライアント通信を検証することもできます。

# curl --cert /etc/pki/entitlement/product/content.crt --key /etc/pki/entitlement/key.pem https://ip-10-4-58-34.ec2.internal/pulp/repos/content/dist/rhel/rhui/server/6/6Server/x86_64 /rhui/2.1/os/repodata/repomd.xml -k <?xml version="1.0" encoding="UTF-8"?> <repomd xmlns="http://linux.duke.edu/metadata/repo" xmlns:rpm="http://linux.duke.edu/metadata/rpm"> <revision>1339940325</revision> <data type="other_db"> <location href="repodata/4f86b0ae203bba90d22a8363120c66ed6f37da81-other.sqlite.bz2"/> <checksum type="sha">4f86b0ae203bba90d22a8363120c66ed6f37da81</checksum> <timestamp>1339940328.43</timestamp>

コンテンツ配信サーバーの同期

Qpid 証明書の有効期限が切れているため、CDS 同期が SSL エラーで失敗します。

RHUI で qpid CA 証明書の有効期限が切れているため、CD 同期がsslv3 alert certificate expiredエラーにより失敗します。詳細は、Troubleshooting Red Hat Update Infrastructure Issues を参照してください。

クライアント/HAProxy 通信

HAProxy ノードがすべてダウンしています。クライアントが RHUI リポジトリーへのアクセスを失いました。

新規の HAProxy ノードを追加および設定します。何らかの理由でこれを実行できない場合は、DNS 設定を一時的に変更して、主なロードバランサーのホスト名 (本ガイドの cds.example.com) がいずれかの CDS ノードの IP アドレスに解決するようにします。これにより、クライアントは利用できない HAProxy ノードを回避し、CDS と直接通信できます。

バグの報告

付録D Red Hat Update Infrastructure における API リファレンス

注記

ここで引用している資料はすべて、Pulp 2.18 リポジトリー で利用できます。

D.1. リポジトリー API

D.1.1. 作成、削除、および設定

D.1.1.1. リポジトリーの作成

この呼び出しは、Pulp に新しいリポジトリーを作成し、インポーターとディストリビューターの設定用のオプションのパラメーターを受け入れます。これらのパラメーターの詳細な説明は、インポーターまたはディストリビューターを既存のリポジトリーに関連付ける API のドキュメントを参照してください。これらのパラメーターが渡されない場合、呼び出しはパルプにのみリポジトリーを作成します。リポジトリーの実際の機能は、インポーターとディストリビューターが追加されるまで定義されません。リポジトリー ID は、サーバーの全リポジトリーで一意でなければなりません。

方法: POST

パス: /pulp/api/v2/repositories/

パーティション: create

要求ボディーの内容。

id
(文字列) リポジトリーの一意の識別子
display_name
(文字列) (オプション) リポジトリーのわかりやすい名前
description
(文字列) (オプション) リポジトリーのコンテンツを説明するユーザーフレンドリーなテキスト
notes
(オブジェクト) (オプション) リポジトリーにプログラムでタグを付けるためのキーと値のペア
importer_type_id
(文字列) (オプション) リポジトリーに関連付けられているインポーターのタイプ ID
importer_config
(オブジェクト) (オプション) リポジトリーがインポーターの動作を駆動するために使用する設定。proxy_passwordbasic_auth_password は、セキュリティー上の理由から * として返されることに注意してください。
distributors
(配列) (オプション)distributor_type_idrepo_plugin_configauto_publish、および distributor_id の値を含むオブジェクトの配列

レスポンスコード

201
リポジトリーが正常に作成されました。
400
いずれかのパラメーターが無効になっている場合
409
指定した ID のリポジトリーがすでに存在する場合
500
インポータ―またはディストリビューターで初期化中にエラーを発生した場合

戻り値: 作成されたリポジトリーのデータベース表現

要求のサンプル:

{
 "display_name": "Harness Repository: harness_repo_1",
 "id": "harness_repo_1",
 "importer_type_id": "harness_importer",
 "importer_config": {
   "num_units": "5",
   "write_files": "true"
 },
 "distributors": [{
               "distributor_id": "dist_1",
               "distributor_type_id": "harness_distributor",
               "distributor_config": {
               "publish_dir": "/tmp/harness-publish",
               "write_files": "true"
               },
               "auto_publish": false
       }],
}

201 応答の本文のサンプル:

{
 "scratchpad": {},
 "display_name": "Harness Repository: harness_repo_1",
 "description": null,
 "_ns": "repos",
 "notes": {},
 "content_unit_counts": {},
 "_id": {
   "$oid": "52280416e5e71041ad000066"
 },
 "id": "harness_repo_1",
 "_href": "/pulp/api/v2/repositories/harness_repo_1/"
}

D.1.1.2. リポジトリーを更新します。

(関連するインポーター/ディストリビューターと比較して) リポジトリーの作成が単にリポジトリーメタデータに関連しているように、更新リポジトリーの呼び出しは、そのメタデータのみの更新に重点が置かれます。

方法: PUT

Path: /pulp/api/v2/repositories/<repo_id>/

パーティション: update

要求の本文の内容: 要求の本文は、以下の 3 つの可能なルート要素を持つ JSON ドキュメントです。

delta
(オブジェクト) - (任意) リポジトリー上で更新する必要のある値を持つキーを含むオブジェクト
importer_config
(オブジェクト) - (任意) リポジトリーのインポーター設定で更新する必要のある値を含むオブジェクト
distributor_configs
(オブジェクト) - (任意) ディストリビューター ID であるキーを含むオブジェクト、およびプラグイン固有のキー/値のペアを含むオブジェクトの値

レスポンスコード

200
更新が実行され、成功した場合
202
更新は実行されたにも関わらず、ネストされたディストリビューター設定を更新するために追加のタスクが作成された場合
400
いずれかのパラメーターが無効になっている場合
404
指定した ID のあるリポジトリーがない場合

戻り値: (更新による変更後の) リポジトリーのデータベース表現と、リポジトリーのコンシューマーバインディングを適用するために生成されたタスクが含まれる Call Report。生成されるバインディングタスクの詳細は、コンシューマーをリポジトリーにバインド を参照してください。

要求のサンプル:

{
 "delta": {
  "display_name" : "Updated"
 },
 "importer_config": {
  "demo_key": "demo_value"
 },
 "distributor_configs": {
  "demo_distributor": {
    "demo_key": "demo_value"
  }
 }
}

結果値のサンプル: Call Report の結果フィールドに、リポジトリーのデータベース表現が含まれます。

{
...
"result": {
   "display_name": "zoo",
   "description": "foo",
   "_ns": "repos",
   "notes": {
     "_repo-type": "rpm-repo"
   },
   "content_unit_counts": {
     "package_group": 2,
     "package_category": 1,
     "rpm": 32,
     "erratum": 4
   },
   "_id": {
     "$oid": "5328b2983738202945a3bb47"
   },
   "id": "zoo",
   "_href": "/pulp/api/v2/repositories/zoo/"

 },
 ...
}

D.1.1.3. インポータ―をリポジトリーに関連付けます。

この呼び出しは、以前に作成されたパルプリポジトリーの インポーター を設定します。各リポジトリーは、インポーターの設定を維持します。これは、インポーターがコンテンツを同期する際にどのように動作するかを決定するために使用されます。可能な設定値は、追加するインポーターのタイプによって決まります。インポーターの各タイプは、その機能に関係する異なる値のセットをサポートします。

インポーターは、特定のタイミングでリポジトリーに関連付けられるだけです。リポジトリーにすでに関連付けられたインポーターがある場合、以前の関連付けは削除されます。この削除は、新しいインポーターが初期化される前に実行されるため、新しいインポーターの初期化に失敗した場合は、インポーターなしでリポジトリーが残される可能性があります。

インポーターを追加すると、追加を確認する前に以下の検証ステップが実行されます。

  • インポータープラグインと通信し、インポーターの提供された設定を検証するよう要求されます。その設定が無効であることをインポーターが示している場合は、インポーターはリポジトリーに追加されません。
  • インポーターの importer_added メソッドは、そのリポジトリーに必要な初期化をインポータ―が実行できるように呼び出されます。この呼び出し中にプラグインが例外を発生させると、インポーターはリポジトリーに追加されません。
  • Pulp データベースが更新され、インポーターの設定と、リポジトリーがインポーターに関連付けられている知識が保存されます。

追加されたインポーターの詳細が呼び出しから返されます。

方法: POST

Path: /pulp/api/v2/repositories/<repo_id>/importers/

パーティション: create

要求ボディーの内容。

importer_type_id
(文字列) - リポジトリーに関連付けられているインポーターのタイプを示します。この ID のある Pulp サーバーにインポーターがインストールされている必要があります。
importer_config
(オブジェクト) リポジトリーがインポーターの動作を駆動するために使用する設定。

レスポンスコード

202
関連付けを実行するためにキューに追加された場合
400
必要なパラメーターのいずれかが欠落している場合、インポーターのタイプ ID は存在しないインポーターを参照します。また、インポーターは、指定された設定が無効であることを示します。
404
指定した ID があるリポジトリーが存在しない場合
500
初期化中にインポーターがエラーを発生させる場合

戻り値: 関連タスクの現在の状態が含まれる Call Report

要求のサンプル:

{
 "importer_type_id": "harness_importer",
 "importer_config": {
   "num_units": "5",
   "write_files": "true"
 }
}

Task Report の結果値のサンプル: Task Report の結果フィールドには、インポーターのデータベース表現 (完全なリポジトリーの詳細ではなく、インポーターのみ) が含まれます。

{
 "scratchpad": null,
 "_ns": "repo_importers",
 "importer_type_id": "harness_importer",
 "last_sync": null,
 "repo_id": "harness_repo_1",
 "_id": "bab0f9d5-dfd1-45ef-bd1d-fd7ea8077d75",
 "config": {
   "num_units": "5",
   "write_files": "true"
 },
 "id": "harness_importer"
}

タグ: 作成されたタスクには、pulp:action:update_importerpulp:repository:<repo_id>pulp:repository_importer:<importer_type_id> のタグが含まれます。

D.1.1.4. ディストリビューターとリポジトリーの関連付け

この呼び出しは、以前に作成されたパルプリポジトリーの ディストリビューター を設定します。各リポジトリーは、ディストリビューターの設定を維持します。これは、ディストリビューターがコンテンツを公開する際にどのように動作するかを決定するために使用されます。可能な設定値は、追加されるディストリビューターのタイプによって異なります。各ディストリビュータータイプは、その機能に関連するさまざまな値のセットをサポートします。

注記

任意のディストリビューター設定パラメーターがあります。これは force_full と呼ばれるすべてのディストリビュータープラグインタイプで使用できます。このパラメーターを設定すると、このディストリビューターを使用するリポジトリーのすべての公開が最初から実行されます。詳細は、リリースノート を参照してください。

一度に複数のディストリビューターをリポジトリーに関連付けることができます。同じタイプのディストリビューターが複数存在する場合があります。唯一の制限は、ディストリビューション ID が特定のリポジトリーのすべてのディストリビューターで一意である必要があることです。

ディストリビューターを追加すると、追加を確認する前に以下の検証手順が実行されます。

  • これが指定されている場合は、リポジトリーのコンテキストにおける一意性についてディストリビューター ID が確認されます。指定しないと、一意の ID が生成されます。
  • distributor プラグインが接続され、ディストリビューターに指定された設定の検証が求められます。ディストリビューターがその設定が無効であることを示している場合、ディストリビューターはリポジトリーに追加されません。
  • ディストリビューターの distributor_added メソッドは、そのリポジトリーに必要な初期化を行うために呼び出されます。この呼び出し中にプラグインが例外を発生させると、ディストリビューターはリポジトリーに追加されません。
  • Pulp データベースが更新され、ディストリビューターの設定と、リポジトリーがディストリビューターに関連付けられているナレッジが保存されます。

追加されたディストリビューターの詳細が呼び出しから返されます。

方法: POST

Path: /pulp/api/v2/repositories/<repo_id>/distributors/

パーティション: create

要求ボディーの内容。

distributor_type_id
(文字列) リポジトリーに関連付けられているディストリビューターのタイプを示します。この ID のある Pulp サーバーにディストリビューターがインストールされている必要があります。
distributor_config
(オブジェクト) ディストリビューターの動作を駆動するためにリポジトリーが使用するプラグイン固有の設定
distributor_id
(文字列) (オプション) 指定されている場合、この値はディストリビューターを参照します。指定しない場合、1 つはディストリビューターにランダムに割り当てられます。
auto_publish
(ブール値) (オプション) true の場合、このディストリビューターは、リポジトリーの同期が成功した後、自動的に公開操作を呼び出します。指定されていない場合はデフォルトで false に設定されます。

レスポンスコード

201
ディストリビューターが正常に追加された場合
400
必要なパラメーターのいずれかが欠落している場合、ディストリビューターのタイプ ID は存在しないディストリビューターを参照します。また、ディストリビューターは、指定された設定が無効であることを示します。
404
指定した ID があるリポジトリーが存在しない場合
500
ディストリビューターが初期化中にエラーを発生させる場合

戻り値: ディストリビューターのデータベース表現 (完全なリポジトリーの詳細ではなく、ディストリビューターのみ)。

要求のサンプル:

{
 "distributor_id": "dist_1",
 "distributor_type_id": "harness_distributor",
 "distributor_config": {
   "publish_dir": "/tmp/harness-publish",
   "write_files": "true"
 },
 "auto_publish": false
}

201 応答の本文のサンプル:

{
 "scratchpad": null,
 "_ns": "repo_distributors",
 "last_publish": null,
 "auto_publish": false,
 "distributor_type_id": "harness_distributor",
 "repo_id": "harness_repo_1",
 "publish_in_progress": false,
 "_id": "cfdd6ab9-6dbe-4192-bde2-d00db768f268",
 "config": {
   "publish_dir": "/tmp/harness-publish",
   "write_files": "true"
 },
 "id": "dist_1"
}

D.1.1.5. リポジトリーに関連付けられているインポートの更新

リポジトリーに関連付けられている インポーター の設定を更新します。

指定されていないインポーター設定値は変更されません。

インポーターの proxy_password フィールドと basic_auth_password フィールドは、入力されている場合は * として返されることに注意してください。これは、セキュリティーの目的で行われます。

方法: PUT

Path: /pulp/api/v2/repositories/<repo_id>/importers/<importer_id>/

パーティション: update

要求ボディーの内容。

importer_config
(オブジェクト) インポーターで更新する必要のある値を持つキーを含むオブジェクト

レスポンスコード

202
リポジトリーが利用可能の場合に、インポーターを更新するサーバーが要求に要求が受け入れられた場合
400
要求ボディーパラメーターが無効になっている場合
404
指定した ID を持つリポジトリーまたはインポーターがない場合

戻り値: Task Report にポーリングする必要がある生成されたタスクが含まれる Call Report

要求のサンプル:

{
 "importer_config": {
   "demo_key": "demo_value"
 }
}

Task Report の結果値のサンプル: Task Report の結果フィールドには、インポーターのデータベース表現が含まれます。これには、完全なリポジトリー情報が含まれません。

[options="nowrap"]
{
  "scratchpad": null,
  "_ns": "repo_importers",
  "importer_type_id": "demo_importer",
  "last_sync": "2013-10-03T14:08:35Z",
  "scheduled_syncs": [],
  "repo_id": "demo_repo",
  "_id": {
    "$oid": "524db282dd01fb194283e53f"
  },
  "config": {
    "demo_key": "demo_value"
  },
  "id": "demo_importer"
}

タグ: 作成されたタスクには、pulp:action:update_importerpulp:repository:<repo_id>pulp:repository_importer:<importer_id> のタグが含まれます。

D.1.1.6. リポジトリーからのインポーターの関連付けを解除します。

方法: DELETE

Path: /pulp/api/v2/repositories/<repo_id>/importers/<importer_id>/

パーティション: delete

レスポンスコード

202
リポジトリーが利用可能である場合は、関連付けを解除をするサーバーに要求に要求が受け入れられた場合
404
指定した ID を持つリポジトリーまたはインポーターがない場合

戻り値: Call Report

タグ: 作成されたタスクには、pulp:action:delete_importerpulp:repository:<repo_id>pulp:repository_importer:<importer_id> のタグが含まれます。

D.1.1.7. リポジトリーに関連付けられているディストリビューターの更新

リポジトリーに関連付けられているディストリビューターの設定を更新します。これにより、以下のアクションが実行されます。

  1. サーバーのディストリビューターを更新します。
  2. バインドされたコンシューマーを再バインドします。

指定されていないディストリビューターの設定値は変更されず、明示的に None に設定されている値は設定から削除されます。

最初のステップは、Call Report に示されます。ステップ 1 が完了すると、spawned_tasks フィールドに、ステップ 2 を完了するために必要なタスクへのリンクが表示されます。ディストリビューターを更新すると、そのリポジトリーに関連する各バインディングも更新されます。詳細は、コンシューマーのリポジトリーへのバインド を参照してください。

方法: PUT

Path: /pulp/api/v2/repositories/<repo_id>/distributors/<distributor_id>/

パーティション: update

要求ボディーの内容。

distributor_config
(オブジェクト) (オプション) ディストリビューター設定を更新する値を持つプラグイン固有のキーを含むオブジェクト
delta
(オブジェクト) (オプション) ディストリビューターオブジェクトを更新する値を持つキーを含むオブジェクト。現在、auto_publish のみをサポートしています。

レスポンスコード

202
リポジトリーが利用可能の場合に、ディストリビューターを更新するサーバーにリクエストが許可された場合
404
指定した ID を持つリポジトリーやディストリビューターがない場合

戻り値: Call Report

要求のサンプル:

{
 "distributor_config": {
   "demo_key": "demo_value"
 },
 "delta": {
   "auto_publish": true
 }
}

タグ: ディストリビューターを更新するために作成されるタスクには、pulp:action:update_distributorpulp:repository:<repo_id>、および pulp:repository_distributor:<distributor_id> のタグが含まれます。バインディングタスクに関する情報は、Bind a Consumer to a Repository を参照してください。

D.1.1.8. リポジトリーからのディストリビューターの関連付けを解除

ディストリビューターの関連付けを解除すると、以下のアクションが実行します。

  1. ディストリビューターとリポジトリー間の関連付けを削除します。
  2. バインドされているすべてのコンシューマーのバインドを解除します。

最初のステップは、Call Report に示されます。ステップ 1 が完了すると、spawned_tasks フィールドに、ステップ 2 を完了するために必要なタスクへのリンクが表示されます。生成されたタスクの合計数は、リポジトリーにバインドされるコンシューマーの数によって異なります。

方法: DELETE

Path: /pulp/api/v2/repositories/<repo_id>/distributors/<distributor_id>/

パーティション: delete

レスポンスコード

202
リポジトリーが利用可能である場合は、関連付けを解除をするサーバーに要求に要求が受け入れられた場合
404
指定した ID を持つリポジトリーやディストリビューターがない場合
500
サーバーが関連付け解除時にエラーを発生させる場合

戻り値: Call Report

タグ: ディストリビューターを削除するために作成されるタスクには、pulp:action:remove_distributorpulp:repository:<repo_id>、および pulp:repository_distributor:<distributor_id> のタグが含まれます。

D.1.1.9. リポジトリーを削除します。

リポジトリーが削除されると、データベースから削除され、ローカルの作業ディレクトリーが削除されます。リポジトリー内のコンテンツは削除されません。コンテンツの削除は、孤立したユニット プロセスで処理されます。

リポジトリーの削除は、主に以下の手順で行います。

  • リポジトリーを削除します。
  • バインドされているすべてのコンシューマーのバインドを解除します。

最初のステップは、Call Report に示されます。ステップ 1 が完了すると、spawned_tasks フィールドに、ステップ 2 を完了するために必要なタスクへのリンクが表示されます。生成されたタスクの合計数は、リポジトリーにバインドされるコンシューマーの数によって異なります。

方法: DELETE

Path: /pulp/api/v2/repositories/<repo_id>/

パーティション: delete

レスポンスコード

202
サーバーがリポジトリーを削除するために要求を受け入れた場合
404
要求されたリポジトリーが存在しない場合

戻り値: Call Report

タグ: リポジトリーを削除するために作成されるタスクには、pulp:action:deletepulp:repository:<repo_id> のタグが含まれます。

D.1.2. 取得

D.1.2.1. 単一リポジトリーの取得

この呼び出しは、単一のパルプリポジトリーに関する情報を取得します。返されるデータには、一般的なリポジトリーメタデータ、リポジトリーに関連付けられているインポーターとディストリビューターを記述するメタデータ、リポジトリーに対してローカルに保存されているコンテンツユニットの数が含まれます。

方法: GET

Path: /pulp/api/v2/repositories/<repo_id>/

パーティション: read

クエリーパラメーター

details
(ブール値) (任意) ディストリビューター、インポーター、およびコンテンツユニット数を含むショートカット
importers
(ブール値) (任意) 各リポジトリーの importers 属性が含まれます。
distributors
(ブール値) (オプション) 各リポジトリーに distributors 属性を含めます

レスポンスコード

200
リポジトリーが存在する場合
404
指定 ID を持つリポジトリーが存在しない場合

戻り値: 一致するリポジトリーのデータベース表現

200 応答の本文のサンプル:

{
 "display_name": "Harness Repository: harness_repo_1",
 "description": null,
 "distributors": [
   {
     "scratchpad": 1,
     "_ns": "repo_distributors",
     "last_publish": "2012-01-25T15:26:32Z",
     "auto_publish": false,
     "distributor_type_id": "harness_distributor",
     "repo_id": "harness_repo_1",
     "publish_in_progress": false,
     "_id": "addf9261-345e-4ce3-ad1e-436ba005287f",
     "config": {
       "publish_dir": "/tmp/harness-publish",
       "write_files": "true"
     },
     "id": "dist_1"
   }
 ],
 "notes": {},
 "scratchpad": {},
 "content_unit_counts": {},
 "last_unit_added": "2012-01-25T15:26:32Z",
 "last_unit_removed": "2012-01-25T15:26:32Z",
 "importers": [
   {
     "scratchpad": 1,
     "_ns": "repo_importers",
     "importer_type_id": "harness_importer",
     "last_sync": "2012-01-25T15:26:32Z",
     "repo_id": "harness_repo_1",
     "sync_in_progress": false,
     "_id": "bbe81308-ef7c-4c0c-b684-385fd627d99e",
     "config": {
       "num_units": "5",
       "write_files": "true"
     },
     "id": "harness_importer"
   }
 ],
 "id": "harness_repo_1",
 "total_repository_units": 5,
 "locally_stored_units": 3
}

D.1.2.2. すべてのリポジトリーの取得

この呼び出しは、パルプサーバー内のすべてのリポジトリーに関する情報を返します。この呼び出しが 404 を返すことは決してないことに注意してください。リポジトリーがない場合は、空の配列が返されます。

方法: GET

パス: /pulp/api/v2/repositories/

パーティション: read

クエリーパラメーター

details
(ブール値) - (任意) ディストリビューターとインポーターの両方を含むショートカット
importers
(ブール値) (オプション) 各リポジトリーに importers 属性を含めます
distributors
(ブール値) (オプション) 各リポジトリーに distributors 属性を含めます

レスポンスコード

200
リポジトリーの配列が含まれます。

戻り値: 単一リポジトリーの取得と同じ形式です。ただし、戻り値のベースは、それらの配列です。

200 応答の本文のサンプル:

[
 {
   "display_name": "Harness Repository: harness_repo_1",
   "description": null,
   "last_unit_added": "2012-01-25T15:26:32Z",
   "last_unit_removed": null,
   "distributors": [
     {
       "scratchpad": 1,
       "_ns": "repo_distributors",
       "last_publish": "2012-01-25T15:26:32Z",
       "auto_publish": false,
       "distributor_type_id": "harness_distributor",
       "repo_id": "harness_repo_1",
       "publish_in_progress": false,
       "_id": "addf9261-345e-4ce3-ad1e-436ba005287f",
       "config": {
         "publish_dir": "/tmp/harness-publish",
         "write_files": "true"
       },
       "id": "dist_1"
     }
   ],
   "notes": {},
   "scratchpad": {},
   "content_unit_counts": {},
   "importers": [
     {
       "scratchpad": 1,
       "_ns": "repo_importers",
       "importer_type_id": "harness_importer",
       "last_sync": "2012-01-25T15:26:32Z",
       "repo_id": "harness_repo_1",
       "sync_in_progress": false,
       "_id": "bbe81308-ef7c-4c0c-b684-385fd627d99e",
       "config": {
         "num_units": "5",
         "write_files": "true"
       },
       "id": "harness_importer"
     }
   ],
   "id": "harness_repo_1"
 }
]

D.1.2.3. リポジトリーの高度な検索

これらの検索の実行方法は、検索 API を参照してください。

この呼び出しは、検索パラメーターに一致するパルプサーバー内のリポジトリーに関する情報を返します。この呼び出しが 404 を返すことは決してないことに注意してください。リポジトリーがない場合は、空の配列が返されます。

方法: POST

パス: /pulp/api/v2/repositories/search/

パーティション: read

要求ボディーの内容。

details
(ブール値) (オプション) インポートとディストリビューターを含むショートカット
importers
(ブール値) (オプション) 各リポジトリーに importers 属性を含めます
distributors
(ブール値) (オプション) 各リポジトリーに distributors 属性を含めます

レスポンスコード

200
リポジトリーの配列が含まれます。

戻り値: 単一リポジトリーの取得と同じ形式です。ただし、戻り値のベースは、それらの配列です。

200 応答の本文のサンプル:

[
 {
   "display_name": "Harness Repository: harness_repo_1",
   "description": null,
   "distributors": [
     {
       "scratchpad": 1,
       "_ns": "repo_distributors",
       "last_publish": "2012-01-25T15:26:32Z",
       "auto_publish": false,
       "distributor_type_id": "harness_distributor",
       "repo_id": "harness_repo_1",
       "publish_in_progress": false,
       "_id": "addf9261-345e-4ce3-ad1e-436ba005287f",
       "config": {
         "publish_dir": "/tmp/harness-publish",
         "write_files": "true"
       },
       "id": "dist_1"
     }
   ],
   "notes": {},
   "scratchpad": {},
   "content_unit_counts": {},
   "last_unit_added": null,
   "last_unit_removed": null,
   "importers": [
     {
       "scratchpad": 1,
       "_ns": "repo_importers",
       "importer_type_id": "harness_importer",
       "last_sync": "2012-01-25T15:26:32Z",
       "repo_id": "harness_repo_1",
       "sync_in_progress": false,
       "_id": "bbe81308-ef7c-4c0c-b684-385fd627d99e",
       "config": {
         "num_units": "5",
         "write_files": "true"
       },
       "id": "harness_importer"
     }
   ],
   "id": "harness_repo_1"
 }
]

この呼び出しは、検索パラメーターに一致するパルプサーバー内のリポジトリーに関する情報を返します。この呼び出しが 404 を返すことは決してないことに注意してください。リポジトリーがない場合は、空の配列が返されます。

一部のフィルター式はクエリーパラメーターとしてシリアル化できない場合があるため、この方法は POST の代替方法よりも制限があります。

方法: GET

パス: /pulp/api/v2/repositories/search/

パーティション: read

クエリーパラメーター

details
(ブール値) - (任意) ディストリビューターとインポーターの両方を含むショートカット
importers
(ブール値) (任意) 各リポジトリーの importers 属性が含まれます。
distributors
(ブール値) (オプション) 各リポジトリーに distributors 属性を含めます

クエリーパラメーターは、Search Criteria で定義されている Criteria オブジェクトの属性と一致する必要があります。例外は fields パラメーターで、これは単数形で指定する必要があります。例: /v2/repository/search/?field = id&field = display_name&limit =20'

レスポンスコード

200
リポジトリーの配列を獲得する

戻り値: 単一リポジトリーの取得と同じ形式です。ただし、戻り値のベースは、それらの配列です。

200 応答の本文のサンプル:

[
 {
   "display_name": "Harness Repository: harness_repo_1",
   "description": null,
   "distributors": [
     {
       "scratchpad": 1,
       "_ns": "repo_distributors",
       "last_publish": "2012-01-25T15:26:32Z",
       "auto_publish": false,
       "distributor_type_id": "harness_distributor",
       "repo_id": "harness_repo_1",
       "publish_in_progress": false,
       "_id": "addf9261-345e-4ce3-ad1e-436ba005287f",
       "config": {
         "publish_dir": "/tmp/harness-publish",
         "write_files": "true"
       },
       "id": "dist_1"
     }
   ],
   "notes": {},
   "scratchpad": {},
   "content_unit_counts": {},
   "last_unit_added": null,
   "last_unit_removed": null,
   "importers": [
     {
       "scratchpad": 1,
       "_ns": "repo_importers",
       "importer_type_id": "harness_importer",
       "last_sync": "2012-01-25T15:26:32Z",
       "repo_id": "harness_repo_1",
       "sync_in_progress": false,
       "_id": "bbe81308-ef7c-4c0c-b684-385fd627d99e",
       "config": {
         "num_units": "5",
         "write_files": "true"
       },
       "id": "harness_importer"
     }
   ],
   "id": "harness_repo_1"
 }
]

D.1.2.4. リポジトリーに関連付けられているインポートの取得

この呼び出しは、リポジトリーに関連付けられている インポーター (存在する場合) を取得します。配列は空 (インポーターが設定されていない) になるか、単一のエントリーが含まれます。

方法: GET

Path: /pulp/api/v2/repositories/<repo_id>/importers/

パーティション: read

クエリーパラメーター: なし

レスポンスコード

200
インポーターの配列が含まれます。
404
指定した ID のリポジトリーがない場合は、リポジトリーが存在していても関連するインポーターがない場合には、これは発生しません。

戻り値: リポジトリーのインポーターまたは空の一覧のデータベース表現。

200 応答の本文のサンプル:

[
   {
       "_href": "/pulp/api/v2/repositories/zoo/importers/yum_importer/",
       "_id": {
           "$oid": "563c82fa45ef48043f026c32"
       },
       "_ns": "repo_importers",
       "config": {
           "feed": "http://example.com/repos/zoo/"
       },
       "id": "yum_importer",
       "importer_type_id": "yum_importer",
       "last_sync": "2015-11-06T10:38:23Z",
       "repo_id": "zoo",
       "scratchpad": {
           "repomd_revision": 1331832478
       }
   }
]

D.1.2.5. リポジトリーに関連付けられているインポータ―の取得

この呼び出しは、リポジトリーに関連付けられている特定の インポーター (存在する場合) を取得します。

方法: GET

Path: /pulp/api/v2/repositories/<repo_id>/importers/<importer_id>/

パーティション: read

クエリーパラメーター: なし

レスポンスコード

200
インポーターの詳細が含まれます。
404
一致する ID のリポジトリーまたはインポーターがない場合

戻り値: リポジトリーのインポーターのデータベース表現

200 応答の本文のサンプル:

{
   "_href": "/pulp/api/v2/repositories/zoo/importers/yum_importer/",
   "_id": {
       "$oid": "563c82fa45ef48043f026c32"
   },
   "_ns": "repo_importers",
   "config": {
       "feed": "http://example.com/repos/zoo/"
   },
   "id": "yum_importer",
   "importer_type_id": "yum_importer",
   "last_sync": "2015-11-06T10:38:23Z",
   "repo_id": "zoo",
   "scratchpad": {
       "repomd_revision": 1331832478
   }
}

D.1.2.6. リポジトリーに関連付けられているディストリビューターの取得

この呼び出しは、リポジトリーに関連付けられているすべての ディストリビューター を取得します。リポジトリーに関連するディストリビューターがない場合は、空の配列が返されます。

方法: GET

Path: /pulp/api/v2/repositories/<repo_id>/distributors/

パーティション: read

クエリーパラメーター: なし

レスポンスコード

200
ディストリビューターの配列が含まれます。
404
指定した ID のリポジトリーがない場合は、リポジトリーが存在していても関連するディストリビューターがない場合には、これは発生しません。

戻り値: リポジトリー上のすべてのディストリビューターのデータベース表現

200 応答の本文のサンプル:

[
 {
   "scratchpad": 1,
   "_ns": "repo_distributors",
   "last_publish": "2012-01-25T15:26:32Z",
   "auto_publish": false,
   "distributor_type_id": "harness_distributor",
   "repo_id": "harness_repo_1",
   "publish_in_progress": false,
   "_id": "addf9261-345e-4ce3-ad1e-436ba005287f",
   "config": {
     "publish_dir": "/tmp/harness-publish",
     "write_files": "true"
   },
   "id": "dist_1"
 }
]

D.1.2.7. リポジトリーに関連付けられているディストリビューターの取得

この呼び出しは、リポジトリーに関連付けられた単一の ディストリビューター を取得します。

方法: GET

Path: /pulp/api/v2/repositories/<repo_id>/distributors/<distributor_id>/

パーティション: read

クエリーパラメーター: なし

レスポンスコード

200
ディストリビューターの詳細が含まれます。
404
リポジトリーがない場合や、一致する ID を持つディストリビューターがない場合

戻り値: ディストリビューターのデータベース表現

200 応答の本文のサンプル:

{
  "scratchpad": 1,
  "_ns": "repo_distributors",
  "last_publish": "2012-01-25T15:26:32Z",
  "auto_publish": false,
  "distributor_type_id": "harness_distributor",
  "repo_id": "harness_repo_1",
  "publish_in_progress": false,
  "_id": {"$oid": "addf9261-345e-4ce3-ad1e-436ba005287f"},
  "config": {
    "publish_dir": "/tmp/harness-publish",
    "write_files": "true"
  },
  "id": "dist_1"
}

D.1.2.8. ディストリビューターの高度な検索

これらの検索の実行方法は、検索 API を参照してください。

この呼び出しは、検索パラメーターに一致するパルプサーバーのディストリビューターに関する情報を返します。この呼び出しが 404 を返すことは決してないことに注意してください。ディストリビューターがない場合は、空の配列が返されます。

方法: POST

パス: /pulp/api/v2/distributors/search/

パーティション: read

要求ボディーの内容: なし

レスポンスコード

200
ディストリビューターの配列が含まれます。

戻り値: ディストリビューターオブジェクトの一覧

200 応答の本文のサンプル:

[
  {
    "repo_id": "el7",
    "last_publish": "2015-04-28T18:19:01Z",
    "auto_publish": null,
    "scheduled_publishes": [],
    "distributor_type_id": "ostree_web_distributor",
    "scratchpad": null,
    "config": {
      "relative_path": "/opt/content/ostree/el7"
    },
    "id": "ostree_web_distributor_name_cli"
  },
  {
    "repo_id": "el6",
    "last_publish": "2015-5-28T18:18:01Z",
    "auto_publish": null,
    "scheduled_publishes": [],
    "distributor_type_id": "ostree_web_distributor",
    "scratchpad": null,
    "config": {
      "relative_path": "/opt/content/ostree/el6"
    },
    "id": "ostree_web_distributor_name_cli"
  }
]

D.1.3. 同期

D.1.3.1. リポジトリーを同期します。

この呼び出しは、リポジトリーの インポーター を使用して、フィードソースからリポジトリーにコンテンツを同期します。

方法: POST

Path: /pulp/api/v2/repositories/<repo_id>/actions/sync/

パーティション: execute

要求ボディーの内容。

override_config
(オブジェクト) (オプション) この同期のインポーターのデフォルト設定をオーバーライドするインポーター設定値

レスポンスコード

202
同期が実行するように設定されている場合
404
リポジトリーが存在しない場合

戻り値: Call Report

要求のサンプル:

{
  "override_config": {"verify_checksum": false,
                      "verify_size": false},
}

タグ: 作成されたタスクには、pulp:action:syncpulp:repository:<repo_id> のタグが含まれます。

D.1.3.2. リポジトリーのダウンロード

同期時に遅延したリポジトリーにコンテンツをダウンロードします。これは、download_policy=(background | on_demand) で設定されたインポーターを含むリポジトリーで役に立ちます。ダウンロード済みのコンテンツは再度ダウンロードされません。

注記

この API では、Alternate Download Policies 機能がインストールされ、機能するように設定されている必要があります。設定されていない場合は、この API によってディスパッチされるタスクは何もしません。

方法: POST

パス: /pulp/api/v2/repositories/<repo_id>/actions/download/

パーティション: execute

要求ボディーの内容。

verify_all_units
(ブール値) (オプション) リポジトリー内のすべてのユニットに破損または欠落しているファイルがないか確認し、欠落していることがわかっているファイルをダウンロードするだけでなく、必要に応じてファイルをダウンロードします (デフォルトは false)

レスポンスコード

202
ダウンロードが実行するように設定されている場合
404
リポジトリーが存在しない場合

戻り値: Call Report

要求のサンプル:

{
  "verify_all_units": false
}

タグ: 作成されたタスクには、pulp:action:download_repopulp:repository:<repo_id> のタグが含まれます。

D.1.3.3. 同期のスケジュール設定

リポジトリーは、iso8601 の間隔 を使用して自動的に同期できます。スケジュールされた同期を作成するには、間隔、同期オーバーライド設定、およびその他のスケジュールオプションをリポジトリーの インポーター に設定する必要があります。

方法: POST

Path: /pulp/api/v2/repositories/<repo_id>/importers/<importer_id>/schedules/sync/

パーティション: create

要求ボディーの内容。

スケジュール
(文字列) iso8601 間隔としてのスケジュール
override_config
(オブジェクト) (任意) スケジュールが設定された同期で使用されるインポーターの上書き設定

failure_threshold (数値) (任意) スケジュールが設定されたこの同期が無効になる前に連続して失敗が可能な回数

enabled
(ブール値) (任意) スケジュールが設定された同期が最初に有効かどうか (デフォルトは true)

レスポンスコード

201
スケジュールが正常に作成された場合
400
いずれかのパラメーターが無効になっている場合
404
指定した ID を持つリポジトリーまたはインポーターがない場合

戻り値: スケジュールを設定した呼び出しの現在の状態を表すスケジュールレポート

要求のサンプル:

{
 "override_config": {},
 "schedule": "00:00:00Z/P1DT",
 "failure_threshold": 3,
}

201 応答の本文のサンプル:

{
 "next_run": "2014-01-27T21:41:50Z",
 "task": "pulp.server.tasks.repository.sync_with_auto_publish",
 "last_updated": 1390858910.292712,
 "first_run": "2014-01-27T21:41:50Z",
 "schedule": "PT1H",
 "args": [
   "demo"
 ],
 "enabled": true,
 "last_run_at": null,
 "_id": "52e6d29edd01fb70bd0d9c37",
 "total_run_count": 0,
 "failure_threshold": 3,
 "kwargs": {
   "overrides": {}
 },
 "resource": "pulp:importer:demo:puppet_importer",
 "remaining_runs": null,
 "consecutive_failures": 0,
 "_href": "/pulp/api/v2/repositories/demo/importers/puppet_importer/schedules/sync/52e6d29edd01fb70bd0d9c37/"
}

D.1.3.4. スケジュールが設定された同期の更新

スケジュールされた同期の作成に使用されるパラメーターはいつでも更新できます。

方法: PUT

パス: /pulp/api/v2/repositories/<repo_id>/importers/<importer_id>/schedules/sync/<schedule_id>/

パーティション: create

要求ボディーの内容。

スケジュール
(文字列) (オプション) iso8601 間隔としての新しいスケジュール
override_config
(オブジェクト) (任意) スケジュールが設定された同期で使用されるインポーターの新しい上書き設定

failure_threshold (数値) (任意) スケジュールが設定されたこの同期が無効になる前に新たに連続して失敗が可能な回数

enabled
(ブール値) (任意) スケジュールされた同期が有効かどうか

レスポンスコード

200
スケジュールが正常に更新された場合
400
いずれかのパラメーターが無効になっている場合
404
リポジトリーがない場合は、指定された ID でインポートまたはスケジュールします。

戻り値: スケジュールが設定された呼び出しの現在の状態を表すスケジュールレポート (詳細は、同期のスケジュール設定の応答例を参照してください)。

D.1.3.5. スケジュールが設定された同期の削除

スケジュールが設定された同期を削除して、インポータ―から永続的に削除します。

方法: DELETE

パス: /pulp/api/v2/repositories/<repo_id>/importers/<importer_id>/schedules/sync/<schedule_id>/

パーティション: delete

レスポンスコード

200
スケジュールが正常に削除された場合
404
リポジトリーがない場合は、指定された ID でインポートまたはスケジュールします。

戻り値: null

D.1.3.6. スケジュールされた同期の一覧表示

指定のインポーターに対してスケジュールが設定された同期がすべて表示されます。

方法: GET

Path: /pulp/api/v2/repositories/<repo_id>/importers/<importer_id>/schedules/sync/

パーティション: read

レスポンスコード

200
リポジトリーの場合は、importer が存在します。
404
指定した ID を持つリポジトリーまたはインポーターがない場合

戻り値: スケジュールが設定されたすべての同期のスケジュールレポートの配列

200 応答の本文のサンプル:

[
   {
       "_href": "/pulp/api/v2/repositories/test/importers/yum_importer/schedules/sync/54d8852245ef4876fade7cc2/",
       "_id": "54d8852245ef4876fade7cc2",
       "args": [
           "test"
       ],
       "consecutive_failures": 0,
       "enabled": true,
       "failure_threshold": null,
       "first_run": "2015-02-09T10:00:02Z",
       "kwargs": {
           "overrides": {}
       },
       "last_run_at": "2015-02-09T10:00:23Z",
       "last_updated": 1423476133.825821,
       "next_run": "2015-02-10T10:00:02Z",
       "remaining_runs": null,
       "resource": "pulp:importer:test:yum_importer",
       "schedule": "P1DT",
       "task": "pulp.server.tasks.repository.sync_with_auto_publish",
       "total_run_count": 1
   }
]

D.1.3.7. スケジュールされた単一同期の一覧表示

スケジュールが設定された各同期は検査できます。

方法: GET

パーティション: read

パス: /pulp/api/v2/repositories/<repo_id>/importers/<importer_id>/schedules/sync/<schedule_id>/

レスポンスコード

200
リポジトリー、インポーター、スケジュールが存在する場合
404
リポジトリーがない場合は、指定された ID でインポートまたはスケジュールします。

戻り値: スケジュールが設定された同期のスケジュールレポート

200 応答の本文のサンプル:

{
   "_href": "/pulp/api/v2/repositories/test/importers/yum_importer/schedules/sync/54d8852245ef4876fade7cc2/",
   "_id": "54d8852245ef4876fade7cc2",
   "args": [
       "test"
   ],
   "consecutive_failures": 0,
   "enabled": true,
   "failure_threshold": null,
   "first_run": "2015-02-09T10:00:02Z",
   "kwargs": {
       "overrides": {}
   },
   "last_run_at": "2015-02-09T10:00:23Z",
   "last_updated": 1423476133.825821,
   "next_run": "2015-02-10T10:00:02Z",
   "remaining_runs": null,
   "resource": "pulp:importer:test:yum_importer",
   "schedule": "P1DT",
   "task": "pulp.server.tasks.repository.sync_with_auto_publish",
   "total_run_count": 1
}

D.1.3.8. 同期履歴の取得

この呼び出しは、リポジトリーの同期履歴を取得します。リポジトリーで実行される各同期は履歴エントリーを作成します。

方法: GET

パーティション: read

パス: /pulp/api/v2/repositories/<repo_id>/history/sync/

クエリーパラメーター

limit
(整数) (オプション) 返す履歴エントリーの最大数です。指定されないと、履歴全体が返されます。
sort
(文字列) (任意) オプションは ascending および descending です。配列は同期のタイムスタンプでソートされます。
start_date
(iso8601 日時) (任意) 指定の日付より前のタイムスタンプのエントリーは返されません。
end_date
(iso8601 datetime) (オプション) 指定された日付より後のタイムスタンプを持つエントリーは返されません

レスポンスコード

200
履歴が正常に取得された場合
404
指定したリポジトリー ID が存在しない場合

戻り値: 同期履歴エントリーの配列

200 応答の本文のサンプル:

[
 {
  "result": "success",
  "importer_id": "my_demo_importer",
  "exception": null,
  "repo_id": "demo_repo",
  "traceback": null,
  "started": "1970:00:00T00:00:00Z",
  "completed": "1970:00:00T00:00:01Z",
  "importer_type_id": "demo_importer",
  "error_message": null,
 }
]

D.1.4. 公開

D.1.4.1. リポジトリーの公開

この呼び出しは、リポジトリーの ディストリビュータ を使用してリポジトリーからコンテンツを公開します。この呼び出しは常に非同期で実行され、呼び出しレポート を返します。

方法: POST

パス: /pulp/api/v2/repositories/<repo_id>/actions/publish/

パーティション: execute

要求ボディーの内容。

id
(文字列) 公開するリポジトリーのディストリビューターを指定します。
override_config
(オブジェクト) (任意) ディストリビューターの設定値 (この公開のディストリビューターのデフォルト設定を上書きします)

レスポンスコード

202
公開が実行するように設定されている場合
404
リポジトリーが存在しない場合

戻り値: 同期の現在の状態を表す Call Report

要求のサンプル:

{
  "id": "distributor_1",
  "override_config": {},
}

タグ: 作成されたタスクには、pulp:action:publishpulp:repository:<repo_id> のタグが含まれます。

D.1.4.2. 公開のスケジュール設定

リポジトリーは、iso8601 の間隔 を使用して自動的に公開できます。スケジュールが設定された公開、間隔、公開のオーバーライド設定、およびその他のスケジュールオプションをリポジトリーの ディストリビューター に設定する必要があります。

方法: POST

パス: /pulp/api/v2/repositories/<repo_id>/distributors/<distributor_id>/schedules/publish/

パーティション: create

要求ボディーの内容。

スケジュール
(文字列) iso8601 間隔としてのスケジュール
override_config
(オブジェクト) (任意) スケジュールが設定された公開で使用されるディストリビューターの上書き設定
failure_threshold
(番号) (オプション) このスケジュールされた公開が無効になる前に許可される連続した失敗
enabled
(ブール値) (オプション) スケジュールされた公開が最初に有効になっているかどうか (デフォルトは true)

レスポンスコード

201
スケジュールが正常に作成された場合
400
いずれかのパラメーターが無効になっている場合
404
指定した ID を持つリポジトリーやディストリビューターがない場合

戻り値: スケジュールを設定した呼び出しの現在の状態を表すスケジュールレポート

要求のサンプル:

{
 "override_config": {},
 "schedule": "PT1H",
 "failure_threshold": 3,
}

201 応答の本文のサンプル:

{
 "next_run": "2014-01-27T21:27:56Z",
 "task": "pulp.server.tasks.repository.publish",
 "last_updated": 1390858076.682694,
 "first_run": "2014-01-27T21:27:56Z",
 "schedule": "PT1H",
 "args": [
   "demo",
   "puppet_distributor"
 ],
 "enabled": true,
 "last_run_at": null,
 "_id": "52e6cf5cdd01fb70bd0d9c34",
 "total_run_count": 0,
 "failure_threshold": 3,
 "kwargs": {
   "overrides": {}
 },
 "resource": "pulp:distributor:demo:puppet_distributor",
 "remaining_runs": null,
 "consecutive_failures": 0,
 "_href": "/pulp/api/v2/repositories/demo/distributors/puppet_distributor/schedules/publish/52e6cf5cdd01fb70bd0d9c34/"
}

D.1.4.3. スケジュールが設定された公開の更新

スケジュール済みパブリッシュの作成に使用されるパラメーターはいつでも更新される可能性があります。

方法: PUT

パス: /pulp/api/v2/repositories/<repo_id>/distributors/<distributor_id>/schedules/publish/<schedule_id>/

パーティション: create

要求ボディーの内容。

スケジュール
(文字列) (オプション) iso8601 間隔としての新しいスケジュール
override_config
(オブジェクト) (任意) スケジュールが設定された同期で使用されるインポーターの新しい上書き設定
failure_threshold
(番号) (オプション) このスケジュールされた同期が無効になる前に許可される新しい連続した失敗
enabled
(ブール値) (任意) スケジュールされた同期が有効かどうか

レスポンスコード

200
スケジュールが正常に更新された場合

400: いずれかのパラメーターが無効になっている場合

404: リポジトリーがない場合は、指定した ID で配布またはスケジュールします。

戻り値: スケジュールが設定された呼び出しの現在の状態を表すスケジュールレポート (詳細は、公開のスケジュール設定の応答例を参照してください)。

D.1.4.4. スケジュールが設定された公開の削除

スケジュールが設定された公開を削除して、ディストリビューターから永続的に削除します。

方法: DELETE

パス: /pulp/api/v2/repositories/<repo_id>/distributors/<distributor_id>/schedules/publish/<schedule_id>/

パーティション: delete

レスポンスコード

200
スケジュールが正常に削除された場合
404
リポジトリーがない場合は、指定した ID で配布またはスケジュールします。

戻り値: null

D.1.4.5. スケジュールされたすべての公開の一覧表示

指定のディストリビューターに対してスケジュールが設定された公開がすべて表示されます。

方法: GET

パス: /pulp/api/v2/repositories/<repo_id>/distributors/<distributor_id>/schedules/publish/

パーティション: read

レスポンスコード

200
リポジトリーがある場合は、ディストリビューターが存在します
404
指定された ID を持つリポジトリーまたはディストリビューターがない場合

戻り値: スケジュールが設定されたすべての公開のスケジュールレポートの配列です (詳細は、公開のスケジュール設定の応答例を参照してください)。

200 応答の本文のサンプル:

{
    "_href": "/pulp/api/v2/repositories/test/distributors/yum_distributor/schedules/publish/54d88df045ef4876fb50c994/",
    "_id": "54d88df045ef4876fb50c994",
    "args": [
        "test",
        "yum_distributor"
    ],
    "consecutive_failures": 0,
    "enabled": true,
    "failure_threshold": null,
    "first_run": "2015-02-09T10:37:36Z",
    "kwargs": {
        "overrides": {}
    },
    "last_run_at": "2015-02-09T10:38:23Z",
    "last_updated": 1423478256.805917,
    "next_run": "2015-02-10T10:37:36Z",
    "remaining_runs": null,
    "resource": "pulp:distributor:test:yum_distributor",
    "schedule": "P1DT",
    "task": "pulp.server.tasks.repository.publish",
    "total_run_count": 1
}

D.1.4.6. スケジュールが設定された単一公開の一覧表示

スケジュールが設定された各公開は検査できます。

方法: GET

パーティション: read

パス: /pulp/api/v2/repositories/<repo_id>/distributors/<distributor_id>/schedules/publish/<schedule_id>/

レスポンスコード:

200
リポジトリーがある場合は、ディストリビューターまたはスケジュールが存在します
404
指定された ID のリポジトリー、ディストリビューター、またはスケジュールがない場合

戻り値: スケジュールが設定された公開のスケジュールレポート (詳細は、公開のスケジュール設定の応答例を参照してください)。

200 応答の本文のサンプル:

{
   "_href": "/pulp/api/v2/repositories/test/distributors/yum_distributor/schedules/publish/54d88df045ef4876fb50c994/",
   "_id": "54d88df045ef4876fb50c994",
   "args": [
       "test",
       "yum_distributor"
   ],
   "consecutive_failures": 0,
   "enabled": true,
   "failure_threshold": null,
   "first_run": "2015-02-09T10:37:36Z",
   "kwargs": {
       "overrides": {}
   },
   "last_run_at": "2015-02-09T10:38:23Z",
   "last_updated": 1423478256.805917,
   "next_run": "2015-02-10T10:37:36Z",
   "remaining_runs": null,
   "resource": "pulp:distributor:test:yum_distributor",
   "schedule": "P1DT",
   "task": "pulp.server.tasks.repository.publish",
   "total_run_count": 1
}

D.1.4.7. 公開履歴の取得

この呼び出しは、リポジトリーの公開履歴を取得します。リポジトリーで実行される各公開は履歴エントリーを作成します。

方法: GET

パーティション: read

Path: /pulp/api/v2/repositories/<repo_id>/history/publish/<distributor_id>/

クエリーパラメーター

limit
(整数) (オプション) 返される履歴エントリーの最大数。指定しない場合、履歴全体が返されます。
sort
(文字列) (任意) オプションは ascending および descending です。配列は公開のタイムスタンプでソートされます。

start_date (iso8601 日時) (任意) 指定の日付より前のタイムスタンプのエントリーは返されません。

end_date
(iso8601 datetime) (オプション) 指定された日付より後のタイムスタンプを持つエントリーは返されません。

レスポンスコード

200
履歴が正常に取得された場合

404: 指定したリポジトリー ID が存在しない場合

戻り値: 公開履歴エントリーの配列

200 応答の本文のサンプル:

[
 {
  "result": "success",
  "distributor_id": "my_demo_distributor",
  "distributor_type_id": "demo_distributor",
  "exception": null,
  "repo_id": "demo_repo",
  "traceback": null,
  "started": "1970:00:00T00:00:00Z",
  "completed": "1970:00:00T00:00:01Z",
  "error_message": null,
 }
]

D.1.5. コンテンツの取得

D.2. タスク管理

Pulp はほぼすべての呼び出しを非同期で実行でき、一部の呼び出しは常に非同期で実行されます。Pulp は、これらの呼び出しを実行するタスクを検査および管理する REST API を提供します。

D.2.1. タスクレポート

タスク情報オブジェクトは、非同期に実行されたタスクに関する情報を報告するために使用されます。

タスク情報オブジェクト

_href
(文字列) このタスクレポートオブジェクトを取得するための URI パス
state
(文字列) タスクの現在の状態。可能な値には、waitingskipped‘runningsuspendedfinishederrorcanceled が含まれます。
task_id
(文字列) 非同期呼び出しを実行しているタスクの一意の ID
task_type
(文字列) 非同期呼び出しを実行しているタスクの完全修飾 (パッケージ/メソッド) タイプを非推奨にしました。コンシューマーエージェントによって実行されるタスクのフィールドは空です。
progress_report
(オブジェクト) 任意の進捗情報。通常はオブジェクトの形式です。
result
(any) 呼び出しの戻り値 (存在する場合)
exception
(null または文字列) エラー例外値がある場合は非推奨
トレースバック
(null または配列) 例外が発生した場合、結果のトレースバックは非推奨になりました
start_time
(null または文字列) 呼び出しの実行が開始された時刻
finish_time
(null または文字列) 呼び出しの実行が停止した時間
tags
(配列) Call Report の検索に役立つ任意のタグ
spawned_tasks
(配列) このタスクによって生成されたタスクの URI とタスク ID を含むオブジェクトのリスト
worker_name
(文字列) タスクに関連付けられているワーカー。ワーカーがまだ割り当てられていない場合、このフィールドは空です。
queue
(文字列) タスクに関連付けられたキュー。キューがまだ割り当てられていない場合、このフィールドは空です。
error
(null またはオブジェクト) 全体的な呼び出しを失敗させなかったエラーがある場合は表示されます。Error Details を参照してください。
注記

exception フィールドおよび traceback フィールドは、Pulp 2.4 では非推奨になりました。発生したエラーに関する情報は error ブロックに含まれます。詳細は、エラーの詳細 を参照してください。

Task Report の例:

{
 "_href": "/pulp/api/v2/tasks/0fe4fcab-a040-11e1-a71c-00508d977dff/",
 "state": "running",
 "worker_name": "reserved_resource_worker-0@your.domain.com",
 "task_id": "0fe4fcab-a040-11e1-a71c-00508d977dff",
 "task_type": "pulp.server.tasks.repository.sync_with_auto_publish",
 "progress_report": {}, # contents depend on the operation
 "result": null,
 "start_time": "2012-05-17T16:48:00Z",
 "finish_time": null,
 "exception": null,
 "traceback": null,
 "tags": [
   "pulp:repository:f16",
   "pulp:action:sync"
 ],
 "spawned_tasks": [{"href": "/pulp/api/v2/tasks/7744e2df-39b9-46f0-bb10-feffa2f7014b/",
                    "task_id": "7744e2df-39b9-46f0-bb10-feffa2f7014b" }],
 "error": null
}

D.2.2. ポーリングタスクの進行状況

進行中のタスクをポーリングし、実行する非同期呼び出しの情報を生成します。ポーリングが Task Report を返す

方法: GET

Path: /pulp/api/v2/tasks/<task_id>/

パーティション: read

レスポンスコード

200
タスクが見つかった場合
404
タスクが見つからない場合

戻り値: クエリーされたタスクを表す Task Report

D.2.3. タスクをキャンセルする

一部の非同期タスクは、完了する前にキャンセルできます。キャンセルするには、タスクが待機状態または実行状態である必要があります。

注記

キャンセル要求が処理される前にタスクを完了したり、エラーが発生する可能性があります。そのため、この呼び出しにより、タスクの最終状態が canceled になる保証はありません。このような場合、このメソッド呼び出しは応答コード 200 を返します。

方法: DELETE

Path: /pulp/api/v2/tasks/<task_id>/

パーティション: delete

レスポンスコード

200
タスクのキャンセル要求を正常に受け取った場合
404
タスクが見つからない場合

戻り値: null

D.2.4. タスクの一覧表示

現在実行しているタスクと待機中のタスクがすべて表示されます。これは、Task Report インスタンスの配列を返します。配列はタグでフィルター設定できます。

方法: GET

パス: /pulp/api/v2/tasks/

パーティション: read

クエリーパラメーター

tag
(string) (オプション) すべてのタグパラメーターでタグ付けされたタスクのみを返します。

レスポンスコード

200
タスクの配列が含まれます。

戻り値: Task Report の配列

D.2.5. 完了したタスクの削除

状態が終了、エラー、スキップされたすべての完了したタスクを削除できます。この呼び出しは、成功した場合は応答コード 204 を返し、要求が禁止されている場合はコード 403 を返します。

方法: DELETE

パス: /pulp/api/v2/tasks/

パーティション: delete

state
(文字列) (オプション) 現在この状態にあるタスクのみを削除します

以下に例を示します。

/pulp/api/v2/tasks/?state=finished&state=skipped

レスポンスコード

204
タスクが正常に削除された場合
403
禁止された要求がある場合

戻り値: http 応答またはパルプ例外

D.2.6. タスクの検索

API 呼び出し元はタスクを検索することもできます。これは、search criteria document を使用します。

方法: POST

パス: /pulp/api/v2/tasks/search/

パーティション: read

リクエスト本文の内容: キー criteria を含めます。その値は、検索基準 で定義されたマッピング構造です。

レスポンスコード

200
タスクの一覧が含まれます。

戻り値: 戻り値のベースがリストであることを除いて、単一のタスクを取得するのと同じ形式。結果が見つからない場合は、空のリストが返されます。

方法: GET

パス: /pulp/api/v2/tasks/search/

パーティション: read

クエリーパラメーター: クエリーパラメーターは、Search Criteria で定義されている基準オブジェクトの属性と一致する必要があります。例外として、フィールド名は必要な数の field=foo ペアを持つ単数形で指定する必要があります。

以下に例を示します。

/pulp/api/v2/tasks/search/?field=id&field=task_type&limit=20

レスポンスコード

200
タスクの配列が含まれます。

D.3. タスクグループの管理

D.3.1. タスクグループ内のタスクをキャンセルする

特定のタスクグループ内のすべての非同期タスクは、完了する前にユーザーがキャンセルできます。キャンセルするには、タスクが waiting 状態または running 中の状態である必要があります。

注記

=== キャンセル要求が処理される前にタスクを完了したり、エラーが発生する可能性があります。そのため、この呼び出しにより、タスクの最終状態が canceled になる保証はありません。このような場合、このメソッド呼び出しは応答コード 200 を返します。 ===

方法: DELETE

Path: /pulp/api/v2/task_groups/<group_id>/

パーティション: delete

レスポンスコード

200
タスクグループのキャンセル要求を正常に受け取った場合
404
タスクグループが見つからない場合

戻り値: null

D.3.2. タスクグループの概要

タスクグループの概要オブジェクトは、タスクグループに属するすべてのタスクの状態を要約します。

タスクグループの概要オブジェクト

accepted
accepted 状態のタスクの数 (整数) です。
finished
finished 状態のタスクの数 (整数)
running
running 状態のタスクの数 (整数)
取り消し済み
canceled 状態のタスクの数 (整数)
待機中
waiting 状態のタスクの数 (整数)
skipped
skipped された状態のタスクの数 (整数)
suspended
suspended 状態のタスクの数 (整数)
error
error 状態のタスクの数 (整数)
tota
タスクグループ内のタスクの総数 (整数)

タスクグループの要約例:

{
 "accepted": 0,
 "finished": 100,
 "running": 4,
 "canceled": 0,
 "waiting": 2,
 "skipped": 0,
 "suspended": 0,
 "error": 0,
 "total": 106
}

D.3.3. タスクグループの進捗のポーリング

進行中のサマリー用にタスクのグループをポーリングします。ポーリングは、タスクグループでキャンセルタスク を返します。

方法: GET

Path: /pulp/api/v2/task_groups/<task_group_id>/state_summary/

パーティション: read

レスポンスコード

200
タスクグループが見つかった場合
404
タスクグループ ID が見つからない場合

戻り値: タスクグループのタスクをキャンセルする と、クエリーされたタスクグループ ID に属するすべてのタスクの状態を要約します。

バグの報告

付録E GNU General Public Licenses

E.1. GNU General Public License Version 2.0

GNU GENERAL PUBLIC LICENSE Version 2, June 1991

Copyright © 1989, 1991 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.

Preamble

The licenses for most software are designed to take away your freedom to share and change it.対照的に、GNU General Public License は、自由なソフトウェアを共有および変更する自由を保証することを目的としています。これにより、ソフトウェアがすべてのユーザーに無料で提供されるようになります。This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it.(Some other Free Software Foundation software is covered by the GNU Lesser General Public License instead.) You can apply it to your programs, too.

When we speak of free software, we are referring to freedom, not price.Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things.

To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights.These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it.

For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have.You must make sure that they, too, receive or can get the source code.And you must show them these terms so they know their rights.

We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software.

Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software.If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations.

Finally, any free program is threatened constantly by software patents.We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary.To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all.

The precise terms and conditions for copying, distribution and modification follow.

TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

0.This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License.The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Progr am or a portion of it, either verbatim or with modifications and/or translated into another language.(Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you".

Activities other than copying, distribution and modification are not covered by this License; they are outside its scope.The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program).Whether that is true depends on what the Program does.

1.You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program.

You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee.

2.You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions:

a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change.

b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License.

c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License.(Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.)

These requirements apply to the modified work as a whole.If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works.But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it.

Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program.

In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License.

3.You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following:

a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or,

b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or,

c) Accompany it with the information you received as to the offer to distribute corresponding source code.(This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.)

The source code for a work means the preferred form of the work for making modifications to it.For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable.However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.

If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code.

4.You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License.Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License.However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance.

5.You are not required to accept this License, since you have not signed it.However, nothing else grants you permission to modify or distribute the Program or its derivative works.These actions are prohibited by law if you do not accept this License.Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it.

6.Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions.You may not impose any further restrictions on the recipients' exercise of the rights granted herein.You are not responsible for enforcing compliance by third parties to this License.

7.If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License.If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all.For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program.

If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances.

It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices.Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice.

This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License.

8.If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded.In such case, this License incorporates the limitation as if written in the body of this License.

9.The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time.Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.

Each version is given a distinguishing version number.If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation.If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation.

10.If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission.For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this.Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally.

NO WARRANTY

11.BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

12.IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

END OF TERMS AND CONDITIONS

How to Apply These Terms to Your New Programs

If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms.

To do so, attach the following notices to the program.It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found.

  • one line to give the program's name and an idea of what it does.
  • Copyright © yyyy name of author
  • This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
  • This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the GNU General Public License for more details.
  • You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  • Also add information on how to contact you by electronic and paper mail.

If the program is interactive, make it output a short notice like this when it starts in an interactive mode:

Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w`.
This is free software, and you are welcome to redistribute it under certain conditions; type `show c` for details.

The hypothetical commands show w and show c should show the appropriate parts of the General Public License.もちろん、使用するコマンドは、show w および show c 以外の名前で呼ばれることもあり ます。プログラムに適したものであれば、マウスクリックやメニュー項目でもかまいません。

You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary.Here is a sample; alter the names:

Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision'
(which makes passes at compilers) written by James Hacker.

signature of Ty Coon, 1 April 1989
Ty Coon, President of Vice

This General Public License does not permit incorporating your program into proprietary programs.If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library.If this is what you want to do, use the [GNU Lesser General Public License](http://www.gnu.org/licenses/lgpl.html) instead of this License.

E.2. GNU General Public License Version 3.0

GNU GENERAL PUBLIC LICENSE Version 3, 29 June 2007

Copyright © 2007 Free Software Foundation, Inc.http://fsf.org/

Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.

Preamble

The GNU General Public License is a free, copyleft license for software and other kinds of works.

The licenses for most software and other practical works are designed to take away your freedom to share and change the works.対照的に、GNU General Public License は、プログラムのすべてのバージョンを共有および変更する自由を保証することを目的としています。これにより、プログラムがすべてのユーザーにとって自由なソフトウェアであり続けることが保証されます。We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors.You can apply it to your programs, too.

When we speak of free software, we are referring to freedom, not price.Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things.

To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights.Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others.

For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received.You must make sure that they, too, receive or can get the source code.And you must show them these terms so they know their rights.

Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it.

For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software.For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions.

Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so.This is fundamentally incompatible with the aim of protecting users' freedom to change the software.The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable.Therefore, we have designed this version of the GPL to prohibit the practice for those products.If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users.

Finally, every program is threatened constantly by software patents.States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary.To prevent this, the GPL assures that patents cannot be used to render the program non-free.

The precise terms and conditions for copying, distribution and modification follow.

TERMS AND CONDITIONS

0.Definitions

"This License" refers to version 3 of the GNU General Public License.

"Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks.

"The Program" refers to any copyrightable work licensed under this License.Each licensee is addressed as "you"."Licensees" and "recipients" may be individuals or organizations.

To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy.The resulting work is called a "modified version" of the earlier work or a work "based on" the earlier work.

A "covered work" means either the unmodified Program or a work based on the Program.

To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy.Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well.

To "convey" a work means any kind of propagation that enables other parties to make or receive copies.Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying.

An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License.If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion.

1.Source Code

The "source code" for a work means the preferred form of the work for making modifications to it."Object code" means any non-source form of a work.

A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language.

The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form.A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it.

The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities.However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work.For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work.

The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source.

The Corresponding Source for a work in source code form is that same work.

2.Basic Permissions

All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met.This License explicitly affirms your unlimited permission to run the unmodified Program.The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work.This License acknowledges your rights of fair use or other equivalent, as provided by copyright law.

You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force.You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright.Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you.

Conveying under any other circumstances is permitted solely under the conditions stated below.Sublicensing is not allowed; section 10 makes it unnecessary.

3.Protecting Users' Legal Rights From Anti-Circumvention Law

No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures.

When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures.

4.Conveying Verbatim Copies

You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program.

You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee.

5.Conveying Modified Source Versions

You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions:

a) The work must carry prominent notices stating that you modified it, and giving a relevant date.

b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7.This requirement modifies the requirement in section 4 to "keep intact all notices".

c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy.This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged.This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it.

d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so.

A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit.Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate.

6.Conveying Non-Source Forms

You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways:

a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange.

b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge.

c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source.This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b.

d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge.You need not require recipients to copy the Corresponding Source along with the object code.If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source.Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements.

e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d.

A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work.

A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling.In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage.For a particular product received by a particular user, "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product.A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product.

"Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source.The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made.

If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information.But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM).

The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed.Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network.

Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying.

7.Additional Terms

"Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions.Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law.If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions.

When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it.(Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission.

Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms:

a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or

b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or

c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or

d) Limiting the use for publicity purposes of names of licensors or authors of the material; or

e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or

f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors.

All other non-permissive additional terms are considered "further restrictions" within the meaning of section 10.If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term.If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying.

If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms.

Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way.

8.Termination

You may not propagate or modify a covered work except as expressly provided under this License.Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11).

However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation.

Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice.

Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License.If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10.

9.Acceptance Not Required for Having Copies

You are not required to accept this License in order to receive or run a copy of the Program.Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance.However, nothing other than this License grants you permission to propagate or modify any covered work.These actions infringe copyright if you do not accept this License.Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so.

10.Automatic Licensing of Downstream Recipients

Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License.You are not responsible for enforcing compliance by third parties with this License.

An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations.If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts.

You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License.For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it.

11.Patents

A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based.The work thus licensed is called the contributor's "contributor version".

A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version.For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License.

Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version.

In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement).To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party.

If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients."Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid.

If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it.

A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License.You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007.

Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law.

12.No Surrender of Others' Freedom

If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License.If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all.For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program.

13.Use with the GNU Affero General Public License

Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work.The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such.

14.Revised Versions of this License

The Free Software Foundation may publish revised and/or new versions of the GNU General Public License from time to time.Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.

Each version is given a distinguishing version number.If the Program specifies that a certain numbered version of the GNU General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation.If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation.

If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program.

Later license versions may give you additional or different permissions.However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version.

15.Disclaimer of Warranty

THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

16.Limitation of Liability

IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

17.Interpretation of Sections 15 and 16

If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee.

END OF TERMS AND CONDITIONS

How to Apply These Terms to Your New Programs

If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms.

To do so, attach the following notices to the program.It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found.

  • one line to give the program's name and a brief idea of what it does
  • Copyright © <year> <name of author>
  • This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
  • This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the GNU General Public License for more details.
  • You should have received a copy of the GNU General Public License along with this program.If not, see http://www.gnu.org/licenses/.
  • Also add information on how to contact you by electronic and paper mail.

If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode:

<program>  Copyright (C) <year>  <name of author>
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w`.
This is free software, and you are welcome to redistribute it under certain conditions; type `show c` for details.

The hypothetical commands show w and show c should show the appropriate parts of the General Public License.Of course, your program's commands might be different; for a GUI interface, you would use an "about box".

You should also get your employer (if you work as a programmer) or school, if any, to sign a "copyright disclaimer" for the program, if necessary.For more information on this, and how to apply and follow the GNU GPL, see http://www.gnu.org/licenses.

The GNU General Public License does not permit incorporating your program into proprietary programs.If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library.If this is what you want to do, use the GNU Lesser General Public License instead of this License.But first, please read http://www.gnu.org/philosophy/why-not-lgpl.html.

バグの報告

付録F Red Hat Update Infrastructure のアップグレード

前提条件

RHUI のエラータを適用する前に、Red Hat Enterprise Linux のエラータのみを適用する場合は、次のコマンドを実行します。

# yum --disablerepo=rhel-7-server-rhui-3-rpms update
重要

Red Hat は、RHUI の更新を監視し、リリース時に適用することで、インストールを常に最新の状態に保つことを推奨します。常に、最新の RHUI 3.1.x バージョンのみがサポートされます。以前のバージョンではバックポートは提供されません。Red Hat は、RHUI 3.0 を実行しているユーザーが最新のバージョンに速やかに更新することを強く推奨します。

注記

インストールされている RHUI バージョンが分からない場合は、RHUA ノードの rh-rhui-tools パッケージのバージョンを確認してください。以下の例では、インストールされている RHUI バージョンは 3.1.3 です。

# rpm -q rh-rhui-tools
rh-rhui-tools-3.1.3-1.noarch

F.1. RHUA ノードのアップグレード

RHUA ノードで次の手順を実行します。

  1. 更新しているパッケージを確認します。

    # yum check-update
  2. パッケージを更新します。

    # yum -y update

    RHUA ノードの一部の RHUI 更新には、新しいバージョンの pulp またはそのプラグインが含まれます。その場合、RHUI 3.0.x または 3.1.2 以前から更新する場合は、更新を適用した後にこれらの手順を実行します。

  3. pulp サービスが停止していることを確認します。

    # systemctl stop pulp\*
  4. データベースの移行を実行します。

    # sudo -u apache pulp-manage-db
    注記

    RHUI にあるリポジトリーおよびパッケージ数によっては、移行が完了するまで数分かかる場合があります。

    移行からの出力を監視します。RHUI に RHEL 8 のリポジトリーが含まれている場合には、一部を再公開する必要がある場合があります。その場合は、出力に表示される指示に従ってください。

  5. RHUI サービスを再起動します。

    # rhui-services-restart
  6. CDS ノードに設定を再適用します。

    • rhui-manager を実行して c を入力し、r を入力して、一度にホスト名を選択します。
    • 別の方法として、コマンドラインですべての CDS ホスト名に対して、次のコマンドを実行します。
    # rhui cds reinstall <HOSTNAME>
注記

新しいバージョンの pulp やそのプラグインがこの更新に含まれていない場合、更新後の手順は必要ありません。

F.1.1. CDS ノードのアップグレード

CDS ノードで次の手順を実行します。

  1. どのパッケージが更新されているかを確認します。

    # yum check-update
  2. CDS ノードの RHUI 更新には、新しいバージョンの pulp またはそのプラグインが含まれるか、rhui-oid-validator パッケージの更新が含まれるものもあります。この場合 (RHUI 3.0.x または 3.1.1 以前から更新する場合) は、RHUI の更新を適用する に、共有ファイルシステム (通常 /var/lib/rhui/remote_share にマウントされ、読み取り/書き込み権限) を再マウントしてください。これにより、pulp パッケージが CDS ノードで更新できるようになります。

    ファイルシステムを再マウントする方法は、基礎となるテクノロジーによって異なります。

    • Glusterfs を使用している場合は、一時的にファイルシステムをアンマウントしてから、読み取り/書き込み権限でマウントします。

      # umount /var/lib/rhui/remote_share
      # mount -o rw /var/lib/rhui/remote_share
    • NFS を使用している場合は、ワンステップでファイルシステムを再マウントできます。

      # mount -o remount,rw /var/lib/rhui/remote_share
  3. パッケージを更新します。

    # yum -y update
  4. 共有ファイルシステムを再マウントします。読み取り専用です。

    • Glusterfs を使用している場合は、次のコマンドを実行します。

      # umount /var/lib/rhui/remote_share
      # mount /var/lib/rhui/remote_share
    • NFS を使用している場合は、次のコマンドを実行します。

      # mount -o remount,ro /var/lib/rhui/remote_share
  5. RHUI サービスを再起動します。

    # rhui-services-restart

    新しい pulp または rhui-oid-validator バージョンが更新に含まれていない場合は、更新前の手順 (手順 2) または更新後の手順 (手順 4 および 5) を実行する必要はありません。

F.1.2. HAProxy ノードのアップグレード

Red Hat Update Infrastructure の更新は HAProxy ノードに影響を及ぼしません。HAProxy ノードを最新の状態に保つには、該当する RHEL 7 の更新がすべて適用されていることを確認することのみが必要になります。

F.1.3. Red Hat Update Infrastructure の新機能の設定

バージョン 3.0.0 で導入された以下の Red Hat Update Infrastructure 機能には、手動の設定が必要です。

F.1.3.1. エンタイトルメント証明書の更新

Red Hat Update Infrastructure 3.0.3 では、CDN 証明書を継続的に監視できるサービスが導入されました。CDN に新しい証明書が生成されると、このサービスは古い証明書を新しい証明書に置き換え、Red Hat Update Infrastructure がリポジトリーの同期を維持できるようにします。

この機能を有効にするのに、以下の手順を行っていない場合は先に行ってください。

重要

rhsmcertd サービスが実行され、有効になっていることを確認してください。

F.1.3.2. コンテナーレジストリーの認証情報

Red Hat Update Infrastructure 3.1.3 以降では、デフォルトのコンテナーレジストリーは registry.redhat.io です。このデフォルトのレジストリー URL を上書きして、他のレジストリーでホストされる Red Hat Update Infrastructure コンテナーに追加できます。

注記

registry.redhat.io を含む一部のレジストリーでは、ログインおよびパスワードが必要です。このデータを RHUI 設定に保存するか、プロンプトが表示されたらこれを指定できます。これらのオプションは、両方とも 「Red Hat Update Infrastructure へのコンテナーの追加」 で説明されています。

F.1.3.3. 追加のパッケージ

基本的な RHUI 機能を拡張するパッケージの包括的なリストは、「追加パッケージのインストール」 を参照してください。

付録G RHUI 2 から RHUI 3.1 への移行

重要

以下の手順では、カスタムリポジトリーを移行しない Red Hat リポジトリーのみを移行します。

手順

  1. 次のコマンドを実行して、ダウンロードした ISO を RHUA の mnt ディレクトリーにマウントします。

    [root@rhua mnt]# mkdir rhui
    [root@rhua mnt]# mount -o loop <ISO> rhui
  2. 移行スクリプトを rhui/migrate/migrate.py から RHUI 2 以降の RHUA にコピーします。

    [root@rhua ~]# scp rhui/migrate/migrate.py rhua2:/directory/in/rhua2
  3. Red Hat Update Infrastructure 2.x の RHUA にログインし、以下のスクリプトを実行して rhui-export-config-{timestamp}.tar を生成します。

    [root@rhua2 ~]# python ./migrate.py -password <PASSWORD>
    注記

    <PASSWORD> を、RHUI 管理者のパスワードに置き換えます。

  4. tarball の rhui-export を Red Hat Update Infrastructure 3.1.9 ディレクトリーにコピーします。

    [root@rhua2 ~]# scp rhui-export-config-{timestamp}.tar rhui3:
  5. 完全にインストールされた Red Hat Update Infrastructure 3.1.9 にアクセスします。
  6. rhui-export tarball を展開します。

    [root@rhua ~]# tar xvf rhui-export-config-{timestamp}.tar
  7. Red Hat Update Infrastructure 2.x からデータをインポートします。

    [root@rhua ~]# ./import-rhui2-data.sh
  8. プロンプトが表示されたら、RHUI パスワードを入力します。

tarball の rhui-export には、RHUI 2 RHUA から収集されるエンタイトルメント認証局 (CA) ファイル (CA 証明書およびそのキー) も含まれます。RHUI 3 CDS ノードで CA 証明書ファイルを使用して、以前に RHUI 2 からコンテンツをフェッチしたクライアントが RHUI 3 に切り替えたときに引き続き機能できるようにすることができます。レガシー CA の受け入れの詳細は、「レガシー CA を許可するようにコンテンツ配信サーバーを設定」 を参照してください。

または、Red Hat Update Infrastructure 3.9.1 を使用してクライアントを強制的に起動することもできます。これを実行する場合は、Red Hat Update Infrastructure 2.x から Red Hat Update Infrastructure 3.1.9 への移行を完了するためにいくつかの手順を実行する必要があります。

たとえば、次の手順を実行する必要があります。

  • Red Hat Update Infrastructure 3.1.9 RHUA で移行したリポジトリーの新しいエンタイトルメント証明書を生成します。
  • 証明書からクライアント設定 RPM を作成します。
  • RPM をクライアントにコピーしてインストールします。Red Hat Update Infrastructure 2.x RHUA の以前の yum 設定を置き換えます。

つまり、Red Hat Update Infrastructure 2.x にこのような RPM を作成し、たとえば example-rpm-1-1.noarch.rpm というファイルを使用して、クライアントにインストールする必要があります。Red Hat Update Infrastructure 3.1.9 では、リポジトリーの移行後にエンタイトルメントを生成し、example-rpm-2-1.noarch.rpm という名前の RPM を作成します。

Red Hat Update Infrastructure Management Tool を使用すると、設定 RPM のバージョン を指定できます。Red Hat Update Infrastructure 2.x で 1 を使用している場合は、Red Hat Update Infrastructure 3.1.9 でより大きな数値、たとえば 2 を使用します。その後、クライアントで yum update example-rpm-2-1.noarch.rpm または rpm -U example-rpm-2-1.noarch.rpm を使用できます。この設定は完全に置き換えられ、クライアントは Red Hat Update Infrastructure 3.1.9 のコンテンツを使用できます。別の名前を使用する場合は、古い設定パッケージ (yum remove example-rpm または rpm -e example-rpm) を削除して、新しい設定パッケージをインストールする必要があります。

バグを報告する

法律上の通知

Copyright © 2017, Red Hat, Inc.
このドキュメントのテキストと図は、Red Hat が Creative Commons Attribution-Share Alike 3.0 Unported license ("CC-BY-SA")に基づいてライセンスを受けています。An explanation of CC-BY-SA is available at http://creativecommons.org/licenses/by-sa/3.0/.In accordance with CC-BY-SA, if you distribute this document or an adaptation of it, you must provide the URL for the original version.
Red Hat, as the licensor of this document, waives the right to enforce, and agrees not to assert, Section 4d of CC-BY-SA to the fullest extent permitted by applicable law.
システム管理者ガイドの付録 D は、GPLv2+ で https://github.com/pulp/pulp/tree/2.18-release/ から採用されました。特定のライセンス情報については、Red Hat Update Infrastructure License for Documentation を参照してください。All licensing information has also been included as Appendix E.
Red Hat, Red Hat Enterprise Linux, the psyc logo, JBoss, OpenShift, Fedora, the Infinity logo, andpsyc are trademarks of Red Hat, Inc., registered in the United States and other countries.
Linux® is the registered trademark of Linus Torvalds in the United States and other countries.
Java® is a registered trademark of Oracle and/or its affiliates.
XFS® is a trademark of Silicon Graphics International Corp. or its subsidiaries in the United States and/or other countries.
MySQL® is a registered trademark of MySQL AB in the United States, the European Union and other countries.
Node.js® is an official trademark of Joyent.Red Hat Software Collections は、公式の Joyent Node.js オープンソースまたは商用プロジェクトに関連するものではなく、正式に関連しているわけではありません。
The OpenStack® Word Mark and OpenStack logo are either registered trademarks/service marks or trademarks/service marks of the OpenStack Foundation, in the United States and other countries and are used with the OpenStack Foundation's permission.We are not affiliated with, endorsed or sponsored by the OpenStack Foundation, or the OpenStack community.
All other trademarks are the property of their respective owners.