Backup & Restore: The service parameter value is restricted to 255 characters

Bug #1845211 reported by Senthil Mukundakumar
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
Fix Released
Medium
Kristine Bujold

Bug Description

Brief Description
-----------------
Restore on IPV6 configuration fails due to service parameter value restricted at 255 characters.
When restore, following error is seen. It seems that bootstrap reproduces those derived entries for docker_no_proxy.

TASK [bootstrap/persist-config : debug] ****************************************************************
ok: [localhost] => {
    "populate_result": {
        "changed": true,
        "failed": false,
        "failed_when_result": false,
        "msg": "non-zero return code",
        "rc": 1,
        "stderr": "No handlers could be found for logger \"cgtsclient.common.http\"\nTraceback (most recent call last):\n File \"/tmp/.ansible-sysadmin/tmp/ansible-tmp-1569262449.64-51808289835978/populate_initial_config.py\", line 967, in <module>\n populate_docker_config(client)\n File \"/tmp/.ansible-sysadmin/tmp/ansible-tmp-1569262449.64-51808289835978/populate_initial_config.py\", line 568, in populate_docker_config\n client.sysinv.service_parameter.create(**values)\n File \"/usr/lib64/python2.7/site-packages/cgtsclient/v1/service_parameter.py\", line 42, in create\n return self._create(self._path(), body)\n File \"/usr/lib64/python2.7/site-packages/cgtsclient/common/base.py\", line 51, in _create\n _, body = self.api.json_request('POST', url, body=body)\n File \"/usr/lib64/python2.7/site-packages/cgtsclient/common/http.py\", line 243, in json_request\n method, **kwargs)\n File \"/usr/lib64/python2.7/site-packages/cgtsclient/common/http.py\", line 219, in _cs_request\n error_json.get('debuginfo'), *args)\ncgtsclient.exc.HTTPBadRequest: The service parameter value is restricted to at most 255 characters.\n",
        "stderr_lines": [
            "No handlers could be found for logger \"cgtsclient.common.http\"",
            "Traceback (most recent call last):",
            " File \"/tmp/.ansible-sysadmin/tmp/ansible-tmp-1569262449.64-51808289835978/populate_initial_config.py\", line 967, in <module>",
            " populate_docker_config(client)",
            " File \"/tmp/.ansible-sysadmin/tmp/ansible-tmp-1569262449.64-51808289835978/populate_initial_config.py\", line 568, in populate_docker_config",
            " client.sysinv.service_parameter.create(**values)",
            " File \"/usr/lib64/python2.7/site-packages/cgtsclient/v1/service_parameter.py\", line 42, in create",
            " return self._create(self._path(), body)",
            " File \"/usr/lib64/python2.7/site-packages/cgtsclient/common/base.py\", line 51, in _create",
            " _, body = self.api.json_request('POST', url, body=body)",
            " File \"/usr/lib64/python2.7/site-packages/cgtsclient/common/http.py\", line 243, in json_request",
            " method, **kwargs)",
            " File \"/usr/lib64/python2.7/site-packages/cgtsclient/common/http.py\", line 219, in _cs_request",
            " error_json.get('debuginfo'), *args)",
            "cgtsclient.exc.HTTPBadRequest: The service parameter value is restricted to at most 255 characters."
        ],
        "stdout": "Populating system config...\nSystem config completed.\nPopulating load config...\nLoad config completed.\nPopulating management network...\nPopulating pxeboot network...\nPopulating oam network...\nPopulating multicast network...\nPopulating cluster host network...\nPopulating cluster pod network...\nPopulating cluster service network...\nNetwork config completed.\nPopulating/Updating DNS config...\nDNS config completed.\nPopulating/Updating docker proxy config...\nFailed to update the initial system config.\n",
        "stdout_lines": [
            "Populating system config...",
            "System config completed.",
            "Populating load config...",
            "Load config completed.",
            "Populating management network...",
            "Populating pxeboot network...",
            "Populating oam network...",
            "Populating multicast network...",
            "Populating cluster host network...",
            "Populating cluster pod network...",
            "Populating cluster service network...",
            "Network config completed.",
            "Populating/Updating DNS config...",
            "DNS config completed.",
            "Populating/Updating docker proxy config...",
            "Failed to update the initial system config."
        ]
    }
}

TASK [bootstrap/persist-config : Fail if populate config script throws an exception] *******************
fatal: [localhost]: FAILED! => {"changed": false, "msg": "Failed to provision initial system configuration."}

PLAY RECAP *********************************************************************************************
localhost : ok=192 changed=74 unreachable=0 failed=1

2019-09-23 19:56:20.874 92986 ERROR sysinv.api.controllers.v1.service_parameter [-] WEI value localhost,127.0.0.1,registry.local,[face::2],[face::3],[2620:10a:a001:a103::1085],[2620:10a:a001:a103::1083],[face::4],[2620:10a:a001:a103::1084],[face::2],[face::3],[2620:10a:a001:a103::1085],[2620:10a:a001:a103::1083],[face::4],[2620:10a:a001:a103::1084],tis-lab-registry.cumulus.wrs.com ß It has 290 characters which is more than 255. The entries in green and purple are duplicated.
2019-09-23 19:56:20.874 92986 WARNING wsme.api [-] Client-side error: The service parameter value is restricted to at most 255 characters.

