Crash Course on GRUB and Fully Automated Install

Latest response

Using UEFI I can mount and run install from a remotely mounted ISO file. I am also able to create my own custom ISO for the purposes of automating RHEL 7.1 server installations.
Where I need a crash course is on modifying grub.cfg and all other files required to fully automate an installation. There is no display, no keyboard, and no mouse. Where do I start with modifying the install process and including my required packages for a custom RHEL 7.1 installation?
Please don't tell me to read documentation because I have and I am no better off today then the day I started looking at the documentation.
By the way, where can I download a copy of the documentation so I don't have to hack my way through the web version? I prefer PDF.
I need to bypass all GUIs, all prompts for user input.
I need to make a list of all required packages to install.
I need to have the installation run completely unattended start to finish.

Responses

Tom.

Have you read the documentation regarding generating a kickstart file for unattended install? I assume this is going to meet your requirements but you have specifically requested I not tell you to read the documentation.

As for documentation in PDF, at the top right of the documentation pages you can change the format of the documentation, select 'PDF" and then save locally.

Hi Tom,

I'm on the documentation team at Red Hat, and it'd be very helpful for us if you could provide us with more information with regard to any problems you had with the docs. I assume you're referring to the Kickstart section of the Installation Guide. Could you please either file a bug against that guide, or just reach out to me directly, and I'd make sure the feedback gets to the appropriate person.

Thanks.

For starters,
The documentation refers to examples and provides this URL "https://access.redhat.com/labs/" which is BLANK.
I don't see any link at the top right of any page that indicates I can switch to PDF and save the entire file. "https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/Installation_Guide/chap-kickstart-installations.html"

23.2.5. Starting the Kickstart Installation
To start a Kickstart installation, a special boot option (inst.ks=) must be specified when booting the system. The exact way to specify the boot option depends on your system's architecture - see Chapter 20, Boot Options for details.

Chapter 20 only describes using boot menus during installation, not how to configure files to automate installation.

Since this is a network installation using UEFI I go to Chapter 21.
The only section describing GRUB is 21.1.3 but this is not the kind of network boot I require.

Where do I go to find instructions on how to modify GRUB files and prepare all other required files in an ISO so when I create my new ISO and boot the server it loads an ISO that will automate the installation?

Thanks Tom,

What browser and what version are you using? The labs and the PDF format seem to be a browser issue.

I'm forwarding your comments about the content of the guide to its maintainer.

You do need to allow redhat.com to run scripts to see the content of https://access.redhat.com/labs/

Hello Tom,

The procedure you found (21.1.3) is for IBM Power Systems. There is a separate procedure for AMD64/Intel 64 systems with UEFI firmware on the same page - just scroll up: procedure 21.2.

Step 7 in that procedure explains how to use boot options (the ones described in ch. 20, as well as generic kernel options) in an automated install. In this example, you want to add the inst.ks= option to the line starting with linuxefi - something like this:

linuxefi uefi/vmlinuz ip=dhcp inst.repo=http://10.32.5.1/mnt/archive/RHEL-7/7.1/Server/x86_64/os/ inst.ks=http://path/to/kickstart.ks

EDIT: If you're booting from an ISO, then you can add the inst.ks= option to the EFI/BOOT/grub.cfg file on Red Hat-provided boot media. This file describes the boot menu - the menu that normally appears on UEFI systems with displays when you boot.

The option selected by default is the second menuentry, and looks like this:

menuentry 'Test this media & install Red Hat Enterprise Linux 7.1' --class fedora --class gnu-linux --class gnu --class os {
        linuxefi /images/pxeboot/vmlinuz inst.stage2=hd:LABEL=RHEL-7.1\x20x86_64 rd.live.check quiet
        initrdefi /images/pxeboot/initrd.img
}

Again, add inst.ks=path/to/kickstart.ks to the line starting with linuxefi. The System Administrator's Guide has a section about customizing the GRUB2 menu, it describes everything you can do in this file.

Also note that the file has a 60 second timeout by default; you might want to change the set timeout=60 line to set timeout=0, which will boot the default entry immediately. Also, the default menu entry runs a media check before proceeding, which is not very useful if you don't have a display - you wouldn't see an error message if there was one, anyway. Remove the rd.live.check option from the entry if you want to skip it.

Once you're done editing, recreate the ISO with the edited config file (as you've already discussed here), and boot. The default menuentry will then be selected automatically and the Kickstart will be loaded.

I primarily use IE. The version is the latest version 11 running on Windows 7 Pro.
Switching to Chrome appears to work.
It also looks like the documentation format options at the top right of pages appears when I switch to Chrome.

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.