RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1903219 - tzdata provided in image does not provide zoneinfo in ubi8-minimal
Summary: tzdata provided in image does not provide zoneinfo in ubi8-minimal
Keywords:
Status: CLOSED DUPLICATE of bug 1668185
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: ubi8-minimal-container
Version: 8.3
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: rc
: 8.0
Assignee: Jindrich Novy
QA Contact: Martin Jenner
URL:
Whiteboard:
Depends On:
Blocks: 1186913
TreeView+ depends on / blocked
 
Reported: 2020-12-01 16:30 UTC by Robb Manes
Modified: 2024-03-25 17:19 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-12-01 17:11:02 UTC
Type: Bug
Target Upstream Version:
Embargoed:
pm-rhel: mirror+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 5616681 0 None None None 2020-12-01 17:08:25 UTC

Description Robb Manes 2020-12-01 16:30:36 UTC
Description of problem:
In ubi8-minimal, as provided from registry.redhat.io, although the `tzdata` package is installed, /usr/share/zoneinfo provided by that package is not present.

$ podman run --name=test --rm registry.redhat.io/ubi8-minimal sh -c "rpm -q tzdata; ls -lattrh /usr/share/zoneinfo"
tzdata-2020d-1.el8.noarch
ls: cannot access '/usr/share/zoneinfo': No such file or directory

This must be stripped out of the build, as reinstalling it allows for the zoneinfo to be present:

$ podman run --name=test --rm registry.redhat.io/ubi8-minimal sh -c 'rpm -q tzdata; echo "Checking zoneinfo locations..."; ls -lattrh /usr/share/zoneinfo; echo "Reinstalling tzdata..."; microdnf reinstall tzdata -y; echo "Rechecking zoneinfo after reinstall..."; ls -lattrh /usr/share/zoneinfo | head'
tzdata-2020d-1.el8.noarch
Checking zoneinfo locations...
ls: cannot access '/usr/share/zoneinfo': No such file or directory
Reinstalling tzdata...

(microdnf:10): librhsm-WARNING **: 16:20:42.172: Found 0 entitlement certificates

(microdnf:10): librhsm-WARNING **: 16:20:42.174: Found 0 entitlement certificates
Downloading metadata...
Downloading metadata...
Downloading metadata...
Package                    Repository       Size
Reinstalling:
 tzdata-2020d-1.el8.noarch ubi-8-baseos 482.4 kB
Transaction Summary:
 Installing:        0 packages
 Reinstalling:      1 packages
 Upgrading:         0 packages
 Removing:          0 packages
 Downgrading:       0 packages
Downloading packages...
Running transaction test...
Reinstalling: tzdata;2020d-1.el8;noarch;ubi-8-baseos
Complete.
Rechecking zoneinfo after reinstall...
total 460K
-rw-r--r--.  1 root root 4.4K Feb 19  2019 iso3166.tab
-rw-r--r--.  1 root root  18K Mar 10  2020 zone1970.tab
-rw-r--r--.  1 root root  19K Mar 10  2020 zone.tab
-rw-r--r--.  1 root root 3.1K Jul  9 20:01 leapseconds
-rw-r--r--.  1 root root 110K Oct 21 20:10 tzdata.zi
-rw-r--r--.  3 root root 3.5K Oct 21 20:10 posixrules
-rw-r--r--.  8 root root  127 Oct 21 20:10 Zulu
-rw-r--r--.  1 root root 1.9K Oct 21 20:10 WET
-rw-r--r--.  2 root root 1.6K Oct 21 20:10 W-SU

Is this stripped out intentionally?  Seeing as the vast contents of the `tzdata` package are stored in /usr/share/zoneinfo, I do not suppose this was intentional.

Version-Release number of selected component (if applicable):
Tested with this version of ubi8-minimal:

$ skopeo inspect docker://registry.redhat.io/ubi8-minimal | jq '."Labels"'
{
  "architecture": "x86_64",
  "build-date": "2020-10-31T05:07:05.471303",
  "com.redhat.build-host": "cpt-1002.osbs.prod.upshift.rdu2.redhat.com",
  "com.redhat.component": "ubi8-minimal-container",
  "com.redhat.license_terms": "https://www.redhat.com/en/about/red-hat-end-user-license-agreements#UBI",
  "description": "The Universal Base Image Minimal is a stripped down image that uses microdnf as a package manager. This base image is freely redistributable, but Red Hat only supports Red Hat technologies through subscriptions for Red Hat products. This image is maintained by Red Hat and updated regularly.",
  "distribution-scope": "public",
  "io.k8s.description": "The Universal Base Image Minimal is a stripped down image that uses microdnf as a package manager. This base image is freely redistributable, but Red Hat only supports Red Hat technologies through subscriptions for Red Hat products. This image is maintained by Red Hat and updated regularly.",
  "io.k8s.display-name": "Red Hat Universal Base Image 8 Minimal",
  "io.openshift.expose-services": "",
  "io.openshift.tags": "minimal rhel8",
  "maintainer": "Red Hat, Inc.",
  "name": "ubi8-minimal",
  "release": "201",
  "summary": "Provides the latest release of the minimal Red Hat Universal Base Image 8.",
  "url": "https://access.redhat.com/containers/#/registry.access.redhat.com/ubi8-minimal/images/8.3-201",
  "vcs-ref": "f53dab37c7541dd0080f410727c5886e85c09ee7",
  "vcs-type": "git",
  "vendor": "Red Hat, Inc.",
  "version": "8.3"
}

How reproducible:
Every time.

Steps to Reproduce:
Provided above.

Actual results:
tzdata contains no /usr/share/zoneinfo only in ubi8-minimal images.

Expected results:
tzdata should contain zoneinfo data.

Additional info:
In my testing, this appears to affect every prior version of ubi8-minmal.

Comment 2 Robb Manes 2020-12-01 16:55:46 UTC
I've been told that this may be intentional; glibc requires tzdata, but we may intentionally remove /usr/share/zoneinfo as it is adds another ~2Mb to the image.  It may be expected that, if needing tzdata is required, you may need to as part of your build process reinstall tzdata.

Comment 3 Robb Manes 2020-12-01 17:11:02 UTC
Closed as a duplicate of bz1668185; this is intentional.  As a workaround if needed, as part of your build system implement something like `microdnf reinstall tzdata -y` to repopulate any tzdata that is needed.

*** This bug has been marked as a duplicate of bug 1668185 ***


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