Bug 1098749 - new-kernel-pkg needlessly adds LANG= to boot options
Summary: new-kernel-pkg needlessly adds LANG= to boot options
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: grubby
Version: 29
Hardware: All
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Peter Jones
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-05-18 00:36 UTC by Marcos Mello
Modified: 2019-12-02 13:31 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 1010454
Environment:
Last Closed: 2019-11-27 19:05:40 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Proposed fix (2.19 KB, patch)
2014-12-22 11:45 UTC, Marcos Mello
no flags Details | Diff
Proposed fix (V2) (2.18 KB, patch)
2015-01-19 12:53 UTC, Marcos Mello
no flags Details | Diff
Proposed fix (V3) (2.26 KB, patch)
2015-01-20 08:55 UTC, Marcos Mello
no flags Details | Diff

Description Marcos Mello 2014-05-18 00:36:37 UTC
Cloning *again* since the original bug was closed without reason one more time. Awesome!


+++ This bug was initially created as a clone of Bug #1010454 +++

During the kernel install the 'LANG=<LOCALE>' directive is copied from the '/etc/locale.conf' and appended to the kernel parameters line in the bootloader configuration file.
As far as I'm concerned this is redundant, cause the 'systemd-localed.service' is the one responsible for the system locale settings, already.

e.g.
/etc/locale.conf:
LANG=en_US.utf8

/boot/extlinux/extlinux.conf
…
append … LANG=en_US.utf8
…

--- Additional comment from poma on 2013-10-03 12:48:24 EDT ---


No news here either.
Good luck.

--- Additional comment from Marcos Mello on 2013-11-28 06:51:33 EST ---

Should not Anaconda write locale.LANG (as it already does with vconsole.font and vconsole.keymap) to the bootloader configuration and your patch be applied? Or perhaps /etc/{vconsole.conf,locale.conf} and /etc/sysconfig/{keyboard,i18n} import section be removed entirely?

I configure boot options in /etc/default/grub. Get *new* ones from new-kernel-pkg is unexpected.

--- Additional comment from Marcos Mello on 2014-01-23 07:44:31 EST ---

/etc/sysconfig/i18n and /etc/sysconfig/keyboard are both dead now. Thus SYSFONT, SYSFONTACM, UNIMAP, KEYTABLE, are gone too. LANG by luck is still used in /etc/locale.conf, but I am not sure it serves any purpose anymore considering dracut already put /etc/{vconsole.conf,locale.conf} in the initramfs.

--- Additional comment from Marcos Mello on 2014-01-23 08:24:49 EST ---

BTW, since F20 Anaconda does not write vconsole.keymap anymore, see bug 1035316 .

--- Additional comment from poma on 2014-02-02 08:37:50 EST ---


https://bugzilla.redhat.com/show_bug.cgi?id=1001411 ;)

--- Additional comment from Marcos Mello on 2014-02-02 09:17:55 EST ---



--- Additional comment from Marcos Mello on 2014-02-02 14:20:56 EST ---

Related:
https://bugzilla.redhat.com/show_bug.cgi?id=1033250
https://bugzilla.redhat.com/show_bug.cgi?id=881624

--- Additional comment from poma on 2014-02-05 01:17:46 EST ---

I see no purpose cause the maintainer doesn't respond.
However, here it is.
Good look.

--- Additional comment from Marcos Mello on 2014-03-21 16:39:52 EDT ---



--- Additional comment from Marcos Mello on 2014-03-21 16:41:14 EDT ---

I have marked bug 1060332 as a duplicate. Please keep this bug open.

--- Additional comment from Marcos Mello on 2014-03-21 16:49:31 EDT ---

cc'ing Harald.

Harald, does LANG= do anything since

http://git.kernel.org/cgit/boot/dracut/dracut.git/commit/?id=6c8fc6e377b94e26e6d03cddbf174cb27caad0a6

?

--- Additional comment from Harald Hoyer on 2014-04-04 05:47:50 EDT ---

