Bug 1919879 - The toolbox container name is changed from 'toolbox-root' to 'toolbox-' in a chroot environment
Summary: The toolbox container name is changed from 'toolbox-root' to 'toolbox-' in a...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: RHCOS
Version: 4.7
Hardware: All
OS: Linux
low
low
Target Milestone: ---
: 4.7.0
Assignee: Timothée Ravier
QA Contact: Michael Nguyen
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-01-25 11:05 UTC by Timothée Ravier
Modified: 2021-02-24 15:56 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-02-24 15:55:50 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2020:5633 0 None None None 2021-02-24 15:56:05 UTC

Description Timothée Ravier 2021-01-25 11:05:23 UTC
This bug was initially created as a copy of Bug #1868223

I am copying this bug because: 

This is the bug for the coreos/toolbox package and not for the containers/toolbox one.


Description of problem:
The toolbox container name is changed from toolbox-root to toolbox- in a chroot environment, the name 'toolbox-' is not very friendly for users.

For details, please also see https://bugzilla.redhat.com/show_bug.cgi?id=1850230#c21

Version-Release number of selected component (if applicable):
toolbox-0.0.8-1.module+el8.3.0+7627+c01ededd.noarch

How reproducible:
always

Steps to Reproduce:
1. oc debug node/<node_name>
2. chroot /host
3. toolbox

Actual results:
sh-4.4# toolbox
Spawning a container 'toolbox-' with image '...'
[root@toolbox /]# ls
bin  boot  dev  etc  home  host  lib  lib64  lost+found  media  mnt  opt  proc  root  run  sbin  srv  sys  tmp  usr  var

Expected results:
fix container naming.

Comment 1 Timothée Ravier 2021-01-25 11:07:58 UTC
Fixed by https://src.osci.redhat.com/rpms/toolbox/pull-request/9

Comment 3 Michael Nguyen 2021-01-25 21:48:46 UTC
Verified on 4.7.0-0.nightly-2021-01-25-160335. 

$ oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.7.0-0.nightly-2021-01-25-160335   True        False         20m     Cluster version is 4.7.0-0.nightly-2021-01-25-160335

$ oc get nodes
NAME                                         STATUS   ROLES    AGE   VERSION
ip-10-0-140-103.us-west-2.compute.internal   Ready    master   46m   v1.20.0+70dd98e
ip-10-0-154-51.us-west-2.compute.internal    Ready    worker   33m   v1.20.0+70dd98e
ip-10-0-170-124.us-west-2.compute.internal   Ready    worker   34m   v1.20.0+70dd98e
ip-10-0-173-237.us-west-2.compute.internal   Ready    master   45m   v1.20.0+70dd98e
ip-10-0-196-185.us-west-2.compute.internal   Ready    master   46m   v1.20.0+70dd98e
ip-10-0-220-32.us-west-2.compute.internal    Ready    worker   33m   v1.20.0+70dd98e
$ oc debug node/ip-10-0-154-51.us-west-2.compute.internal
Starting pod/ip-10-0-154-51us-west-2computeinternal-debug ...
To use host binaries, run `chroot /host`
If you don't see a command prompt, try pressing enter.
sh-4.2# chroot /host
sh-4.4# toolbox
Trying to pull registry.redhat.io/rhel8/support-tools...
Getting image source signatures
Copying blob d9e72d058dc5 skipped: already exists  
Copying blob cca21acb641a skipped: already exists  
Copying blob 5ee83610639d done  
Copying config be1f7079a9 done  
Writing manifest to image destination
Storing signatures
be1f7079a938a4ab5c1f8b4c7d2dc82b8c60598bb1e248438ced576829f96389
Spawning a container 'toolbox-root' with image 'registry.redhat.io/rhel8/support-tools'
Detected RUN label in the container image. Using that as the default...
[root@ip-10-0-154-51 /]# exit
exit
sh-4.4# podman ps -a
CONTAINER ID  IMAGE                                          COMMAND        CREATED         STATUS                     PORTS   NAMES
71d83cf8ddcf  registry.redhat.io/rhel8/support-tools:latest  /usr/bin/bash  21 seconds ago  Exited (0) 15 seconds ago          toolbox-root
sh-4.4# rpm-ostree status
State: idle
Deployments:
* pivot://quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:e52aead8f8025eb8fe12a385a826a822fa94f9dc89e8d55abcc2bbf718f4b11f
              CustomOrigin: Managed by machine-config-operator
                   Version: 47.83.202101251242-0 (2021-01-25T12:46:04Z)

  ostree://8e87a86b9444784ab29e7917fa82e00d5e356f18b19449946b687ee8dc27c51a
                   Version: 47.83.202101161239-0 (2021-01-16T12:43:01Z)
sh-4.4# exit
exit
sh-4.2# exit
exit

Removing debug pod ...
$ oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.7.0-0.nightly-2021-01-25-160335   True        False         20m     Cluster version is 4.7.0-0.nightly-2021-01-25-160335

Comment 7 errata-xmlrpc 2021-02-24 15:55:50 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Container Platform 4.7.0 security, bug fix, and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2020:5633


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