Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1755346

Summary: Uploading images to undercloud warning
Product: Red Hat OpenStack Reporter: Edu Alcaniz <ealcaniz>
Component: python-tripleoclientAssignee: Rabi Mishra <ramishra>
Status: CLOSED ERRATA QA Contact: Sasha Smolyak <ssmolyak>
Severity: medium Docs Contact:
Priority: medium    
Version: 15.0 (Stein)CC: ealcaniz, emacchi, hbrock, jslagle, mburns, ramishra, sandyada
Target Milestone: zstreamKeywords: Triaged, ZStream
Target Release: 15.0 (Stein)   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: python-tripleoclient-11.5.1-1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-03-05 12:00:13 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Edu Alcaniz 2019-09-25 09:51:20 UTC
Description of problem:
Deploying OSP15 images gaves some warnings:

/usr/lib/python3.6/site-packages/tripleoclient/v1/overcloud_image.py:496: ResourceWarning: unclosed file <_io.BufferedReader name='/home/stack/images/ironic-python-agent.initramfs'>
  deploy_ramdisk_file))
sys:1: ResourceWarning: unclosed <ssl.SSLSocket fd=7, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=('172.19.1.3', 56488), raddr=('172.19.1.3', 13292)>
sys:1: ResourceWarning: unclosed <ssl.SSLSocket fd=4, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=('172.19.1.3', 58992), raddr=('172.19.1.3', 13000)>



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

How reproducible:
(undercloud) [stack@undercloud15 images]$ openstack overcloud image upload --image-path /home/stack/images/
Image "overcloud-full-vmlinuz" was uploaded.
+--------------------------------------+------------------------+-------------+---------+--------+
|                  ID                  |          Name          | Disk Format |   Size  | Status |
+--------------------------------------+------------------------+-------------+---------+--------+
| 92175186-268c-475e-a5db-3e02b66cd238 | overcloud-full-vmlinuz |     aki     | 7876960 | active |
+--------------------------------------+------------------------+-------------+---------+--------+
openstack image listImage "overcloud-full-initrd" was uploaded.
+--------------------------------------+-----------------------+-------------+----------+--------+
|                  ID                  |          Name         | Disk Format |   Size   | Status |
+--------------------------------------+-----------------------+-------------+----------+--------+
| 3831d3b6-7fba-450b-897b-7cf2254be6e9 | overcloud-full-initrd |     ari     | 64571098 | active |
+--------------------------------------+-----------------------+-------------+----------+--------+

ls -l /var/lib/ironic/httpboot
Image "overcloud-full" was uploaded.
+--------------------------------------+----------------+-------------+-----------+--------+
|                  ID                  |      Name      | Disk Format |    Size   | Status |
+--------------------------------------+----------------+-------------+-----------+--------+
| 96b4a757-6f1e-468b-a880-5edeae70a107 | overcloud-full |    qcow2    | 969670656 | active |
+--------------------------------------+----------------+-------------+-----------+--------+
Image "bm-deploy-kernel" was uploaded.
+--------------------------------------+------------------+-------------+---------+--------+
|                  ID                  |       Name       | Disk Format |   Size  | Status |
+--------------------------------------+------------------+-------------+---------+--------+
| 8f90fcec-98e6-4e12-b718-39aaf0100106 | bm-deploy-kernel |     aki     | 7876960 | active |
+--------------------------------------+------------------+-------------+---------+--------+
/usr/lib/python3.6/site-packages/tripleoclient/v1/overcloud_image.py:480: ResourceWarning: unclosed file <_io.BufferedReader name='/home/stack/images/ironic-python-agent.kernel'>
  deploy_kernel_file))
Image "bm-deploy-ramdisk" was uploaded.
+--------------------------------------+-------------------+-------------+-----------+--------+
|                  ID                  |        Name       | Disk Format |    Size   | Status |
+--------------------------------------+-------------------+-------------+-----------+--------+
| a5b67368-c785-4935-8354-aa2531a9e2dc | bm-deploy-ramdisk |     ari     | 506895011 | active |
+--------------------------------------+-------------------+-------------+-----------+--------+
/usr/lib/python3.6/site-packages/tripleoclient/v1/overcloud_image.py:496: ResourceWarning: unclosed file <_io.BufferedReader name='/home/stack/images/ironic-python-agent.initramfs'>
  deploy_ramdisk_file))
sys:1: ResourceWarning: unclosed <ssl.SSLSocket fd=7, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=('172.19.1.3', 56488), raddr=('172.19.1.3', 13292)>
sys:1: ResourceWarning: unclosed <ssl.SSLSocket fd=4, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=('172.19.1.3', 58992), raddr=('172.19.1.3', 13000)>
(undercloud) [stack@undercloud15 images]$ openstack image list
+--------------------------------------+------------------------+--------+
| ID                                   | Name                   | Status |
+--------------------------------------+------------------------+--------+
| 8f90fcec-98e6-4e12-b718-39aaf0100106 | bm-deploy-kernel       | active |
| a5b67368-c785-4935-8354-aa2531a9e2dc | bm-deploy-ramdisk      | active |
| 96b4a757-6f1e-468b-a880-5edeae70a107 | overcloud-full         | active |
| 3831d3b6-7fba-450b-897b-7cf2254be6e9 | overcloud-full-initrd  | active |
| 92175186-268c-475e-a5db-3e02b66cd238 | overcloud-full-vmlinuz | active |
+--------------------------------------+------------------------+--------+
(undercloud) [stack@undercloud15 images]$ ls -l /var/lib/ironic/httpboot
total 502720
-rwxr-xr-x. 1 root  root    7876960 Sep 25 05:20 agent.kernel
-rw-r--r--. 1 root  root  506895011 Sep 25 05:20 agent.ramdisk
-rw-r--r--. 1 42422 42422       758 Sep 24 11:45 boot.ipxe
-rw-r--r--. 1 42422 42422       464 Sep 24 11:20 inspector.ipxe




Steps to Reproduce:
1.
2.
3.

Actual results:
No errors/warnings
Is it an important issue?

Expected results:


Additional info:

Comment 1 Emilien Macchi 2019-09-25 12:51:39 UTC
This backport was incomplete: https://review.opendev.org/#/c/674291/3/tripleoclient/v1/overcloud_image.py

Comment 4 Michele Baldessari 2019-09-27 06:43:21 UTC
*** Bug 1756219 has been marked as a duplicate of this bug. ***

Comment 7 Edu Alcaniz 2019-09-27 10:38:37 UTC
I receive similar warning using the command

(undercloud) [stack@undercloud15 ~]$ openstack overcloud node import --validate-only ~/instackenv.json
Waiting for messages on queue 'tripleo' with no timeout.

Successfully validated environment file
sys:1: ResourceWarning: unclosed <ssl.SSLSocket fd=4, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=('172.19.1.3', 60672), raddr=('172.19.1.3', 13000)>
sys:1: ResourceWarning: unclosed <ssl.SSLSocket fd=7, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=('172.19.1.3', 44348), raddr=('172.19.1.3', 13989)>

I guess it is all related

Comment 11 errata-xmlrpc 2020-03-05 12:00:13 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, 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/RHBA-2020:0643