(In reply to Marcos Mello from comment #11)
> cc'ing Harald.
> 
> Harald, does LANG= do anything since
> 
> http://git.kernel.org/cgit/boot/dracut/dracut.git/commit/
> ?id=6c8fc6e377b94e26e6d03cddbf174cb27caad0a6
> 
> ?

Hmm, not really. On the kernel command line, one should use "rd.locale.LANG=" to overwrite the language in the initramfs. This might be used to use a different language, than the one which is in $initramfs/etc/locale.conf (copied from the system, the last time dracut was called to generate the initramfs) or in case of the rescue initramfs (which has no locale.conf) to set the language.

If you use "locale.LANG=", you overwrite the setting of the real root /etc/locale.conf, which you probably don't want.

--- Additional comment from Marcos Mello on 2014-04-04 12:51:32 EDT ---

Thank you for the explanation. Just like
https://bugzilla.redhat.com/show_bug.cgi?id=1033250
https://bugzilla.redhat.com/show_bug.cgi?id=1074113

Therefore all /etc/sysconfig/{i18n,keyboard} and /etc/{locale.conf,vconsole.conf} import stuff may be dropped from new-kernel-pkg because default initramfs is HostOnly. There is an usecase that I think deserves be documented: when you need a generic initramfs (i.e. install dracut-config-generic) and want to keep console/locale settings in it. As you told me on IRC, a simple Dracut snippet config file does the job

/etc/dracut.conf.d/console.conf

install_items+=" /etc/vconsole.conf /etc/locale.conf "

Besides that, should we have any rd.locale.XXX in the bootloader options? I never used the rescue initramfs. For it maybe? (it would be Anaconda business anyway)

--- Additional comment from Marcos Mello on 2014-04-25 17:41:50 EDT ---

It affects RHEL 7.0 RC too.

--- Additional comment from Marcos Mello on 2014-05-17 12:12:08 EDT ---

Why can not you keep this bug open? I agree that nobody appears to care, but closing it will just make it harder to someone take a look into this someday.

Comment 1 Marcos Mello 2014-12-18 13:21:36 UTC
It is still present in F21.

Comment 2 Marcos Mello 2014-12-22 11:45:51 UTC
Created attachment 971971 [details]
Proposed fix

Comment 4 Marcos Mello 2015-01-19 12:53:32 UTC
Created attachment 981510 [details]
Proposed fix (V2)

Replaced eval with Bash's built-in variable indirection.

Comment 5 Marcos Mello 2015-01-20 08:55:51 UTC
Created attachment 981776 [details]
Proposed fix (V3)

Drop $val. It is not needed anymore.

Comment 6 Marcos Mello 2015-01-28 11:09:03 UTC
Ping? This is a long-standing problem created by bitroted code.

I do not see a way to configure kernel-install to invoke new-kernel-pkg with --add-dracut-args, but anyway at least let's unbreak it. If one needs the dracut kernel args, teach kernel-install some config option for that.

Comment 7 Jaroslav Reznik 2015-03-03 15:49:24 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 22 development cycle.
Changing version to '22'.

More information and reason for this action is here:
https://fedoraproject.org/wiki/Fedora_Program_Management/HouseKeeping/Fedora22

Comment 8 Marko Myllynen 2015-03-13 10:33:55 UTC
It would indeed be nice to have this fixed in F22, especially now that a patch proposal already exists. Thanks.

Comment 9 Marcos Mello 2015-05-13 19:42:41 UTC
F22 is already gone at this point. Let's hope for F23!

Comment 10 Marcos Mello 2015-09-16 10:58:30 UTC
Marko, can't you take a look at this? F23 is almost beta now.

Comment 11 Marko Myllynen 2015-09-16 13:15:59 UTC
This looks like to be pending Peter Jones to review the patch attached earlier this year.

Peter?

Comment 12 Marcos Mello 2015-10-06 11:53:58 UTC
https://github.com/rhinstaller/grubby/pull/6

Comment 14 Marko Myllynen 2016-06-01 07:05:07 UTC
This is still an issue with Fedora 24, the upstream patches have not yet landed.

Comment 15 Marko Myllynen 2016-10-12 06:06:32 UTC
This is still an issue with Fedora 25 Beta.

Peter: all what should be needed is to rebuild grubby with the patch already included in upstream.

Thanks.

Comment 16 Marcos Mello 2016-11-07 10:16:30 UTC
I posted some time ago

https://github.com/rhinstaller/grubby/issues/14

if RHEL 6 compatibility is still necessary.

Comment 17 Fedora End Of Life 2017-07-25 18:40:02 UTC
This message is a reminder that Fedora 24 is nearing its end of life.
Approximately 2 (two) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 24. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '24'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version'
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not
able to fix it before Fedora 24 is end of life. If you would still like
to see this bug fixed and are able to reproduce it against a later version
of Fedora, you are encouraged  change the 'version' to a later Fedora
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

Comment 18 Marko Myllynen 2017-08-01 14:46:09 UTC
Sadly, after more than three and half years since the initial report, it is no more a surprise that this straightforward case is still an issue with the latest release, this time being Fedora 26.

Please assign to a more responsive maintainer if you know any. Thanks.

Comment 19 Jan Kurik 2017-08-15 08:07:17 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 27 development cycle.
Changing version to '27'.

Comment 20 Marko Myllynen 2017-10-24 11:26:18 UTC
This is still an issue with Fedora 27 Beta.

Comment 21 Marcos Mello 2018-02-19 10:15:56 UTC
What's going on? Is grubby unmaintained?

Comment 22 Marko Myllynen 2018-05-07 07:46:51 UTC
This is still an issue with Fedora 28.

Comment 23 Marko Myllynen 2018-05-07 13:01:18 UTC
Adjusting title a bit to make it hopefully more clear, adding PrioritizedBug to Whiteboard as per https://fedoraproject.org/wiki/Fedora_Program_Management/Prioritized_bugs_and_issues_-_the_process to hopefully get more attention to this.

The earlier BZ (pasted larger above as well) about this perhaps also provides some additional context:

https://bugzilla.redhat.com/show_bug.cgi?id=1010454

@pjones: we would really appreciate your comments here.

Thanks.

Comment 24 Matthew Miller 2018-06-06 14:27:13 UTC
Is there an actual harm here, or is it entirely aesthetic?

In order for Prioritized Bugs to really work, we need to keep it focused on issues with big impact. That doesn't mean thousands of little annoying problems shouldn't get fixed, but we can't solve them all with that particular hammer.

Comment 25 Marko Myllynen 2018-06-11 07:42:12 UTC
It is certainly an aesthetic and a correctness issue but whether there's an actual harm may be a matter of interpretation. Let's take a concrete example:

Installing Fedora 28 using Finnish will cause LANG=fi_FI.UTF-8 to be added to kernel command line via grub.cfg. If changing system locale later with localectl(1), only /etc/locale.conf is updated, not grub.cfg. There is thus discrepancy of kernel command line arguments and locale actually being used.

Since LANG is not set in /etc/default/grub using grubby(8) is also inadequate, one would need to locate grub.cfg (path differs on BIOS vs EFI systems), and change/remove all LANG entries there to avoid this discrepancy.

Thanks.

Comment 26 Ben Cotton 2018-08-01 20:49:26 UTC
Rejected as a PrioritizedBug. The upcoming grubby rework should address this issue.

Comment 27 Jan Kurik 2018-08-14 10:24:22 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 29 development cycle.
Changing version to '29'.

Comment 28 Ben Cotton 2019-10-31 20:51:12 UTC
This message is a reminder that Fedora 29 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora 29 on 2019-11-26.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
Fedora 'version' of '29'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 29 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 29 Ben Cotton 2019-11-27 19:05:40 UTC
Fedora 29 changed to end-of-life (EOL) status on 2019-11-26. Fedora 29 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 30 Marko Myllynen 2019-11-28 09:51:39 UTC
I am happy to confirm this seems to be finally resolved with Fedora 31. After fresh Fedora 31 installation using the release ISO and all-defaults no LANG option is in /proc/cmdline. After upgrading to the latest packages (which include a kernel upgrade as well) and rebooting, still no LANG in /proc/cmdline.


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