Bug 1925620 - cURL fix and add instructions for image cache
Summary: cURL fix and add instructions for image cache
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Documentation
Version: 4.6
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: ---
: 4.6.z
Assignee: John Wilkins
QA Contact: Xiaoli Tian
Tomas 'Sheldon' Radej
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-02-05 17:27 UTC by Brian J. Beaudoin
Modified: 2021-08-03 15:16 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-08-03 15:16:08 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Brian J. Beaudoin 2021-02-05 17:27:41 UTC
Document URL: https://docs.openshift.com/container-platform/4.6/installing/installing_bare_metal_ipi/ipi-install-installation-workflow.html

Section Number and Name: ipi-install-creating-an-rhcos-images-cache_ipi-install-installation-workflow

Describe the issue: Missing documentation on how to use the cache for the installation in a disconnected environment

Suggestions for improvement: Fix the curl and add instructions

Additional information: 
Full fix for cURL and image cache instructions in my PR:
https://github.com/openshift/openshift-docs/pull/29155

There was a partial fix (just the cURL) in this PR from another contributor:
https://github.com/openshift/openshift-docs/pull/27650

Comment 1 aygarg 2021-02-08 05:21:39 UTC
Hello,

In one of my cases, the customer is facing the same issue. I am sharing the exact information that the customer shared with me.

~~~
As per the below IPI installation steps
https://docs.openshift.com/container-platform/4.6/installing/installing_bare_metal_ipi/ipi-install-installation-workflow.html

curl -L ${RHCOS_PATH}${RHCOS_QEMU_URI} -o /home/kni/rhcos_image_cache
curl -L ${RHCOS_PATH}${RHCOS_OPENSTACK_URI} -o /home/kni/rhcos_image_cache

When I try the steps below it would fail like 

[kni@provisioner ~]$ curl -L ${RHCOS_PATH}${RHCOS_QEMU_URI} -o /home/kni/rhcos_image_cache
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:02 --:--:--     0
100   161  100   161    0     0     25      0  0:00:06  0:00:06 --:--:--    36
  0     0    0     0    0     0      0      0 --:--:--  0:00:12 --:--:--     0Warning: Failed to create the file /home/kni/rhcos_image_cache: Is a directory
  0  847M    0  1642    0     0    128      0  80d 07h  0:00:12  80d 07h   352
curl: (23) Failed writing body (0 != 1642)
[kni@provisioner ~]$ curl -L ${RHCOS_PATH}${RHCOS_OPENSTACK_URI} -o /home/kni/rhcos_image_cache
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   161  100   161    0     0     26      0  0:00:06  0:00:06 --:--:--    41
  0  846M    0     0    0     0      0      0 --:--:--  0:00:12 --:--:--     0Warning: Failed to create the file /home/kni/rhcos_image_cache: Is a directory
  0  846M    0   618    0     0     50      0 205d 10h  0:00:12 205d 10h   154
curl: (23) Failed writing body (0 != 618)

However, when I try with a filename inside /home/kni/rhcos_image_cache, the it would succeed. Pay closer attention to the directory name and also the file 

[kni@provisioner ~]$  curl -L ${RHCOS_PATH}${RHCOS_QEMU_URI} -o /home/kni/rhcos_image_cache/rhcos_image_cache_1
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   161  100   161    0     0     26      0  0:00:06  0:00:06 --:--:--    34
100  847M  100  847M    0     0  5824k      0  0:02:28  0:02:28 --:--:-- 8492k

[kni@provisioner ~]$ curl -L ${RHCOS_PATH}${RHCOS_OPENSTACK_URI} -o /home/kni/rhcos_image_cache/rhcos_image_cache_2
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   161  100   161    0     0     26      0  0:00:06  0:00:06 --:--:--    35
100  846M  100  846M    0     0  3200k      0  0:04:30  0:04:30 --:--:-- 3843k
~~~

Comment 3 Amit Ugol 2021-07-01 15:02:34 UTC
Yes this is the correct usage for curl.


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