Bug 1452770 - Document and fix a small bug when using driverdisk kickstart command
Summary: Document and fix a small bug when using driverdisk kickstart command
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: anaconda
Version: 7.5
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: ---
Assignee: Anaconda Maintenance Team
QA Contact: Release Test Team
Filip Hanzelka
Depends On:
TreeView+ depends on / blocked
Reported: 2017-05-19 15:14 UTC by Jiri Konecny
Modified: 2021-01-15 07:36 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Known Issue
Doc Text:
Specifying a driverdisk partition with non-alphanumeric characters generates an invalid output Kickstart file When installing Red Hat Enterprise Linux using the *Anaconda* installer, you can add a driver disk by including a path to the partition containing the driver disk in the Kickstart file. At present, if you specify the partition by LABEL or CDLABEL which has non-alphanumeric characters in it, for example: driverdisk "CDLABEL=Fedora 23 x86_64:/path/to/rpm" the output Kickstart file created during the *Anaconda* installation will contain incorrect information. To work around this problem, use only alphanumeric characters when specifying the partition by LABEL or CDLABEL.
Clone Of:
Last Closed: 2021-01-15 07:36:32 UTC
Target Upstream Version:

Attachments (Terms of Use)

Description Jiri Konecny 2017-05-19 15:14:14 UTC
Description of problem:
Presently you can use a driverdisk by specifying a "partition" using a LABEL/UUID, though it should be noted that this behavior isn't officially documented in Pykickstart. That said, we should make an effort to document it.

In an effort to make sure the behavior is bug-free however, I uncovered an issue when specifying a partition by LABEL using non-alphanumeric characters, e.g.:

You should be able to write this to KS and get the same output KS after installation:

driverdisk "CDLABEL=Fedora 23 x86_64:/path/to/rpm"

In theory, you should be able to write this to KS and get the same output after installation, but it fails to parse.

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

How reproducible:

Steps to reproduce:
The best way how to test this is by running Anaconda with this command in it.

1) Create kickstart file with line 'driverdisk "CDLABEL=Fedora 86_64:/path/to/rpm"'
2) Create partition or external USB on the testing machine
3) Format this partition with label "Fedora 86_64"
4) Run this kickstart installation
5) Verify output kickstart file

Actual results:
The "driverdisk" kickstart command usage is not documented properly.

Expected results:
The "driverdisk" kickstart command should be documented and should work correctly for LABEL/UUID.

Comment 2 Petr Bokoc 2017-06-13 11:03:00 UTC
Let's document this as a known issue for 7.4.

Comment 9 Brian Lane 2019-11-18 17:33:19 UTC
Do you have any logs related to this? Are the spaces causing problems in pykickstart itself, or in the driver-disk anaconda code, or both?

Comment 10 Jiri Konecny 2019-11-19 11:07:36 UTC
Brian see comment 7. Yes the problematic part is space.

Unfortunately, the DUD bugs are not easy to reproduce. I'll try to get more info.

Comment 11 Brian Lane 2019-11-19 19:13:56 UTC
(In reply to Jiri Konecny from comment #10)
> Brian see comment 7. Yes the problematic part is space.
> Unfortunately, the DUD bugs are not easy to reproduce. I'll try to get more
> info.

What I mean is, when you look at what happens in the anaconda dracut module is pykickstart failing to return the whole path? eg. "CDLABEL=Fedora" or is the problem after the value is retrieved from pyparted?
I'll also take a look and see if I can trigger it here.

Comment 12 Brian Lane 2019-11-19 23:19:00 UTC
You can work around this by escaping the spaces in the driverdisk line.
Also, you cannot specify the path to the rpm, the driverdisk should be extracted to the root of the partition.
This problem exists in all versions of Anaconda, as far as I can tell.

If you want to escape the spaces the right place to do that is in dracut/parse-kickstart in Anaconda. I have a PR against master here - https://github.com/rhinstaller/anaconda/pull/2223

Comment 13 Jiri Konecny 2019-11-20 12:38:51 UTC
Thanks a lot Brian for your help and PR!

Comment 14 Jiri Konecny 2019-11-20 12:39:50 UTC
Returning back to NEW because the fix was proposed to Fedora.

Comment 15 Jiri Konecny 2020-01-02 15:57:32 UTC
Clearing need info flag. The question is already answered.

Comment 17 Jiri Konecny 2020-03-11 13:48:08 UTC
I've tested PR in comment 12 and it seems to be fixing issue with space in name correctly. 
However, specifying path to the rpm is not supported by Anaconda. You have to have a repository or an iso on the disk you are specifying which will be auto-discovered but not a fixed path to the specific rpm.

This is correct:
driverdisk "CDLABEL=Fedora 23 x86_64"

This is incorrect:
driverdisk "CDLABEL=Fedora 23 x86_64:/path/to/rpm"

Comment 19 RHEL Program Management 2021-01-15 07:36:32 UTC
After evaluating this issue, there are no plans to address it further or fix it in an upcoming release.  Therefore, it is being closed.  If plans change such that this issue will be fixed in an upcoming release, then the bug can be reopened.

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