Insecure registry fails for windows nodes during configuration

Bug #1803015 reported by Lajapathy Madhusudhanan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
Trunk
In Progress
Undecided
Michał Kostrzewa

Bug Description

When private insecure registry is used for registry, the following error is observed for windows nodes,

global_configuration:
  REGISTRY_PRIVATE_INSECURE: True
  CONTAINER_REGISTRY: ci-repo.englab.juniper.net:5010

TASK [docker : create /etc/docker directory] *****************************************************************

 [WARNING]: FATAL ERROR DURING FILE TRANSFER: Traceback (most recent call last): File "/usr/lib/python2.7
/site-packages/ansible/plugins/connection/winrm.py", line 276, in _winrm_exec
self._winrm_send_input(self.protocol, self.shell_id, command_id, data, eof=is_last) File
"/usr/lib/python2.7/site-packages/ansible/plugins/connection/winrm.py", line 256, in _winrm_send_input
protocol.send_message(xmltodict.unparse(rq)) File "/usr/lib/python2.7/site-packages/winrm/protocol.py",
line 256, in send_message raise WinRMOperationTimeoutError() WinRMOperationTimeoutError

fatal: [10.87.66.194]: FAILED! => {"msg": "winrm send_input failed"}

Using module file /usr/lib/python2.7/site-packages/ansible/modules/files/file.py
<10.87.66.192> ESTABLISH WINRM CONNECTION FOR USER: Administrator on PORT 5986 TO 10.87.66.192
Using module file /usr/lib/python2.7/site-packages/ansible/modules/files/file.py
<10.87.66.194> ESTABLISH WINRM CONNECTION FOR USER: Administrator on PORT 5986 TO 10.87.66.194

sagarkchitnis (sagarc)
Changed in juniperopenstack:
assignee: nobody → Michał Kostrzewa (mkostrzewa)
sagarkchitnis (sagarc)
information type: Proprietary → Public
Revision history for this message
Jacek Iżykowski (j.i.) wrote :

Seemingly the following step failed: "create /etc/docker directory".
Reported error is: WinRMOperationTimeoutError.

It doesn't seem that this is anyhow related to any registry.
Looks like a timeout in connection between host running ansible and node being configured.

1. Why do you think this is related to any registry?
2. Do you see any correlation between this error and selected registry?
3. How many times this problem occurred when this task was executed?
4. Have you seen WinRMOperationTimeoutError while other tasks were executed?

Revision history for this message
Jacek Iżykowski (j.i.) wrote :

And by the way: there's WinRMOperationTimeoutError that suggests that an operation fails for Windows node.
But creating a directory /etc/docker is a bit unexpected for Windows node.
What roles are assigned to that Windows node?

Revision history for this message
Jacek Iżykowski (j.i.) wrote :

Update:
In a 'docker' role, when global_configuration.REGISTRY_PRIVATE_INSECURE is set to true, insecure_registry.yaml is included. This file contains tasks that are only valid for Linux.

This bug requires further investigation.

Revision history for this message
haji mohamed ashraf ali (hajim) wrote : Re: Change in Juniper/contrail-controller[master]: Vrouter drop stats log buffer Infra
Download full text (4.4 KiB)

Hi,

Below build(After review creation) failed on Windows systems and I don’t have any clue what went wrong. I have checked the build on centos 7.4 system, Build was passing.

Request your help to fix the issue on windows based system.

Review Id: https://review.opencontrail.org/#/c/47336/
https://review.opencontrail.org/#/c/47334/

Build Failure Log on Windows:
light.exe -nologo -ext WixUtilExtension.dll -out build\debug\vrouter\extension\vRouter.msi vrouter\windows\installer\vrouter_msi.wixobj
2018-11-21 00:45:25.778000 | [Build] scons: building associated VariantDir targets: build\debug\vrouter\utils
2018-11-21 00:45:26.046000 | [Build] cl /Fobuild\debug\vrouter\utils\dropstats.obj /c vrouter\utils\dropstats.c /nologo /Iwindows/inc /D_WINDOWS /D_WIN32_WINNT=0x0A00 /EHsc /DNOMINMAX /DNOGDI /D_SCL_SECURE_NO_WARNINGS /D_CRT_SECURE_NO_WARNINGS /DWIN32_LEAN_AND_MEAN /RTC1 /MDd /Z7 /WX /Ivrouter\include /Ibuild\debug\vrouter\sandesh\gen-c /Ivrouter\sandesh\gen-c /Isrc\contrail-common /Isrc\contrail-common\sandesh\library\c /Ivrouter\windows
2018-11-21 00:45:26.046000 | [Build] dropstats.c
2018-11-21 00:45:26.315000 | [Build] j:\jenkins\workspace\wincontrail\****-server2016-prod\vrouter\utils\dropstats.c(138) : error C2220: warning treated as error - no 'object' file generated
2018-11-21 00:45:26.315000 | [Build] j:\jenkins\workspace\wincontrail\****-server2016-prod\vrouter\utils\dropstats.c(138) : warning C4700: uninitialized local variable 'ret' used
2018-11-21 00:45:26.315000 | [Build] scons: *** [build\debug\vrouter\utils\dropstats.obj] Error 2

Please let me know, if any more details required.

Regards
Haji Mohamed.

On 21/11/18, 2:37 PM, "Contrail Windows CI (Code Review)" <email address hidden> wrote:

    Contrail Windows CI has posted comments on this change.

    Change subject: Vrouter drop stats log buffer Infra
    ......................................................................

    Patch Set 4: Verified-1

    Build failed (check pipeline).

    - ci-contrail-windows-production https://urldefense.proofpoint.com/v2/url?u=http-3A__logs.opencontrail.org_winci_30439a4a989e488aaba941bed53aba8f_&d=DwIDaQ&c=HAkYuh63rsuhr6Scbfh0UjBXeMK-ndb3voDTXcWzoCI&r=C2uP7uRJxCXF0CJnbv4zz_BDg9aYeMnnEWdHkCYupeE&m=h4vCsMMc3kdUJuyQ34_gqXaPpS-S8T1q7aa5_17Jetw&s=IXP-tRHh0Yo1ZENO4DJ46doUavSJaz1BNreHaXbBtxU&e= : FAILURE in 35m 25s

    This is a pipeline from Windows CI. Latest build stats: https://urldefense.proofpoint.com/v2/url?u=http-3A__148.251.5.92_d_w9YdWjqzk_build-2Dstatistics&d=DwIDaQ&c=HAkYuh63rsuhr6Scbfh0UjBXeMK-ndb3voDTXcWzoCI&r=C2uP7uRJxCXF0CJnbv4zz_BDg9aYeMnnEWdHkCYupeE&m=h4vCsMMc3kdUJuyQ34_gqXaPpS-S8T1q7aa5_17Jetw&s=Bn5GFKdGHO_8t155VYviOBxHWd55PbV7RotOCyuhtuI&e=. For troubleshooting and FAQ, see: https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_Juniper_contrail-2Dwindows-2Dci_wiki_OpenContrail-2DWindows-2DCI-2DFAQ&d=DwIDaQ&c=HAkYuh63rsuhr6Scbfh0UjBXeMK-ndb3voDTXcWzoCI&r=C2uP7uRJxCXF0CJnbv4zz_BDg9aYeMnnEWdHkCYupeE&m=h4vCsMMc3kdUJuyQ34_gqXaPpS-S8T1q7aa5_17Jetw&s=_ZaXWpn3s2XYM1Qz1GDYm5yEUCMSr_0nFnrSC2zqHvI&e=

    --
    To view, visit https://url...

Read more...

Revision history for this message
Michał Kostrzewa (mkostrzewa) wrote : Re: [Bug 1803015] Re: Change in Juniper/contrail-controller[master]: Vrouter drop stats log buffer Infra
Download full text (8.1 KiB)

Hi,

looking at the compilation error '*utils\dropstats.c(138) : warning C4700:
uninitialized local variable 'ret' used*'.

I looked at change that your change depends on.

It looks like that change is also failing in Windows CI, probably for the
same reason.

Take a look at line 138 here:
https://review.opencontrail.org/#/c/47334/7/utils/dropstats.
<https://review.opencontrail.org/#/c/47334/7/utils/dropstats.c>

*ret* is initialized and but not assigned.

    int ret;
> vr_pkt_drop_stats_log_request(cl, 0, core, stats_index);
> if(ret <0)
> return ret;

Not sure why you commented under this bug on launchpad though, as it seems
unrelated.

Best regards,

On Wed, Nov 21, 2018 at 11:35 AM haji mohamed ashraf ali <
<email address hidden>> wrote:

> Hi,
>
> Below build(After review creation) failed on Windows systems and I don’t
> have any clue what went wrong. I have checked the build on centos 7.4
> system, Build was passing.
>
> Request your help to fix the issue on windows based system.
>
> Review Id: https://review.opencontrail.org/#/c/47336/
> https://review.opencontrail.org/#/c/47334/
>
>
> Build Failure Log on Windows:
> light.exe -nologo -ext WixUtilExtension.dll -out
> build\debug\vrouter\extension\vRouter.msi
> vrouter\windows\installer\vrouter_msi.wixobj
> 2018-11-21 00:45:25.778000 | [Build] scons: building associated VariantDir
> targets: build\debug\vrouter\utils
> 2018-11-21 00:45:26.046000 | [Build] cl
> /Fobuild\debug\vrouter\utils\dropstats.obj /c vrouter\utils\dropstats.c
> /nologo /Iwindows/inc /D_WINDOWS /D_WIN32_WINNT=0x0A00 /EHsc /DNOMINMAX
> /DNOGDI /D_SCL_SECURE_NO_WARNINGS /D_CRT_SECURE_NO_WARNINGS
> /DWIN32_LEAN_AND_MEAN /RTC1 /MDd /Z7 /WX /Ivrouter\include
> /Ibuild\debug\vrouter\sandesh\gen-c /Ivrouter\sandesh\gen-c
> /Isrc\contrail-common /Isrc\contrail-common\sandesh\library\c
> /Ivrouter\windows
> 2018-11-21 00:45:26.046000 | [Build] dropstats.c
> 2018-11-21 00:45:26.315000 | [Build]
> j:\jenkins\workspace\wincontrail\****-server2016-prod\vrouter\utils\dropstats.c(138)
> : error C2220: warning treated as error - no 'object' file generated
> 2018-11-21 00:45:26.315000 | [Build]
> j:\jenkins\workspace\wincontrail\****-server2016-prod\vrouter\utils\dropstats.c(138)
> : warning C4700: uninitialized local variable 'ret' used
> 2018-11-21 00:45:26.315000 | [Build] scons: ***
> [build\debug\vrouter\utils\dropstats.obj] Error 2
>
> Please let me know, if any more details required.
>
> Regards
> Haji Mohamed.
>
>
> On 21/11/18, 2:37 PM, "Contrail Windows CI (Code Review)" <ci-
> <email address hidden>> wrote:
>
> Contrail Windows CI has posted comments on this change.
>
> Change subject: Vrouter drop stats log buffer Infra
> ......................................................................
>
>
> Patch Set 4: Verified-1
>
> Build failed (check pipeline).
>
> - ci-contrail-windows-production
> https://urldefense.proofpoint.com/v2/url?u=http-3A__logs.opencontrail.org_winci_30439a4a989e488aaba941bed53aba8f_&d=DwIDaQ&c=HAkYuh63rsuhr6Scbfh0UjBXeMK-ndb3voDTXcWzoCI&r=C2uP7uRJxCXF0CJnbv4zz_BDg9aYeMnnEWdHkCYupeE&m=h4vCsMMc3kdUJuyQ34_gqXaPpS-S8T1q7aa5_17Jetw&s=IXP-tRHh0Yo1ZENO4DJ46do...

Read more...

Revision history for this message
Michał Kostrzewa (mkostrzewa) wrote :

Hi,

looking at the compilation error 'utils\dropstats.c(138) : warning C4700: uninitialized local variable 'ret' used'.

I looked at change that your change depends on.

It looks like that change is also failing in Windows CI, probably for the same reason.

Take a look at line 138 here: https://review.opencontrail.org/#/c/47334/7/utils/dropstats.

ret is initialized and but not assigned.

    int ret;
    vr_pkt_drop_stats_log_request(cl, 0, core, stats_index);
    if(ret <0)
        return ret;

Not sure why you commented under this bug on launchpad though, as it seems unrelated.

Best regards,

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/47809
Submitter: Mateusz Jablonski (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote :

Review in progress for https://review.opencontrail.org/47809
Submitter: Michal Krawczyk (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote :

Review in progress for https://review.opencontrail.org/47809
Submitter: Mateusz Jablonski (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/47809
Committed: http://github.com/Juniper/contrail-ansible-deployer/commit/faf80dcfb1f1a803daf8226bf560b963b45aefb1
Submitter: Zuul v3 CI (<email address hidden>)
Branch: master

commit faf80dcfb1f1a803daf8226bf560b963b45aefb1
Author: Mateusz Jablonski <email address hidden>
Date: Thu Nov 22 16:15:39 2018 +0100

Make 'insecure_registry.yaml' system-independent

- Move insecure_registry to OS-dependent files
- Add docker config path constants

Change-Id: Ie3291c842a3d15c1e607838c78ee17096a4a1639
Closes-Bug: #1803015

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/48244
Submitter: Jacek Izykowski (<email address hidden>)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.