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 1413887 - unused '<none>' images can't be removed
Summary: unused '<none>' images can't be removed
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: atomic
Version: 7.3
Hardware: x86_64
OS: Linux
high
high
Target Milestone: rc
: ---
Assignee: Lokesh Mandvekar
QA Contact: atomic-bugs@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-01-17 09:07 UTC by Alex Jia
Modified: 2020-05-05 14:32 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-05-05 14:32:42 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Alex Jia 2017-01-17 09:07:49 UTC
Description of problem:
Unused 'dangling' images can't be removed.

Version-Release number of selected component (if applicable):

[root@atomic-host-test-986 ~]# atomic host status
State: idle
Deployments:
● rhel-atomic-host-ostree:rhel-atomic-host/7/x86_64/standard
       Version: 7.3.2 (2017-01-13 22:00:41)
        Commit: 96826a0d917d7ff10f9fd0289581649f2ffbddd76f3b80efd3d95cc11915cacb
        OSName: rhel-atomic-host

[root@atomic-host-test-986 ~]# rpm -q atomic docker skopeo
atomic-1.14.1-5.el7.x86_64
docker-1.12.5-14.el7.x86_64
skopeo-0.1.17-1.el7.x86_64

[root@atomic-host-test-986 ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux Atomic Host release 7.3

How reproducible:
always

Steps to Reproduce:
1. make sure dangling images exist in your host
2. atomic images prune
3. atomic images delete <dangling_image>

Actual results:

# atomic images list -a
   REPOSITORY          TAG      IMAGE ID       CREATED            VIRTUAL SIZE   TYPE      
   docker.io/busybox   latest   7968321274dc   2017-01-13 22:13   1.11 MB        docker       
   <none>              <none>   e1dc8e08c83b   2017-01-13 05:36   371.87 MB      docker    
   <none>              <none>   aa12bb74b8f6   2017-01-13 05:34   197.1 MB       docker 

# atomic images prune
# atomic images list -a
   REPOSITORY          TAG      IMAGE ID       CREATED            VIRTUAL SIZE   TYPE      
   docker.io/busybox   latest   7968321274dc   2017-01-13 22:13   1.11 MB        docker       
   <none>              <none>   e1dc8e08c83b   2017-01-13 05:36   371.87 MB      docker    
   <none>              <none>   aa12bb74b8f6   2017-01-13 05:34   197.1 MB       docker 

# atomic images delete e1dc8e08c83b
list index out of range


Expected results:
fix it.

Additional info:

Comment 2 Brent Baude 2017-01-18 15:01:01 UTC
The exception should be fixed with https://github.com/projectatomic/atomic/pull/837


Just to be clear, a <none> <none> does not necessarily mean the image is dangling.  By our current definition, dangling images are preceeded with a * in atomic images list -a

Comment 3 Brent Baude 2017-02-27 16:10:24 UTC
Would you agree this is fixed?

Comment 4 Alex Jia 2017-02-28 14:37:09 UTC
(In reply to Brent Baude from comment #3)
> Would you agree this is fixed?

Yes, to document this should be enough.

Comment 5 Micah Abbott 2018-03-12 14:26:43 UTC
Alex, could you please close this if you think this is fixed?  Or comment if you think there is additional work that is necessary?

Comment 6 Alex Jia 2018-03-13 02:36:40 UTC
At present, a dangling container image can be removed by atomic images delete.

$ rpm -q atomic skopeo
atomic-1.21.1-1.git1170769.el7.x86_64
skopeo-0.1.28-1.git0270e56.el7.x86_64

$ sudo atomic images list -a | grep 57310166fe88
   <none>                                                                                <none>   57310166fe88   2018-02-01 17:18                  ostree    

$ sudo  atomic -y images delete 57310166fe88
The following images will be deleted.

   IMAGE          STORAGE
   57310166fe88   ostree

$ sudo  atomic images list -a | grep 57310166fe88
$


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