Here is the override file that is generated:

controller-0:/home/sysadmin# more localhost.yml
dns_servers:
  - 2620:10a:a001:a103::2
pxeboot_subnet: 192.168.202.0/24
pxeboot_start_address: 192.168.202.2
pxeboot_end_address: 192.168.202.254
pxeboot_floating_address: 192.168.202.2
pxeboot_node_0_address: 192.168.202.3
pxeboot_node_1_address: 192.168.202.4
management_subnet: face::/64
management_start_address: face::2
management_end_address: face::ffff:ffff:ffff:fffe
management_floating_address: face::2
management_node_0_address: face::3
management_node_1_address: face::4
management_multicast_subnet: ff05::31:0/124
management_multicast_start_address: ff05::31:1
management_multicast_end_address: ff05::31:e
cluster_host_subnet: feed:beef::/64
cluster_host_start_address: feed:beef::2
cluster_host_end_address: feed:beef::ffff:ffff:ffff:fffe
cluster_host_floating_address: feed:beef::2
cluster_host_node_0_address: feed:beef::3
cluster_host_node_1_address: feed:beef::4
cluster_pod_subnet: dead:beef::/64
cluster_pod_start_address: dead:beef::1
cluster_pod_end_address: dead:beef::ffff:ffff:ffff:fffe
cluster_service_subnet: fd04::/112
cluster_sevice_start_address: fd04::1
cluster_service_end_address: fd04::1
external_oam_subnet: 2620:10a:a001:a103::/64
external_oam_start_address: 2620:10a:a001:a103::1
external_oam_end_address: 2620:10a:a001:a103:ffff:ffff:ffff:fffe
external_oam_gateway_address: 2620:10a:a001:a103::6:0
external_oam_floating_address: 2620:10a:a001:a103::1085
external_oam_node_0_address: 2620:10a:a001:a103::1083
external_oam_node_1_address: 2620:10a:a001:a103::1084
docker_no_proxy:
  - "localhost"
  - "127.0.0.1"
  - "registry.local"
  - "[face::2]"
  - "[face::3]"
  - "[2620:10a:a001:a103::1085]"
  - "[2620:10a:a001:a103::1083]"
  - "[face::4]"
  - "[2620:10a:a001:a103::1084]"
  - "tis-lab-registry.cumulus.wrs.com"
docker_http_proxy: http://yow-proxomatic.wrs.com:3128

Severity
--------
Critical: Fail to restore active controller on IPV6 configuration

Steps to Reproduce
------------------
1. Bring up the IPV6 regular system
2. Backup the system locally
3. Re-install the controller with the same load
4. Restore the system locally from controller

Expected Behavior
------------------
The active controller must be restored from backup

Actual Behavior
----------------
Active controller failed to restore

TASK [bootstrap/persist-config : Fail if populate config script throws an exception] *******************
fatal: [localhost]: FAILED! => {"changed": false, "msg": "Failed to provision initial system configuration."}

PLAY RECAP *********************************************************************************************
localhost : ok=192 changed=74 unreachable=0 failed=1

Reproducibility
---------------
Reproducible

System Configuration
--------------------
IPv6 configured system

Branch/Pull Time/Commit
-----------------------
2019-09-22_20-00-00

Test Activity
-------------
Feature Testing

summary: - Backup & Restore: he service parameter value is restricted to 255
+ Backup & Restore: The service parameter value is restricted to 255
characters
Yang Liu (yliu12)
tags: added: stx.retestneeded
Revision history for this message
Ghada Khalil (gkhalil) wrote :

Marking as stx.3.0 gating assuming there is a config that requires ansible to have more than 255 characters. If there is no such config, please mark as Invalid.

tags: added: stx.config
Changed in starlingx:
importance: Undecided → Medium
status: New → Triaged
assignee: nobody → Tee Ngo (teewrs)
tags: added: stx.3.0
Revision history for this message
Kristine Bujold (kbujold) wrote :

This is a duplicated of https://bugs.launchpad.net/starlingx/+bug/1856236 which is resolved.

Changed in starlingx:
assignee: Tee Ngo (teewrs) → Kristine Bujold (kbujold)
Revision history for this message
Ghada Khalil (gkhalil) wrote :

Marking as Fix Released
Duplicate LP fixed by: https://review.opendev.org/699278
Merged in stx master on 2019-12-17

Changed in starlingx:
status: Triaged → Fix Released
Revision history for this message
Ghada Khalil (gkhalil) wrote :

Since the fix is only in master, changing the release tag to stx.4.0.
This is medium priority, so doesn't qualify for cherry-picking to the r/stx.3.0 branch.

tags: added: stx.4.0
removed: stx.3.0
Revision history for this message
Senthil Mukundakumar (smukunda) wrote :

Verified using wcp_78_79 with load 2020-02-18_04-10-00

tags: removed: stx.retestneeded
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.