All of lore.kernel.org
 help / color / mirror / Atom feed
* need hostname on menu
@ 2021-01-24  0:52 Humphrey van Polanen Petel
  2021-01-24  0:57 ` John Paul Adrian Glaubitz
  2021-01-24  9:28 ` Didier Spaier
  0 siblings, 2 replies; 10+ messages in thread
From: Humphrey van Polanen Petel @ 2021-01-24  0:52 UTC (permalink / raw)
  To: grub-devel

[-- Attachment #1: Type: text/plain, Size: 894 bytes --]

Hi,

Currently, the grub menu has no option to display the hostname, but when 
on a dual-boot system there two systems of the same distribution it 
becomes a problem when the user is not sure which install is on which 
disk.  In my case, I had Ubuntu 16.04 and 20.04 on separate disks and 
grub just gave "Ubuntu" as the default so I had to close down the system 
and reopen the case to refresh my memory of which install was on which 
disk.  I solved the problem  by replacing

     GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`

with

     GRUB_DISTRIBUTOR=`cat /etc/hostname || lsb_release -i -s 2> 
/dev/null || echo Debian`

which worked well enough.

However, it seems to me that it would be a lot more useful to add a 
parameter allowing the user to display the name of the install from 
/etc/hostname.

Humphrey

-- 
We are but sheep and here to be fleeced


[-- Attachment #2: Type: text/html, Size: 1369 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
  2021-01-24  0:52 need hostname on menu Humphrey van Polanen Petel
@ 2021-01-24  0:57 ` John Paul Adrian Glaubitz
  2021-01-24  3:32   ` Humphrey van Polanen Petel
  2021-01-24  9:28 ` Didier Spaier
  1 sibling, 1 reply; 10+ messages in thread
From: John Paul Adrian Glaubitz @ 2021-01-24  0:57 UTC (permalink / raw)
  To: Humphrey van Polanen Petel; +Cc: The development of GNU GRUB

Hello!

On 1/24/21 1:52 AM, Humphrey van Polanen Petel wrote:
> However, it seems to me that it would be a lot more useful to add a parameter
> allowing the user to display the name of the install from /etc/hostname.

GRUB is a universal bootloader which supports multiple platforms and operating
systems. I'm not sure it would be trivial to implement such a feature for all
possible target configurations that GRUB support just to solve this rather exotic
problem you are describing here.

Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@debian.org
`. `'   Freie Universitaet Berlin - glaubitz@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913



^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
  2021-01-24  0:57 ` John Paul Adrian Glaubitz
@ 2021-01-24  3:32   ` Humphrey van Polanen Petel
  2021-01-24  9:03     ` John Paul Adrian Glaubitz
  0 siblings, 1 reply; 10+ messages in thread
From: Humphrey van Polanen Petel @ 2021-01-24  3:32 UTC (permalink / raw)
  To: John Paul Adrian Glaubitz; +Cc: The development of GNU GRUB

[-- Attachment #1: Type: text/plain, Size: 1070 bytes --]

Hi,

Whether it is a trivial problem or not I am not qualified to comment on, 
but it nevertheless seems to me that being able to identify at boot a 
systemby the name by which it is know is of obvious benefit simply 
because mnemonics are most easily remembered.

And if you wish to call this a "rather exotic problem" then I would like 
to point out that it is not up to the developers, but to the users to 
determine how they use their system.

Humphrey

We are but sheep and here to be fleeced

On 24/1/21 11:57 am, John Paul Adrian Glaubitz wrote:
> Hello!
>
> On 1/24/21 1:52 AM, Humphrey van Polanen Petel wrote:
>> However, it seems to me that it would be a lot more useful to add a parameter
>> allowing the user to display the name of the install from /etc/hostname.
> GRUB is a universal bootloader which supports multiple platforms and operating
> systems. I'm not sure it would be trivial to implement such a feature for all
> possible target configurations that GRUB support just to solve this rather exotic
> problem you are describing here.
>
> Adrian
>

[-- Attachment #2: Type: text/html, Size: 1924 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
  2021-01-24  3:32   ` Humphrey van Polanen Petel
@ 2021-01-24  9:03     ` John Paul Adrian Glaubitz
  2021-01-24 11:26       ` Humphrey van Polanen Petel
  0 siblings, 1 reply; 10+ messages in thread
From: John Paul Adrian Glaubitz @ 2021-01-24  9:03 UTC (permalink / raw)
  To: Humphrey van Polanen Petel; +Cc: The development of GNU GRUB

Hello!

On 1/24/21 4:32 AM, Humphrey van Polanen Petel wrote:
> Whether it is a trivial problem or not I am not qualified to comment on, but it
> nevertheless seems to me that being able to identify at boot a systemby the name
> by which it is know is of obvious benefit simply because mnemonics are most easily
> remembered.

I was not arguing this point. I was just talking about the development and maintenance
effort.

> And if you wish to call this a "rather exotic problem" then I would like to point out
> that it is not up to the developers, but to the users to determine how they use their
> system.

No developer is telling you how to use the software, that's not my point but that someone
has to implement the feature and maintain it and that person is the developer.

So while the developer does not get to tell you how you use the software, he decides what
he works on and what not. And if there is a feature that is requested by only a very small
amount of users, then it usually makes no sense to put up with the additional development
and maintenance burden.

Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@debian.org
`. `'   Freie Universitaet Berlin - glaubitz@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913



^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
  2021-01-24  0:52 need hostname on menu Humphrey van Polanen Petel
  2021-01-24  0:57 ` John Paul Adrian Glaubitz
@ 2021-01-24  9:28 ` Didier Spaier
  2021-01-24  9:33   ` Didier Spaier
  1 sibling, 1 reply; 10+ messages in thread
From: Didier Spaier @ 2021-01-24  9:28 UTC (permalink / raw)
  To: grub-devel

Hi,

Le 24/01/2021 à 01:52, Humphrey van Polanen Petel a écrit :
> However, it seems to me that it would be a lot more useful to add a 
> parameter allowing the user to display the name of the install from 
> /etc/hostname.

I won't repeat what grub developers said but in addition:

1) Other users could want to customize the name including an information
not available in /etc/hostname, like e.g. /etc/os-release

2) the customization is easy to by the user or the package maintainer
or the distribution maintainer and there are several ways to do that,
for instance edit by hand grub.cfg, or write a customized config file as
/etc/grub.d/<nn>_<name>, or write a script that customizes grub.cfg
after having run grub-mkconfig or update-grub, possibly called
by a wrapper script that will run grub-mkconfig or update-grub first.

Have a good day,
Didier


I won't repeat what grub developers said but in addition:

1) Other users could want to customize the name including an information
not available in /etc/hostname, like e.g. /etc/os-release

2) the customization is easy to do by the user or the package maintainer or
the distribution maintainer and there are several ways to do that, like:
a) Edit by hand grub.cfg
b) Write a customized config file as /etc/grub.d/<nn>_<name>.
c) Write a script that customizes grub.cfg after having run grub-mkconfig
or update-grub.
d) Write a  wrapper script that runs grub-mkconfig or update-grub then do
the customization.

Have a good day,
Didier


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
  2021-01-24  9:28 ` Didier Spaier
@ 2021-01-24  9:33   ` Didier Spaier
  0 siblings, 0 replies; 10+ messages in thread
From: Didier Spaier @ 2021-01-24  9:33 UTC (permalink / raw)
  To: grub-devel

Sorry for the faulty paste, please keep only the part quoted below:

Le 24/01/2021 à 10:28, Didier Spaier a écrit :
<snip>> Hi,> > Le 24/01/2021 à 01:52, Humphrey van Polanen Petel a 
écrit :>> However, it seems to me that it would be a lot more useful to 
add a >> parameter allowing the user to display the name of the install 
from >> /etc/hostname.>> I won't repeat what grub developers said but in 
addition:> > 1) Other users could want to customize the name including 
an information> not available in /etc/hostname, like e.g. 
/etc/os-release> > 2) the customization is easy to do by the user or the 
package maintainer or> the distribution maintainer and there are several 
ways to do that, like:> a) Edit by hand grub.cfg> b) Write a customized 
config file as /etc/grub.d/<nn>_<name>.> c) Write a script that 
customizes grub.cfg after having run grub-mkconfig> or update-grub.> d) 
Write a  wrapper script that runs grub-mkconfig or update-grub then do> 
the customization.> > Have a good day,> Didier


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
  2021-01-24  9:03     ` John Paul Adrian Glaubitz
@ 2021-01-24 11:26       ` Humphrey van Polanen Petel
  2021-01-24 11:38         ` John Paul Adrian Glaubitz
  0 siblings, 1 reply; 10+ messages in thread
From: Humphrey van Polanen Petel @ 2021-01-24 11:26 UTC (permalink / raw)
  To: John Paul Adrian Glaubitz; +Cc: The development of GNU GRUB

[-- Attachment #1: Type: text/plain, Size: 1264 bytes --]

Okay, I get it.

I defer to your decision.

Humphrey

We are but sheep and here to be fleeced

On 24/1/21 8:03 pm, John Paul Adrian Glaubitz wrote:
> Hello!
>
> On 1/24/21 4:32 AM, Humphrey van Polanen Petel wrote:
>> Whether it is a trivial problem or not I am not qualified to comment on, but it
>> nevertheless seems to me that being able to identify at boot a systemby the name
>> by which it is know is of obvious benefit simply because mnemonics are most easily
>> remembered.
> I was not arguing this point. I was just talking about the development and maintenance
> effort.
>
>> And if you wish to call this a "rather exotic problem" then I would like to point out
>> that it is not up to the developers, but to the users to determine how they use their
>> system.
> No developer is telling you how to use the software, that's not my point but that someone
> has to implement the feature and maintain it and that person is the developer.
>
> So while the developer does not get to tell you how you use the software, he decides what
> he works on and what not. And if there is a feature that is requested by only a very small
> amount of users, then it usually makes no sense to put up with the additional development
> and maintenance burden.
>
> Adrian
>

[-- Attachment #2: Type: text/html, Size: 2030 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
  2021-01-24 11:26       ` Humphrey van Polanen Petel
@ 2021-01-24 11:38         ` John Paul Adrian Glaubitz
  0 siblings, 0 replies; 10+ messages in thread
From: John Paul Adrian Glaubitz @ 2021-01-24 11:38 UTC (permalink / raw)
  To: Humphrey van Polanen Petel; +Cc: The development of GNU GRUB

On 1/24/21 12:26 PM, Humphrey van Polanen Petel wrote:
> Okay, I get it.
> 
> I defer to your decision.

I did not make any decisions as I'm not in charge of GRUB, I'm just a
contributing developer.

I merely stated my opinion and pointed out some problems with your
suggestion.

Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@debian.org
`. `'   Freie Universitaet Berlin - glaubitz@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913



^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
@ 2021-01-24 13:06 J.Witvliet
  0 siblings, 0 replies; 10+ messages in thread
From: J.Witvliet @ 2021-01-24 13:06 UTC (permalink / raw)
  To: grub-devel

[-- Attachment #1: Type: text/plain, Size: 2018 bytes --]




From: "Humphrey van Polanen Petel" <hpvpp@optusnet.com.au<mailto:hpvpp@optusnet.com.au>>
Date: Sunday, 24 January 2021 at 12:27:20
To: "John Paul Adrian Glaubitz" <glaubitz@physik.fu-berlin.de<mailto:glaubitz@physik.fu-berlin.de>>
Cc: "The development of GNU GRUB" <grub-devel@gnu.org<mailto:grub-devel@gnu.org>>
Subject: Re: need hostname on menu


Okay, I get it.

I defer to your decision.

Humphrey

We are but sheep and here to be fleeced

On 24/1/21 8:03 pm, John Paul Adrian Glaubitz wrote:

Hello!

On 1/24/21 4:32 AM, Humphrey van Polanen Petel wrote:


Whether it is a trivial problem or not I am not qualified to comment on, but it
nevertheless seems to me that being able to identify at boot a systemby the name
by which it is know is of obvious benefit simply because mnemonics are most easily
remembered.


I was not arguing this point. I was just talking about the development and maintenance
effort.


All true.
But after some thoughts, and in this particular case...
I would suggest to ask this question to canonical, as they produce the grub-config file.
Not the people from grub-development.

Afaicr, if you install different versions of Suse, you’ll get different lines in grub-config (analogue to what you asked for)

Dit bericht kan informatie bevatten die niet voor u is bestemd. Indien u niet de geadresseerde bent of dit bericht abusievelijk aan u is toegezonden, wordt u verzocht dat aan de afzender te melden en het bericht te verwijderen. De Staat aanvaardt geen aansprakelijkheid voor schade, van welke aard ook, die verband houdt met risico's verbonden aan het elektronisch verzenden van berichten.

This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. The State accepts no liability for damage of any kind resulting from the risks inherent in the electronic transmission of messages.

[-- Attachment #2: Type: text/html, Size: 2945 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: need hostname on menu
       [not found] <6ecee3f7-3b00-4fba-8320-5c65a2549da7@QAD40071.mod.nl>
@ 2021-01-24  8:45 ` J.Witvliet
  0 siblings, 0 replies; 10+ messages in thread
From: J.Witvliet @ 2021-01-24  8:45 UTC (permalink / raw)
  To: grub-devel

[-- Attachment #1: Type: text/plain, Size: 2120 bytes --]

No, that would still be not enough:
Imagine installing centOS 3 times, one with gnome-desktop, one with kde-desktop, and one with yet another variant, but all using the same OS-release.
Your suggestion would still yield three identical labels...


From: "Humphrey van Polanen Petel" <hpvpp@optusnet.com.au<mailto:hpvpp@optusnet.com.au>>
Date: Sunday, 24 January 2021 at 01:52:49
To: "grub-devel@gnu.org" <grub-devel@gnu.org<mailto:grub-devel@gnu.org>>
Subject: need hostname on menu


Hi,

Currently, the grub menu has no option to display the hostname, but when on a dual-boot system there two systems of the same distribution it becomes a problem when the user is not sure which install is on which disk.  In my case, I had Ubuntu 16.04 and 20.04 on separate disks and grub just gave "Ubuntu" as the default so I had to close down the system and reopen the case to refresh my memory of which install was on which disk.  I solved the problem  by replacing

    GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`

with

    GRUB_DISTRIBUTOR=`cat /etc/hostname || lsb_release -i -s 2> /dev/null || echo Debian`

which worked well enough.

However, it seems to me that it would be a lot more useful to add a parameter allowing the user to display the name of the install from /etc/hostname.

Humphrey

--
We are but sheep and here to be fleeced

Dit bericht kan informatie bevatten die niet voor u is bestemd. Indien u niet de geadresseerde bent of dit bericht abusievelijk aan u is toegezonden, wordt u verzocht dat aan de afzender te melden en het bericht te verwijderen. De Staat aanvaardt geen aansprakelijkheid voor schade, van welke aard ook, die verband houdt met risico's verbonden aan het elektronisch verzenden van berichten.

This message may contain information that is not intended for you. If you are not the addressee or if this message was sent to you by mistake, you are requested to inform the sender and delete the message. The State accepts no liability for damage of any kind resulting from the risks inherent in the electronic transmission of messages.

[-- Attachment #2: Type: text/html, Size: 2860 bytes --]

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2021-01-24 13:06 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-24  0:52 need hostname on menu Humphrey van Polanen Petel
2021-01-24  0:57 ` John Paul Adrian Glaubitz
2021-01-24  3:32   ` Humphrey van Polanen Petel
2021-01-24  9:03     ` John Paul Adrian Glaubitz
2021-01-24 11:26       ` Humphrey van Polanen Petel
2021-01-24 11:38         ` John Paul Adrian Glaubitz
2021-01-24  9:28 ` Didier Spaier
2021-01-24  9:33   ` Didier Spaier
     [not found] <6ecee3f7-3b00-4fba-8320-5c65a2549da7@QAD40071.mod.nl>
2021-01-24  8:45 ` J.Witvliet
2021-01-24 13:06 J.Witvliet

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.