Re: [osinfo-db] rhel: Fix detection of RHEL-7.2 (x86_64) ISOs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Dec 22, 2016 at 02:13:24PM +0100, Fabiano Fidêncio wrote:
> When trying to install the free developer image[0] I've noticed that its
> volume-id[1] doesn't match the regular expression we have been using.
> Let's relax the expression, as already done for 7.0 and 7.1 for x86_64
> ISOs.

What happens is that strings in the ISO header are 32 bytes long, and
are padded with spaces (0x20), but nothing in on_pvd_read()/on_svd_read()
is removing these padding spaces from the string. So we will always be
getting
[SOME-ISO-LABEL                  ] from osinfo_media_get_volume_id()
rather than the expected [SOME-ISO-LABEL].
This explains why the $ anchor does not work here.
Imo it would be better to make sure we drop the extra spaces when
reading the ISO data.

Christophe

> 
> [0]: https://developers.redhat.com/products/rhel/get-started/#tab-kvm
> [1]:
>     CD-ROM is in ISO 9660 format
>     System id: LINUX
>     Volume id: RHEL-7.2 Server.x86_64
>     Volume set id:
>     Publisher id:
>     Data preparer id:
>     Application id: GENISOIMAGE ISO 9660/HFS FILESYSTEM CREATOR (C) 1993
>     E.YOUNGDALE (C) 1997-2006 J.PEARSON/J.SCHILLING (C) 2006-2007 CDRKIT
>     TEAM
>     Copyright File id:
>     Abstract File id:
>     Bibliographic File id:
>     Volume set size is: 1
>     Volume set sequence number is: 1
>     Logical block size is: 2048
>     Volume size is: 1973912
>     El Torito VD version 1 found, boot catalog is in sector 1139
>     Joliet with UCS level 3 found
>     Rock Ridge signatures version 1 found
>     Eltorito validation header:
>         Hid 1
>         Arch 0 (x86)
>         ID ''
>         Key 55 AA
>         Eltorito defaultboot header:
>             Bootid 88 (bootable)
>             Boot media 0 (No Emulation Boot)
>             Load segment 0
>             Sys type 0
>             Nsect 4
>             Bootoff 2D319 185113
> 
> Christophe noticed that the issue is not related only to the free
> developer image, but also happens with the "normal" RHEL-7.2 image.
> 
> Signed-off-by: Fabiano Fidêncio <fabiano@xxxxxxxxxxxx>
> Reported-by: Allan Day <aday@xxxxxxxxxx>
> ---
>  data/os/redhat.com/rhel-7.2.xml.in | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/data/os/redhat.com/rhel-7.2.xml.in b/data/os/redhat.com/rhel-7.2.xml.in
> index ab78cf8..7344341 100644
> --- a/data/os/redhat.com/rhel-7.2.xml.in
> +++ b/data/os/redhat.com/rhel-7.2.xml.in
> @@ -17,7 +17,7 @@
>      <media arch="x86_64">
>        <iso>
>          <system-id>LINUX</system-id>
> -        <volume-id>.*RHEL-7.2.*x86_64$</volume-id>
> +        <volume-id>.*RHEL-7.2.*x86_64.*</volume-id>
>        </iso>
>        <kernel>isolinux/vmlinuz</kernel>
>        <initrd>isolinux/initrd.img</initrd>
> -- 
> 2.9.3
> 
> _______________________________________________
> Libosinfo mailing list
> Libosinfo@xxxxxxxxxx
> https://www.redhat.com/mailman/listinfo/libosinfo

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Libosinfo mailing list
Libosinfo@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libosinfo

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Fedora Users]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux