Bug 611154 - Installation Method prompted in Anaconda although declared in ks.cfg and as boot: argument
Installation Method prompted in Anaconda although declared in ks.cfg and as b...
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: anaconda (Show other bugs)
6.1
i386 Linux
low Severity medium
: rc
: ---
Assigned To: Chris Lumens
Release Test Team
:
: 618144 (view as bug list)
Depends On:
Blocks: 579590 620813
  Show dependency treegraph
 
Reported: 2010-07-03 20:30 EDT by Carl Bachman Kharazmi
Modified: 2013-07-10 20:37 EDT (History)
12 users (show)

See Also:
Fixed In Version: anaconda-13.21.62-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 620813 (view as bug list)
Environment:
Last Closed: 2010-11-10 14:50:19 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Carl Bachman Kharazmi 2010-07-03 20:30:11 EDT
Description of problem:
Even if I use the following lines in my ks.cfg:
install
cdrom

and boot with:
boot: linux ks=hd:sda1:/ks.cfg method=cdrom

Anaconda will prompt "Installation Method" and I have to hit Return to continue with CD/DVD.

Version-Release number of selected component (if applicable):
RHEL6Beta2

How reproducible:
Start RHEL6Beta2 with kickstart

Steps to Reproduce:
1. Declare install; cdrom in ks.cfg
2. Boot RHEL6Beta2 DVD with boot: linux ks=hd:sda1:/ks.cfg method=cdrom
3.
  
Actual results:
Anaconda prompts for "Installation method"

Expected results:
Do not prompt for "Installation Method" again if it is defined in ks.cfg and at boot: using method=

Additional info:
ks.cfg is stored on usb:sda1.
host is i386, and dvd is rhel6b2 i386
Comment 2 Chris Lumens 2010-07-06 09:02:33 EDT
This is because we're still adding "askmethod" to the boot parameters in the tree composition process, which was earlier required for testing.  Can we get rid of that now?
Comment 3 Bill Nottingham 2010-07-06 12:44:37 EDT
CC'ing rel-eng.
Comment 4 Chris Lumens 2010-07-12 13:53:00 EDT
Backstory:

Several Fedora releases ago, we decided you could get away with completely skipping the method selection screen if we just had anaconda look at the /etc/yum.repos.d files and enable what's enabled by default.  Then, you get to use the mirror system without having to know anything.

When we started doing RHEL6, we didn't have any mirror system set up so by default, anaconda would run ahead to the package selection stage of installation, look for a website for the packages, not find anything, and prompt you.  That was awful inconvenient for testing, so we added the askmethod parameter into the boot configs by default.

Now, it seems extremely unlikely that RHEL is going to have the same mirror setup Fedora does, so perhaps the automatic repo enabling isn't a wise idea in RHEL.  In that case, we should kill the askmethod parameter from the boot configs and have it behave like it used to - where the cmdline args or kickstart take precedence, otherwise you get the method selection screen in loader.

Thoughts?
Comment 5 Jay Greguske 2010-07-12 14:47:09 EDT
Makes sense to me. My understanding is that the impacted code is in Anaconda's scripts directory, which is not owned by rel-eng, so hopefully nobody is waiting on me to take some action here. (not sure why I was cc'd)
Comment 6 Bill Nottingham 2010-07-12 15:33:15 EDT
If I'm understanding comment #4 correctly, we get exactly the same behavior (it asks for install method) unless the user passes an argument on the command line/kickstart?
Comment 9 Alexander Todorov 2010-07-22 11:38:16 EDT
With snap #8 askmethod is missing and when one boots off boot.iso anaconda will start stage2 from the boot.iso media and fail to download package metadata because no method is defined nor networking has been started. This is with manual install not kickstart.
Comment 10 David Cantrell 2010-07-22 11:59:40 EDT
(In reply to comment #9)
> With snap #8 askmethod is missing and when one boots off boot.iso anaconda will
> start stage2 from the boot.iso media and fail to download package metadata
> because no method is defined nor networking has been started. This is with
> manual install not kickstart.    

Please provide the exact steps you used to perform the installation so we can investigate.
Comment 11 Alexander Todorov 2010-07-22 12:02:50 EDT
1) Using virt-manager create new KVM domU and select boot.iso as your installation media. 

2) Anaconda starts and the first screen counts down 60 seconds where user can make modifications to boot cmd line. Just hit Enter. No modifications, no kickstart. 

3) Just hit Next accepting all defaults untill anaconda reaches the package selection screen. Before this screen is shown anaconda tells you that it can't download metadata.
Comment 12 Chris Lumens 2010-07-26 17:01:21 EDT
The reason you're still not seeing the askmethod screen is ceb63411285e06652080fd39fe0317d1c19c295a, which adds stage2= to the boot.iso's arguments automatically.  This causes us to skip the screen since we already know where stage2 is.

Alexander - can you try your testing with removing the whole stage2= argument?  Make sure everything works as expected with kickstart and method= like the original comment wanted.
Comment 13 Alexander Todorov 2010-07-27 08:09:44 EDT
(In reply to comment #12)
> Alexander - can you try your testing with removing the whole stage2= argument? 
> Make sure everything works as expected with kickstart and method= like the
> original comment wanted.    

Here's my test:

1) boot from boot.iso, remove the stage2= parameter. No kickstart. The command line is:
vmlinuz initrd=initrd.img method=http://...

Loader detected the ISO media and asked me if I want to do a media check. After skipping it asked me which install method to use. After selecting URL method I was asked about network settings. After network was configured with DHCP anaconda proceeded to stage2 without asking me for the actual URL. 


