* Installer: GUIX_IMAGE as /dev/sda on some hardware?
@ 2019-05-25 9:04 Giovanni Biscuolo
2019-05-25 11:58 ` Tobias Geerinckx-Rice
0 siblings, 1 reply; 19+ messages in thread
From: Giovanni Biscuolo @ 2019-05-25 9:04 UTC (permalink / raw)
To: help-guix
[-- Attachment #1: Type: text/plain, Size: 1032 bytes --]
Hello Guix!
I cannot reproduce this anymore since the machine I used is no more
under my physical control and is in production... anyway
I'm sure on a HP ProLiant DL380p Gen8 the installer image (1.0.0
version) [1] listed the USB media as /dev/sda while I've always observed
(and reproducing now on a testing machine) that it's listed as **the
last** /dev/sd? device in the list
This is **very** important when installing grub, in fact grub
installation failed when instantiating my config.scm on the HP ProLiant
simply because it was on /dev/sda pointing to the USB media; I had to
manually install grub on /dev/sdb to complete the install
A couple of questions:
1. has anyone observed a similar issue?
2. what could have caused it?
3. how is the USB media "relocated" to the last /dev/sd? device by the
installer?
Happy hacking! Gio'.
[1] the only custom thing I made was adding "vga=791" and removing
"quiet" from the kernel arguments
--
Giovanni Biscuolo
Xelera IT Infrastructures
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-25 9:04 Installer: GUIX_IMAGE as /dev/sda on some hardware? Giovanni Biscuolo
@ 2019-05-25 11:58 ` Tobias Geerinckx-Rice
2019-05-25 13:16 ` Giovanni Biscuolo
0 siblings, 1 reply; 19+ messages in thread
From: Tobias Geerinckx-Rice @ 2019-05-25 11:58 UTC (permalink / raw)
To: help-guix
[-- Attachment #1: Type: text/plain, Size: 1787 bytes --]
Giovanni Biscuolo wrote:
> This is **very** important when installing grub, in fact grub
> installation failed when instantiating my config.scm on the HP
> ProLiant
> simply because it was on /dev/sda pointing to the USB media;
/dev/xdyN names have never been safe to use in this way, though.
I guess they're fine (at your own risk…) as short identifiers
during a single CLI session, but not across reboots. It just
often *happens* to work on most machines, which as we all know, is
the most dangerous kind of working.
> 3. how is the USB media "relocated" to the last /dev/sd? device
> by the
> installer?
It's… not? Dev nodes & names are doled out by the kernel. As
you've discovered, they aren't to be relied on, and you should use
labels or UUIDs instead.
Even if we'd pretend differently in the installer, for example
through artificially delayed probing for usb_storage devices,
things would still break when that lie would be exposed by adding
a new SATA drive, or when using a different (rescue) distro, or…
> 1. has anyone observed a similar issue?
>
> 2. what could have caused it?
I used to own a system that scanned drives in a different order
depending on whether or not a USB keyboard was attached. It was
intended as a headless system; great fun debugging that!
I once corrupted a drive (luckily part of a RAID-1 array, but it
was still stupid of me) because the rescue CD scanned drives in a
different order than the distro I was used to.
My first SATA motherboard enumerated drives differently between
cold and warm boots — but only sometimes. I think it had
something to do with spin-up times.
I could go on. I often do. Sorry.
Hoping to have scared you into using UUIDs,
T G-R
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-25 11:58 ` Tobias Geerinckx-Rice
@ 2019-05-25 13:16 ` Giovanni Biscuolo
2019-05-26 11:22 ` Tobias Geerinckx-Rice
` (3 more replies)
0 siblings, 4 replies; 19+ messages in thread
From: Giovanni Biscuolo @ 2019-05-25 13:16 UTC (permalink / raw)
To: Tobias Geerinckx-Rice, help-guix; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 2757 bytes --]
Hi Tobias,
thanks for sharing your experience, I'm cross posting to guix-devel
since it's worth discussing a patch to the installer
Tobias Geerinckx-Rice <me@tobias.gr> writes:
> Giovanni Biscuolo wrote:
>> This is **very** important when installing grub, in fact grub
>> installation failed when instantiating my config.scm on the HP
>> ProLiant
>> simply because it was on /dev/sda pointing to the USB media;
>
> /dev/xdyN names have never been safe to use in this way
I'm not talking about partitions ;-)
According my faulty memory (I cannot reproduce it now)
/dev/sd<something> is what the Installer writes in the bootloader
section of config.scm:
--8<---------------cut here---------------start------------->8---
(bootloader
(bootloader-configuration
(bootloader grub-bootloader)
(target "/dev/sda")
(keyboard-layout keyboard-layout)))
--8<---------------cut here---------------end--------------->8---
and that caused the Installer to fail on grub-install since /dev/sda was
my USB media, (fortunately it failed because there was no space for grub
:-) )
On the other hand, by setting "/dev/sdb" whould made grub-install
succeed when running from USB but fail when running from the system
itself
[...]
>> 3. how is the USB media "relocated" to the last /dev/sd? device
>> by the installer?
>
> It's… not?
So it's pure coincidence that grub-install on /dev/sda succeedes on the
whole set of machines users are installing via USB media? :-O
> Dev nodes & names are doled out by the kernel. As
> you've discovered, they aren't to be relied on, and you should use
> labels or UUIDs instead.
Labels and UUIDs are for volumes, not for the whole disk ;-)
I'm not talking about filesystem config, where using labels or UUIDS is
strongly recommended (and used by the Installer), I'm talking about
grub-install config
But wait! There's the /dev/disk/by-id/ tree, I did not notice it until
now! :-)
That's the solution:
--8<---------------cut here---------------start------------->8---
(bootloader
(bootloader-configuration
(bootloader grub-bootloader)
(target "/dev/disk/by-id/scsi-3600508b1001c75a3bebb04b23d19e249")
(keyboard-layout keyboard-layout)))
--8<---------------cut here---------------end--------------->8---
I did not test this but it smells like running, if Guix devels agree I
think Installer should adopt /dev/disk/by-id by default, sorry I'm not
able to propose a patch for this
[...]
> Hoping to have scared you into using UUIDs,
Yes! You did it (albeit it is disk/by-id and not UUIDs) :-D
Thanks for your suggestions! Gio'.
--
Giovanni Biscuolo
Xelera IT Infrastructures
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-25 13:16 ` Giovanni Biscuolo
@ 2019-05-26 11:22 ` Tobias Geerinckx-Rice
2019-05-26 11:31 ` Tobias Geerinckx-Rice
` (2 subsequent siblings)
3 siblings, 0 replies; 19+ messages in thread
From: Tobias Geerinckx-Rice @ 2019-05-26 11:22 UTC (permalink / raw)
To: Giovanni Biscuolo; +Cc: guix-devel, help-guix
[-- Attachment #1: Type: text/plain, Size: 1598 bytes --]
Giovanni,
Giovanni Biscuolo wrote:
>> /dev/xdyN names have never been safe to use in this way
>
> I'm not talking about partitions ;-)
Neither was I. Force o' habit. May your partitions never be in
random order.
> According my faulty memory (I cannot reproduce it now)
> /dev/sd<something> is what the Installer writes in the
> bootloader
> section of config.scm:
>
> --8<---------------cut
> here---------------start------------->8---
>
> (bootloader
> (bootloader-configuration
> (bootloader grub-bootloader)
> (target "/dev/sda")
> (keyboard-layout keyboard-layout)))
>
I didn't realise that our *installer* did this… It shouldn't.
Thanks for noting this.
> So it's pure coincidence that grub-install on /dev/sda succeedes
> on the
> whole set of machines users are installing via USB media? :-O
‘Pure coincidence’ is too loaded. It almost always works! But
your original question already illustrates how ‘almost always
works’ leads to false inductions of ‘should work’.
The odds may be hugely in your favour, but why gamble at all?
>> you've discovered, they aren't to be relied on, and you should
>> use
>> labels or UUIDs instead.
>
> Labels and UUIDs are for volumes, not for the whole disk ;-)
…? I must not be using the right terminology, but each drive has
a ‘unique identifier’, and a human-readable label (if that human
likes numbers, a lot) that isn't unique.
‘ID’ & ‘name’, then, fine, whatever we call it, my point remains
:-P
Kind regards,
T G-R
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-25 13:16 ` Giovanni Biscuolo
2019-05-26 11:22 ` Tobias Geerinckx-Rice
@ 2019-05-26 11:31 ` Tobias Geerinckx-Rice
2019-05-26 21:26 ` Tobias Geerinckx-Rice
2019-05-28 15:11 ` Ludovic Courtès
3 siblings, 0 replies; 19+ messages in thread
From: Tobias Geerinckx-Rice @ 2019-05-26 11:31 UTC (permalink / raw)
To: Giovanni Biscuolo; +Cc: guix-devel, help-guix
[-- Attachment #1: Type: text/plain, Size: 335 bytes --]
[Part two, having made my train connection with 8 seconds to
spare.]
Giovanni Biscuolo wrote:
> But wait! There's the /dev/disk/by-id/ tree, I did not notice it
> until
> now! :-)
Yes! That's what I meant! Thank you. I'll be sure to use the
udev terminology for this in future, it's confusing enough as it
is.
Thanks,
T G-R
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-25 13:16 ` Giovanni Biscuolo
2019-05-26 11:22 ` Tobias Geerinckx-Rice
2019-05-26 11:31 ` Tobias Geerinckx-Rice
@ 2019-05-26 21:26 ` Tobias Geerinckx-Rice
2019-05-28 15:11 ` Ludovic Courtès
3 siblings, 0 replies; 19+ messages in thread
From: Tobias Geerinckx-Rice @ 2019-05-26 21:26 UTC (permalink / raw)
To: guix-devel
[-- Attachment #1: Type: text/plain, Size: 514 bytes --]
Giovanni Biscuolo wrote:
> I did not test this but it smells like running, if Guix devels
> agree I
> think Installer should adopt /dev/disk/by-id by default, sorry
> I'm not
> able to propose a patch for this
I've written a patch to make this work:
(bootloader
(bootloader-configuration
(bootloader grub-bootloader)
(target
"/dev/disk/by-id/ata-QEMU_HARDDISK_QM00001")
…
…now to rewrite so it stands a chance of being merged :-)
Kind regards,
T G-R
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-25 13:16 ` Giovanni Biscuolo
` (2 preceding siblings ...)
2019-05-26 21:26 ` Tobias Geerinckx-Rice
@ 2019-05-28 15:11 ` Ludovic Courtès
2019-05-28 17:29 ` Tobias Geerinckx-Rice
2019-05-29 19:16 ` bug#35995: [wishlist] bootloader-configuration, avoid use of /dev/sd? Giovanni Biscuolo
3 siblings, 2 replies; 19+ messages in thread
From: Ludovic Courtès @ 2019-05-28 15:11 UTC (permalink / raw)
To: Giovanni Biscuolo; +Cc: guix-devel, help-guix
Hello!
Giovanni Biscuolo <g@xelera.eu> skribis:
> But wait! There's the /dev/disk/by-id/ tree, I did not notice it until
> now! :-)
>
> That's the solution:
>
>
> (bootloader
> (bootloader-configuration
> (bootloader grub-bootloader)
> (target "/dev/disk/by-id/scsi-3600508b1001c75a3bebb04b23d19e249")
> (keyboard-layout keyboard-layout)))
>
> I did not test this but it smells like running, if Guix devels agree I
> think Installer should adopt /dev/disk/by-id by default, sorry I'm not
> able to propose a patch for this
Ideally, we’d use an actual UUID object (or a string?) here rather than
this Linux/udev-specific idiom. So it would look like:
(bootloader-configuration
;; …
(target (uuid …)))
Would that work?
I believe using Guile-Parted we could map it back to a /dev name.
WDYT?
Ludo’.
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-28 15:11 ` Ludovic Courtès
@ 2019-05-28 17:29 ` Tobias Geerinckx-Rice
2019-05-29 19:49 ` bug#35995: " Giovanni Biscuolo
2019-05-29 19:49 ` Giovanni Biscuolo
2019-05-29 19:16 ` bug#35995: [wishlist] bootloader-configuration, avoid use of /dev/sd? Giovanni Biscuolo
1 sibling, 2 replies; 19+ messages in thread
From: Tobias Geerinckx-Rice @ 2019-05-28 17:29 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 779 bytes --]
[De-CC'ing help-guix again.]
Ludo'!
Ludovic Courtès wrote:
> Ideally, we’d use an actual UUID object (or a string?) here
> rather than
> this Linux/udev-specific idiom. […]
> I believe using Guile-Parted we could map it back to a /dev
> name.
Yah, 's one of the reasons that I haven't sent anything yet (the
main one being shame, of course; car/cdr for the win & all that).
> Would that work?
I'd looked in Guile-parted before but came up dry. To be fair I
did little more than grep around for ‘uid’ and friends. So you
tell me ;-)
…
Hum, wait a minute. Isn't that irrelevant? Doesn't Guix itself
do exactly this when mounting file systems? Sigh, silly me, I
should be able to re-use that… >_<
Kind regards,
T G-R
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* bug#35995: [wishlist] bootloader-configuration, avoid use of /dev/sd?
2019-05-28 15:11 ` Ludovic Courtès
2019-05-28 17:29 ` Tobias Geerinckx-Rice
@ 2019-05-29 19:16 ` Giovanni Biscuolo
[not found] ` <handler.35995.B.155915741432036.ack@debbugs.gnu.org>
1 sibling, 1 reply; 19+ messages in thread
From: Giovanni Biscuolo @ 2019-05-29 19:16 UTC (permalink / raw)
To: 35995
[-- Attachment #1: Type: text/plain, Size: 1705 bytes --]
Hello,
Following a recent discussion on Guix-devel [1] I'm "forwarding here" a
proposal to switch from /dev/sd? to (target (uuid ...)) in
bootloader-configuration operating-system declaration
This is a recap of current situation: the installer usually uses
/dev/sda as target for grub-install (and bootloader-cofiguration) but it
happened to me that on a machine /dev/sda was the USB media, not the
target HD
The fact is that it's not guaranteed that /dev/sd? always corresponds to
the same device
This is where we are with the discussion:
Ludovic Courtès <ludo@gnu.org> writes:
> Hello!
>
> Giovanni Biscuolo <g@xelera.eu> skribis:
>
>> But wait! There's the /dev/disk/by-id/ tree, I did not notice it until
>> now! :-)
>>
>> That's the solution:
>>
>>
>> (bootloader
>> (bootloader-configuration
>> (bootloader grub-bootloader)
>> (target "/dev/disk/by-id/scsi-3600508b1001c75a3bebb04b23d19e249")
>> (keyboard-layout keyboard-layout)))
>>
>> I did not test this but it smells like running, if Guix devels agree I
>> think Installer should adopt /dev/disk/by-id by default, sorry I'm not
>> able to propose a patch for this
>
> Ideally, we’d use an actual UUID object (or a string?) here rather than
> this Linux/udev-specific idiom. So it would look like:
>
> (bootloader-configuration
> ;; …
> (target (uuid …)))
>
> Would that work?
>
> I believe using Guile-Parted we could map it back to a /dev name.
>
> WDYT?
>
> Ludo’.
[1] Message-ID: <87o93mwr4b.fsf@gnu.org>
http://lists.gnu.org/archive/html/guix-devel/2019-05/msg00454.html
--
Giovanni Biscuolo
Xelera IT Infrastructures
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* bug#35995: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-28 17:29 ` Tobias Geerinckx-Rice
@ 2019-05-29 19:49 ` Giovanni Biscuolo
2019-05-29 19:49 ` Giovanni Biscuolo
1 sibling, 0 replies; 19+ messages in thread
From: Giovanni Biscuolo @ 2019-05-29 19:49 UTC (permalink / raw)
To: 35995, Tobias Geerinckx-Rice, Ludovic Courtès; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 2301 bytes --]
Hello Tobias and Ludo'
I've opened a bug report for this, WDYT if we go on there?
Tobias Geerinckx-Rice <me@tobias.gr> writes:
> Ludovic Courtès wrote:
>> Ideally, we’d use an actual UUID object (or a string?) here
>> rather than
>> this Linux/udev-specific idiom. […]
>> I believe using Guile-Parted we could map it back to a /dev
>> name.
>
> Yah, 's one of the reasons that I haven't sent anything yet (the
> main one being shame, of course; car/cdr for the win & all that).
>
>> Would that work?
>
> I'd looked in Guile-parted before but came up dry. To be fair I
> did little more than grep around for ‘uid’ and friends. So you
> tell me ;-)
>
> …
>
> Hum, wait a minute. Isn't that irrelevant? Doesn't Guix itself
> do exactly this when mounting file systems? Sigh, silly me, I
> should be able to re-use that… >_<
Grub supports quite a number of ways to specify devices [1] but I cannot
find something suitable for this purpose: am I missimg something
obvious?
AFAIU on ther distros (e.g. Debian) (the installer?) populates a device
map [2] using the grub-mkdevicemap utility (grub-common package in
Debian) but I cannot find that in our grub package
This is an example on one of my Debian hosts:
--8<---------------cut here---------------start------------->8---
$ cat /boot/grub/device.map
(hd0) /dev/disk/by-id/ata-WDC_WD10EADS-00L5B1_WD-WCAU4D992691
(hd1) /dev/disk/by-id/ata-ST3250620NS_9QE2L68Z
(hd2) /dev/disk/by-id/ata-ST3250620NS_9QE2FSQD
(hd3) /dev/disk/by-id/ata-ST3250620NS_9QE27YPJ
(hd4) /dev/disk/by-id/ata-WDC_WD7500BPKT-00PK4T0_WD-WX11A4181554
(hd5) /dev/disk/by-id/ata-WDC_WD7500BPKT-00PK4T0_WD-WXM1A61D0766
--8<---------------cut here---------------end--------------->8---
(the map is not updated)
We could use (hd?) in grub config - that's grub specific, not Linux/udev
specific - **but** we should find a way to automate the selection of the
device corresponding to our target (the one mounted as /mnt)
Thanks for working on this!!!
Happy hacking. Gio'.
[1] https://www.gnu.org/software/grub/manual/grub/html_node/Device-syntax.html
[2] https://www.gnu.org/software/grub/manual/grub/html_node/Device-map.html
--
Giovanni Biscuolo
Xelera IT Infrastructures
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-28 17:29 ` Tobias Geerinckx-Rice
2019-05-29 19:49 ` bug#35995: " Giovanni Biscuolo
@ 2019-05-29 19:49 ` Giovanni Biscuolo
2019-05-29 20:19 ` bug#35995: " Danny Milosavljevic
1 sibling, 1 reply; 19+ messages in thread
From: Giovanni Biscuolo @ 2019-05-29 19:49 UTC (permalink / raw)
To: 35995, Tobias Geerinckx-Rice, Ludovic Courtès; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 2301 bytes --]
Hello Tobias and Ludo'
I've opened a bug report for this, WDYT if we go on there?
Tobias Geerinckx-Rice <me@tobias.gr> writes:
> Ludovic Courtès wrote:
>> Ideally, we’d use an actual UUID object (or a string?) here
>> rather than
>> this Linux/udev-specific idiom. […]
>> I believe using Guile-Parted we could map it back to a /dev
>> name.
>
> Yah, 's one of the reasons that I haven't sent anything yet (the
> main one being shame, of course; car/cdr for the win & all that).
>
>> Would that work?
>
> I'd looked in Guile-parted before but came up dry. To be fair I
> did little more than grep around for ‘uid’ and friends. So you
> tell me ;-)
>
> …
>
> Hum, wait a minute. Isn't that irrelevant? Doesn't Guix itself
> do exactly this when mounting file systems? Sigh, silly me, I
> should be able to re-use that… >_<
Grub supports quite a number of ways to specify devices [1] but I cannot
find something suitable for this purpose: am I missimg something
obvious?
AFAIU on ther distros (e.g. Debian) (the installer?) populates a device
map [2] using the grub-mkdevicemap utility (grub-common package in
Debian) but I cannot find that in our grub package
This is an example on one of my Debian hosts:
--8<---------------cut here---------------start------------->8---
$ cat /boot/grub/device.map
(hd0) /dev/disk/by-id/ata-WDC_WD10EADS-00L5B1_WD-WCAU4D992691
(hd1) /dev/disk/by-id/ata-ST3250620NS_9QE2L68Z
(hd2) /dev/disk/by-id/ata-ST3250620NS_9QE2FSQD
(hd3) /dev/disk/by-id/ata-ST3250620NS_9QE27YPJ
(hd4) /dev/disk/by-id/ata-WDC_WD7500BPKT-00PK4T0_WD-WX11A4181554
(hd5) /dev/disk/by-id/ata-WDC_WD7500BPKT-00PK4T0_WD-WXM1A61D0766
--8<---------------cut here---------------end--------------->8---
(the map is not updated)
We could use (hd?) in grub config - that's grub specific, not Linux/udev
specific - **but** we should find a way to automate the selection of the
device corresponding to our target (the one mounted as /mnt)
Thanks for working on this!!!
Happy hacking. Gio'.
[1] https://www.gnu.org/software/grub/manual/grub/html_node/Device-syntax.html
[2] https://www.gnu.org/software/grub/manual/grub/html_node/Device-map.html
--
Giovanni Biscuolo
Xelera IT Infrastructures
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* bug#35995: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-29 19:49 ` Giovanni Biscuolo
@ 2019-05-29 20:19 ` Danny Milosavljevic
2019-05-31 21:42 ` Ludovic Courtès
2019-05-31 21:42 ` Ludovic Courtès
0 siblings, 2 replies; 19+ messages in thread
From: Danny Milosavljevic @ 2019-05-29 20:19 UTC (permalink / raw)
To: Giovanni Biscuolo, 35995; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 687 bytes --]
Grub already can search by uuid or label (via "search --fsuuid" and
"search --label", respectively). IF you specify an uuid or label
in your operating-system configuration it will use that.
The only part missing is: The Guix installer's config generator should
find out the uuids and print those instead of the /dev nodes.
If nothing else, we can just use blkid to find out which is which.
For example: blkid -d -s UUID -o value /dev/sda1
But T G-R is right, Guix already does what is required at other places.
Care has to be taken that parted also uses GUIDs for GPT partition TYPES
and also for partitions as such (not their contents). Those are something
else.
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* bug#35995: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-29 20:19 ` bug#35995: " Danny Milosavljevic
2019-05-31 21:42 ` Ludovic Courtès
@ 2019-05-31 21:42 ` Ludovic Courtès
1 sibling, 0 replies; 19+ messages in thread
From: Ludovic Courtès @ 2019-05-31 21:42 UTC (permalink / raw)
To: Danny Milosavljevic; +Cc: 35995, guix-devel
Hi Danny,
Danny Milosavljevic <dannym@scratchpost.org> skribis:
> Grub already can search by uuid or label (via "search --fsuuid" and
> "search --label", respectively). IF you specify an uuid or label
> in your operating-system configuration it will use that.
These are concerned with file system UUIDs/labels, whereas this issue is
about disk IDs, AIUI. Or am I missing something?
Ludo’.
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-29 20:19 ` bug#35995: " Danny Milosavljevic
@ 2019-05-31 21:42 ` Ludovic Courtès
2019-05-31 22:16 ` Tobias Geerinckx-Rice
2019-05-31 22:16 ` bug#35995: " Tobias Geerinckx-Rice
2019-05-31 21:42 ` Ludovic Courtès
1 sibling, 2 replies; 19+ messages in thread
From: Ludovic Courtès @ 2019-05-31 21:42 UTC (permalink / raw)
To: Danny Milosavljevic; +Cc: 35995, guix-devel
Hi Danny,
Danny Milosavljevic <dannym@scratchpost.org> skribis:
> Grub already can search by uuid or label (via "search --fsuuid" and
> "search --label", respectively). IF you specify an uuid or label
> in your operating-system configuration it will use that.
These are concerned with file system UUIDs/labels, whereas this issue is
about disk IDs, AIUI. Or am I missing something?
Ludo’.
^ permalink raw reply [flat|nested] 19+ messages in thread
* bug#35995: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-31 21:42 ` Ludovic Courtès
2019-05-31 22:16 ` Tobias Geerinckx-Rice
@ 2019-05-31 22:16 ` Tobias Geerinckx-Rice
1 sibling, 0 replies; 19+ messages in thread
From: Tobias Geerinckx-Rice @ 2019-05-31 22:16 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 35995, guix-devel
[-- Attachment #1: Type: text/plain, Size: 669 bytes --]
Ludovic Courtès wrote:
> Danny Milosavljevic <dannym@scratchpost.org> skribis:
>> Grub already can search by uuid or label (via "search --fsuuid"
>> and
>> "search --label", respectively). IF you specify an uuid or
>> label
>> in your operating-system configuration it will use that.
>
> These are concerned with file system UUIDs/labels, whereas this
> issue is
> about disk IDs, AIUI. Or am I missing something?
This. Also, this only affects grub-install—not ‘grub
run-time’—which runs under the Hurd/Linux/…, unless I, too, am
missing something, and this entire thread collapses in a cacophony
of confusion.
G'night,
T G-R
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-31 21:42 ` Ludovic Courtès
@ 2019-05-31 22:16 ` Tobias Geerinckx-Rice
2019-05-31 23:31 ` bug#35995: " Danny Milosavljevic
2019-05-31 23:31 ` Danny Milosavljevic
2019-05-31 22:16 ` bug#35995: " Tobias Geerinckx-Rice
1 sibling, 2 replies; 19+ messages in thread
From: Tobias Geerinckx-Rice @ 2019-05-31 22:16 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 35995, guix-devel
[-- Attachment #1: Type: text/plain, Size: 669 bytes --]
Ludovic Courtès wrote:
> Danny Milosavljevic <dannym@scratchpost.org> skribis:
>> Grub already can search by uuid or label (via "search --fsuuid"
>> and
>> "search --label", respectively). IF you specify an uuid or
>> label
>> in your operating-system configuration it will use that.
>
> These are concerned with file system UUIDs/labels, whereas this
> issue is
> about disk IDs, AIUI. Or am I missing something?
This. Also, this only affects grub-install—not ‘grub
run-time’—which runs under the Hurd/Linux/…, unless I, too, am
missing something, and this entire thread collapses in a cacophony
of confusion.
G'night,
T G-R
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* bug#35995: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-31 22:16 ` Tobias Geerinckx-Rice
@ 2019-05-31 23:31 ` Danny Milosavljevic
2019-05-31 23:31 ` Danny Milosavljevic
1 sibling, 0 replies; 19+ messages in thread
From: Danny Milosavljevic @ 2019-05-31 23:31 UTC (permalink / raw)
To: Tobias Geerinckx-Rice; +Cc: 35995, guix-devel
[-- Attachment #1: Type: text/plain, Size: 747 bytes --]
Yeah, but disk ids are not uuids.
/dev/disk/by-id seems to be a good way to find those disk ids in order to pass
them to grub-install. I doubt that this can be made OS-independent--even the
udev rules specify different variables for different devices, sometimes it's
bus id and serial number, sometimes it's name and serial number, sometimes it's
ieee1394_id, sometimes ID_WWN_WITH_EXTENSION.
Alternatively, grub also works from a boot-active partition--it nothing else
works, we can install grub to a partition (for example the root partition).
Then, migration would be difficult, though (if people had grub installed on
the MBR, that destroyed the previous loader that would have loaded from the
boot sector of the partition).
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Installer: GUIX_IMAGE as /dev/sda on some hardware?
2019-05-31 22:16 ` Tobias Geerinckx-Rice
2019-05-31 23:31 ` bug#35995: " Danny Milosavljevic
@ 2019-05-31 23:31 ` Danny Milosavljevic
1 sibling, 0 replies; 19+ messages in thread
From: Danny Milosavljevic @ 2019-05-31 23:31 UTC (permalink / raw)
To: Tobias Geerinckx-Rice; +Cc: 35995, guix-devel
[-- Attachment #1: Type: text/plain, Size: 747 bytes --]
Yeah, but disk ids are not uuids.
/dev/disk/by-id seems to be a good way to find those disk ids in order to pass
them to grub-install. I doubt that this can be made OS-independent--even the
udev rules specify different variables for different devices, sometimes it's
bus id and serial number, sometimes it's name and serial number, sometimes it's
ieee1394_id, sometimes ID_WWN_WITH_EXTENSION.
Alternatively, grub also works from a boot-active partition--it nothing else
works, we can install grub to a partition (for example the root partition).
Then, migration would be difficult, though (if people had grub installed on
the MBR, that destroyed the previous loader that would have loaded from the
boot sector of the partition).
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
* bug#35995: [wishlist] bootloader-configuration, avoid use of /dev/sd?
[not found] ` <handler.35995.B.155915741432036.ack@debbugs.gnu.org>
@ 2024-02-28 9:29 ` Giovanni Biscuolo
0 siblings, 0 replies; 19+ messages in thread
From: Giovanni Biscuolo @ 2024-02-28 9:29 UTC (permalink / raw)
To: 35995-done
[-- Attachment #1: Type: text/plain, Size: 198 bytes --]
Hello,
I think this bug has been fixed in bug #51878:
Pushed as b90504cdb5ce3d1981c8d7bc8a9cc918b0d60af7 (26 Nov 2021).
Closing! :-)
--
Giovanni Biscuolo
Xelera IT Infrastructures
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 849 bytes --]
^ permalink raw reply [flat|nested] 19+ messages in thread
end of thread, other threads:[~2024-02-28 9:56 UTC | newest]
Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-05-25 9:04 Installer: GUIX_IMAGE as /dev/sda on some hardware? Giovanni Biscuolo
2019-05-25 11:58 ` Tobias Geerinckx-Rice
2019-05-25 13:16 ` Giovanni Biscuolo
2019-05-26 11:22 ` Tobias Geerinckx-Rice
2019-05-26 11:31 ` Tobias Geerinckx-Rice
2019-05-26 21:26 ` Tobias Geerinckx-Rice
2019-05-28 15:11 ` Ludovic Courtès
2019-05-28 17:29 ` Tobias Geerinckx-Rice
2019-05-29 19:49 ` bug#35995: " Giovanni Biscuolo
2019-05-29 19:49 ` Giovanni Biscuolo
2019-05-29 20:19 ` bug#35995: " Danny Milosavljevic
2019-05-31 21:42 ` Ludovic Courtès
2019-05-31 22:16 ` Tobias Geerinckx-Rice
2019-05-31 23:31 ` bug#35995: " Danny Milosavljevic
2019-05-31 23:31 ` Danny Milosavljevic
2019-05-31 22:16 ` bug#35995: " Tobias Geerinckx-Rice
2019-05-31 21:42 ` Ludovic Courtès
2019-05-29 19:16 ` bug#35995: [wishlist] bootloader-configuration, avoid use of /dev/sd? Giovanni Biscuolo
[not found] ` <handler.35995.B.155915741432036.ack@debbugs.gnu.org>
2024-02-28 9:29 ` Giovanni Biscuolo
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
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.