7.8. Building a Discovery Image


The Discovery image is a minimal operating system that is PXE-booted on hosts to acquire initial hardware information and to check in with Satellite. Discovered hosts keep running the Discovery image until they are rebooted into Anaconda, which then initiates the provisioning process.

The operating system image is based on Red Hat Enterprise Linux 7.

The foreman-discovery-image package contains this image. You must install the package on the Capsule that provides TFTP services.

Use this procedure to build a Satellite discovery image or rebuild an image if you change configuration files.

Do not use this procedure on your production Satellite or Capsule. Use either a dedicated environment or copy the synchronized repositories and a kickstart file to a separate server.

Prerequisites

  • Install the livecd-tools package:

    # satellite-maintain packages install livecd-tools
    Copy to Clipboard Toggle word wrap
  • For the following Red Hat Enterprise Linux 7 repositories required to build the Discovery image, change the download policy to Immediate. This is required because Satellite downloads all packages only during synchronization of repositories with the immediate download policy.

    • The latest Red Hat Enterprise Linux 7 Server (Kickstart) repository. For example, Red Hat Enterprise Linux 7 Server Kickstart x86_64 7.7.
    • Red Hat Satellite Capsule 6.8 for RHEL 7 Server RPMs x86_64.

    For more information about changing download policies, see Changing the Download Policy for a Repository in the Content Management Guide.

  • Synchronize the following Red Hat Enterprise Linux 7 repositories required to build the Discovery image:

    • The latest Red Hat Enterprise Linux 7 Server (Kickstart) repository. For example, Red Hat Enterprise Linux 7 Server Kickstart x86_64 7.7.
    • Red Hat Satellite Capsule 6.8 for RHEL 7 Server RPMs x86_64.

    For more information about synchronizing repositories, see Synchronizing Red Hat Repositories in the Content Management Guide.

Procedure

To build the Satellite discovery image, complete the following steps:

  1. Open the /usr/share/foreman-discovery-image/foreman-discovery-image.ks file for editing:

    # vim /usr/share/foreman-discovery-image/foreman-discovery-image.ks
    Copy to Clipboard Toggle word wrap
  2. Replace the repo lines in the kickstart file with the repository URLs:

    repo --name=rhel --baseurl=file:///var/lib/pulp/published/yum/https/repos/Default_Organization/Library/content/dist/rhel/server/7/7.7/x86_64
    repo --name=sat --baseurl=file:///var/lib/pulp/published/yum/https/repos/Default_Organization/Library/content/dist/rhel/server/7/7Server/x86_64/sat-capsule/6.8/os
    Copy to Clipboard Toggle word wrap
  3. Run the livecd-creator tool:

    # livecd-creator --title="Discovery-Image" \
    --compression-type=xz \
    --cache=var/cache/build-fdi \
    --config /usr/share/foreman-discovery-image/foreman-discovery-image.ks \
    --fslabel fdi \
    --tmpdir /var/tmp
    Copy to Clipboard Toggle word wrap

    If you change fdi in the --fslabel option, you must also change the root label on the kernel command line when loading the image. fdi or the alternative name is appended to the .iso file that is created as part of this procedure. The PXE Discovery tool uses this name when converting from .iso to PXE.

    Use /var/tmp because this process requires close to 3GB of space and /tmp might have problems if the system is low on swap space.

  4. Verify that your fdi.iso file is created:

    # ls *.iso -h
    Copy to Clipboard Toggle word wrap

When you create the .iso file, you can boot the .iso file over a network or locally. Complete one of the following procedures.

To boot the iso file over a network:

  1. To extract the initial ramdisk and kernel files from the .iso file over a network, enter the following command:

    # discovery-iso-to-pxe fdi.iso
    Copy to Clipboard Toggle word wrap
  2. Create a directory to store your boot files:

    # mkdir /var/lib/tftpboot/boot/myimage
    Copy to Clipboard Toggle word wrap
  3. Copy the initrd0.img and vmlinuz0 files to your new directory.
  4. Edit the KERNEL and APPEND entries in the /var/lib/tftpboot/pxelinux.cfg file to add the information about your own initial ramdisk and kernel files.

To boot the iso file locally:

If you want to create a hybrid .iso file for booting locally, complete the following steps:

  1. To convert the .iso file to an .iso hybrid file for PXE provisioning, enter the following command:

    # isohybrid --partok fdi.iso
    Copy to Clipboard Toggle word wrap

    If you have grub2 packages installed, you can also use the following command to install a grub2 bootloader:

    # isohybrid --partok --uefi fdi.iso
    Copy to Clipboard Toggle word wrap
  2. To add md5 checksum to the .iso file so it can pass installation media validation tests in Satellite, enter the following command:

    # implantisomd5 fdi.iso
    Copy to Clipboard Toggle word wrap
トップに戻る
Red Hat logoGithubredditYoutubeTwitter

詳細情報

試用、購入および販売

コミュニティー

Red Hat ドキュメントについて

Red Hat をお使いのお客様が、信頼できるコンテンツが含まれている製品やサービスを活用することで、イノベーションを行い、目標を達成できるようにします。 最新の更新を見る.

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

Red Hat では、コード、ドキュメント、Web プロパティーにおける配慮に欠ける用語の置き換えに取り組んでいます。このような変更は、段階的に実施される予定です。詳細情報: Red Hat ブログ.

会社概要

Red Hat は、企業がコアとなるデータセンターからネットワークエッジに至るまで、各種プラットフォームや環境全体で作業を簡素化できるように、強化されたソリューションを提供しています。

Theme

© 2025 Red Hat