Duplicate entry for GRUB_CMDLINE_LINUX for Centos

Bug #1771366 reported by Doug Szumski on 2018-05-15
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
diskimage-builder
Undecided
Doug Szumski

Bug Description

A duplicate entry for GRUB_CMDLINE_LINUX appears in /etc/sysconfig/grub for Centos. This causes the first entry to be ignored.

`
GRUB_CMDLINE_LINUX="console=tty0 crashkernel=auto console=ttyS0,115200"
<snip>
GRUB_CMDLINE_LINUX_DEFAULT="console=tty0 console=ttyS0,115200 no_timer_check"
<snip>
GRUB_CMDLINE_LINUX="nofb nomodeset vga=normal" <---Duplicate
`

`
$ cat /proc/cmdline
BOOT_IMAGE=/boot/vmlinuz-3.10.0-693.11.1.el7.x86_64 root=LABEL=cloudimg-rootfs ro nofb nomodeset vga=normal console=tty0 console=ttyS0,115200 no_timer_check LANG=en_US.UTF-8
`

`
$ cat /etc/centos-release
CentOS Linux release 7.4.1708 (Core)
`

I also see the same issue with CentOS Linux release 7.3.1611 (Core).

Doug Szumski (dszumski) on 2018-05-15
Changed in diskimage-builder:
assignee: nobody → Doug Szumski (dszumski)

Fix proposed to branch: master
Review: https://review.openstack.org/568600

Changed in diskimage-builder:
status: New → In Progress

Reviewed: https://review.openstack.org/568600
Committed: https://git.openstack.org/cgit/openstack/diskimage-builder/commit/?id=c1b1534c87dbb6b355ae93024135479364c13ac4
Submitter: Zuul
Branch: master

commit c1b1534c87dbb6b355ae93024135479364c13ac4
Author: Doug Szumski <email address hidden>
Date: Tue May 15 15:19:37 2018 +0100

    Remove duplicate GRUB command line entry

    Without this change DIB appends a second command line entry to the GRUB
    config. This causes the original command line entry to be ignored
    when Linux is booted.

    The expected behaviour is that DIB appends to the existing entry as
    it does for Ubuntu and SUSE.

    Following discussion on the review, this also removes the distro specific
    switch statement, as update-grub just calls grub-mkconfig, meaning that
    there was nothing distro specific in the first place.

    Change-Id: I2298675dda1f699c572b3423e7274bc8bd7c1c9d
    Closes-Bug: #1771366

Changed in diskimage-builder:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers