6.4. Configuring the HTTP server for HTTP boot


You must install and enable the httpd service on your server so that the server can provide HTTP boot resources on your network.

Prerequisites

  • Find the network addresses of the server.

    In the following examples, the server has a network card with the 192.168.124.2 IPv4 address.

Procedure

  1. Install the HTTP server:

    # dnf install httpd
  2. Create the /var/www/html/redhat directory:

    # mkdir -p /var/www/html/redhat
  3. Download the RHEL DVD ISO file. See All Red Hat Enterprise Linux Downloads.
  4. Create a mount point for the ISO file:

    # mkdir -p /var/www/html/redhat/iso
  5. Mount the ISO file:

    # mount -o loop,ro -t iso9660 path-to-RHEL-DVD.iso /var/www/html/redhat/iso
  6. Copy the boot loader, kernel, and initramfs from the mounted ISO file into your HTML directory:

    # cp -r /var/www/html/redhat/iso/images /var/www/html/redhat
    # cp -r /var/www/html/redhat/iso/EFI /var/www/html/redhat
  7. Make the boot loader configuration editable and ensure the boot files are owned by the user running httpd server (apache):

    # chmod 644 /var/www/html/redhat/EFI/BOOT/grub.cfg
    # chown -R apache:apache /var/www/html/redhat/EFI
  8. Edit the /var/www/html/redhat/EFI/BOOT/grub.cfg file and replace its content with the following:

    set default="1"
    
    function load_video {
      insmod efi_gop
      insmod efi_uga
      insmod video_bochs
      insmod video_cirrus
      insmod all_video
    }
    
    load_video
    set gfxpayload=keep
    
    set timeout=60
    
    menuentry 'Install Red Hat Enterprise Linux 10.0' --class fedora --class gnu-linux --class gnu --class os {
        	linuxefi /redhat/images/pxeboot/vmlinuz inst.repo=http://192.168.124.2/redhat/iso quiet
        	initrdefi /redhat/images/pxeboot/initrd.img
    }
    submenu 'Troubleshooting -->' {
        	menuentry 'Install Red Hat Enterprise Linux 10.0 in text mode' --class fedora --class gnu-linux --class gnu --class os {
                	linuxefi /redhat/images/pxeboot/vmlinuz inst.repo=http://192.168.124.2/redhat/iso inst.text quiet
                	initrdefi /redhat/images/pxeboot/initrd.img
        	}
        	menuentry 'Rescue a Red Hat Enterprise Linux system' --class fedora --class gnu-linux --class gnu --class os {
                	linuxefi /redhat/images/pxeboot/vmlinuz inst.stage2=http://192.168.124.2/redhat/iso inst.rescue quiet
                	initrdefi /redhat/images/pxeboot/initrd.img
        	}
    }

    In this file, update the following strings:

    Install Red Hat Enterprise Linux 10.0
    Edit the version number to match the version of RHEL that you downloaded.
    192.168.124.2
    Replace with the IP address of your server.
  9. Open ports in the firewall to allow HTTP (80), DHCP (67, 68) and DHCPv6 (546, 547) traffic:

    # firewall-cmd --zone public \
                   --add-port={80/tcp,67/udp,68/udp,546/udp,547/udp}

    This command enables temporary access until the next server reboot.

  10. Optional: To enable permanent access, add the --permanent option to the command.
  11. Reload firewall rules:

    # firewall-cmd --reload
  12. Start the HTTP server:

    # systemctl enable --now httpd
  13. Make the html directory and its content readable and executable:

    # chmod -cR u=rwX,g=rX,o=rX /var/www/html
  14. Restore the SELinux context of the html directory:

    # restorecon -FvvR /var/www/html
Red Hat logoGithubredditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

Red Hat을 사용하는 고객은 신뢰할 수 있는 콘텐츠가 포함된 제품과 서비스를 통해 혁신하고 목표를 달성할 수 있습니다. 최신 업데이트를 확인하세요.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

Theme

© 2026 Red Hat
맨 위로 이동