2) Second test is boot from boot.iso, remove the stage2= parameter and specify kickstart file. The command line is:
vmlinuz initrd=initrd.img ks=http://.../ks.cfg

The ks.cfg file contains all commands and specifies url install method. 

Loader started network via DHCP to download the ks.cfg file then asked me what install method to use. After selecting URL install method installation continued automatically. No more questions asked. 

Looks like both manual and automated installs are not working as expected. Note that there's bug #618618 (libvirt not using bridged networking) and I'm not sure if this doesn't affect things. Both tests were done in KVM.
Comment 14 Chris Lumens 2010-07-27 09:56:58 EDT
*** Bug 618144 has been marked as a duplicate of this bug. ***
Comment 15 Chris Lumens 2010-07-27 09:59:06 EDT
> 1) boot from boot.iso, remove the stage2= parameter. No kickstart. The command
> line is:
> vmlinuz initrd=initrd.img method=http://...
> 
> Loader detected the ISO media and asked me if I want to do a media check. After
> skipping it asked me which install method to use. After selecting URL method I
> was asked about network settings. After network was configured with DHCP
> anaconda proceeded to stage2 without asking me for the actual URL. 

You gave method=, therefore the askmethod screen is skipped.  This part is working as intended.

> 2) Second test is boot from boot.iso, remove the stage2= parameter and specify
> kickstart file. The command line is:
> vmlinuz initrd=initrd.img ks=http://.../ks.cfg
> 
> The ks.cfg file contains all commands and specifies url install method. 
> 
> Loader started network via DHCP to download the ks.cfg file then asked me what
> install method to use. After selecting URL install method installation
> continued automatically. No more questions asked. 

This one still looks to be a problem.
Comment 16 Alexander Todorov 2010-07-27 10:21:27 EDT
(In reply to comment #15)
> > 1) boot from boot.iso, remove the stage2= parameter. No kickstart. The command
> > line is:
> > vmlinuz initrd=initrd.img method=http://...
> > 
> > Loader detected the ISO media and asked me if I want to do a media check. After
> > skipping it asked me which install method to use. After selecting URL method I
> > was asked about network settings. After network was configured with DHCP
> > anaconda proceeded to stage2 without asking me for the actual URL. 
> 
> You gave method=, therefore the askmethod screen is skipped.  This part is
> working as intended.
> 

How is that working? There was the screen where you can select between Local Media, Hard Drive, NFS and URL install methods but after I've selected URL there wasn't the second screen which will ask me about the actual URL value. 

In the case I've specified method=http://... I expect that anaconda will automaticaly assume URL install method and not ask me anything.
Comment 17 Chris Lumens 2010-07-27 10:33:19 EDT
Oh right, sorry, I forgot that I'm always wrong about everything.
Comment 18 weizhang 2010-07-28 05:55:44 EDT
When I try to install the RHEL6.0-20100722.0 and boot from boot.iso (download from RHEL6.0-20100722.0 tree) with no method set, after the media check step I skip, there is no ask on install method and directly enter into graphic interface. Until choose "which type of installation would you like" and I choose "replace existing linux system" and "next", and choose "write change to disk" ,there will be an error said "Unable to read group information from repositories" (as bug 618144 said). In the RHEL6.0-20100722.0 tree I see that the anaconda version is 13.21.60-1

When trying to install the same build with DVD which contains the whole source, it also has no ask on install method, but there is no error and the installation can be finished successfully.
Comment 19 Chris Lumens 2010-07-28 10:04:45 EDT
David and I worked on this one yesterday and committed some new changes that worked well in my testing.
Comment 21 XinSun 2010-08-03 05:50:02 EDT
I try rhel6 beta2 (20100730.5) and boot from boot.iso again, without add "askmethod",this time I can see "DVD/NFS/URL" installation method dialogue.But after I choose URL method, I still did not find where I can input the URL address, so the installation will meet "unable to read group information repositories" again.
Comment 22 Alexander Todorov 2010-08-03 10:48:02 EDT
Tested with 0730.5 tree:

1) Boot from boot.iso with 'linux method=http://...', no kickstart - install is able to complete. However there's only "Minimal" package set option available which sounds like product.img was not downloaded. Will file a separate bug for that.

2) Boot from DVD with 'linux ks=http://...', where ks.cfg specifies cdrom as install method - install completed, all package options were available (i.e. Basic server, Desktop, Minimal, etc)


3) Boot from boot.iso with 'linux askmethod' - select URL install method, configure TCP/IP, anaconda will ask for the URL value - install completes fine.

4) Boot from DVD with 'linux askmethod' - select URL install method, configure networking, anaconda will ask for the URL value - install completes fine.


Moving to VERIFIED.
Comment 23 Alexander Todorov 2010-08-09 06:46:13 EDT
Chris,
booting with kickstart or manually with askmethod or method=... works as expected. However booting off boot.iso and just accepting the defaults fails. Anaconda asked me which install method I want, I've selected URL method, configured networking and stage2 started shortly afterwards. There was no screen asking me which is the URL of the install method. 

Should I open a new bug for this or move this one back to ASSIGNED?
Comment 24 Chris Lumens 2010-08-09 10:02:39 EDT
Please see bug 620746 and make sure you're testing anaconda-13.21.69-1 (or later).
Comment 25 releng-rhel@redhat.com 2010-11-10 14:50:19 EST
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.

Note You need to log in before you can comment on or make changes to this bug.