[LDAP] LDAP plugin blocks Fuel upgrade 9.0->9.1

Bug #1638617 reported by Denis Klepikov
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Fuel Plugins
Fix Committed
Critical
Nikita Karpin
Mirantis OpenStack
Fix Released
Critical
Nikita Karpin

Bug Description

LDAP plugin blocks Fuel upgrade 9.0->9.1

 fuel2 update --env 2 install
Settings configuration for environment with id=2 downloaded to /root/settings_2.yaml
Fail to install updates for environment 2
Traceback (most recent call last):
File "/root/python-cudet/cudet/updates.py", line 138, in take_action
settings_action.upload(parsed_args)
File "/usr/lib/python2.7/site-packages/fuelclient/cli/actions/settings.py", line 54, in upload
env.set_settings_data(settings_data, params.force)
File "/usr/lib/python2.7/site-packages/fuelclient/objects/environment.py", line 276, in set_settings_data
self.settings_url, data)
File "/usr/lib/python2.7/site-packages/fuelclient/client.py", line 185, in put_request
self._raise_for_status_with_info(resp)
File "/usr/lib/python2.7/site-packages/fuelclient/client.py", line 240, in _raise_for_status_with_info
raise error.HTTPError(error.get_full_error_message(e))
HTTPError: 400 Client Error: Bad Request for url: http://ХХ.ХХ.ХХ.ХХ:8000/api/v1/clusters/2/attributes (Cannot enable plugin with legacy tasks unless propagate_task_deploy attribute is set. Ensure tasks.yaml is empty and all tasks has version >= 2.0.0.)
[root@fuel ~]#

# fuel plugins list
id | name | version | package_version | releases
---+-----------------------------+---------+-----------------+----------------------------------------------
1 | ldap | 3.0.0 | 3.0.0 | ubuntu (mitaka-9.0)
2 | elasticsearch_kibana | 0.10.2 | 4.0.0 | ubuntu (liberty-8.0, liberty-9.0, mitaka-9.0)
3 | influxdb_grafana | 0.10.2 | 4.0.0 | ubuntu (liberty-8.0, liberty-9.0, mitaka-9.0)
5 | lma_collector | 0.10.2 | 4.0.0 | ubuntu (liberty-8.0, liberty-9.0, mitaka-9.0)
4 | lma_infrastructure_alerting | 0.10.2 | 4.0.0 | ubuntu (liberty-8.0, liberty-9.0, mitaka-9.0)

deployment_tasks.yaml for this plugin does not contain tasks version

- id: ldap_plugin
  type: puppet
  groups: [primary-controller, controller]
  required_for : [deploy_end]
  requires: [keystone-db, keystone, horizon]
  parameters:
    puppet_manifest: "puppet/manifests/controller_site.pp"
    puppet_modules: "puppet/modules/:/etc/puppet/modules/"
    timeout: 3600

MOS 9.0

Changed in fuel-plugins:
status: New → Confirmed
importance: Undecided → Critical
milestone: none → 9.0
description: updated
Revision history for this message
Georgy Kibardin (gkibardin) wrote :

So, as the warning says, we need to add "version: 2.0.0" to the task.

Changed in mos:
status: New → Confirmed
importance: Undecided → Critical
assignee: nobody → Nikita Karpin (mkarpin)
milestone: none → 9.2
Revision history for this message
Denis Klepikov (dklepikov) wrote :

Adding "version: 2.0.0" to the task will not resolve the issue, due to all data were synced into nailgun during pluging installation and will be used from there insthead of re-reading deployment_tasks.yaml file.
I can try to re-sync nailgun and deployment graf with the correct tasks version.

Revision history for this message
Nikita Karpin (mkarpin) wrote :

@Denis yes, can you please try it and share the results, thank you

Revision history for this message
Denis Klepikov (dklepikov) wrote :

@Nikita, sure.
As soon as I got any result I will inform you

Revision history for this message
Nikita Karpin (mkarpin) wrote :

thanks Denis, I am also testing the patch - https://review.openstack.org/#/c/393109/, but the test is long, the results will be in ~7 hours

Revision history for this message
Denis Klepikov (dklepikov) wrote :

Possible workaround:
Edit /var/www/nailgun/plugins/ldap-3.0/deployment_tasks.yaml
 id: ldap_plugin
  type: puppet
  version: 2.0.0
  groups: [primary-controller, controller]
  required_for : [deploy_end]
  requires: [keystone-db, keystone, horizon]
  parameters:
    puppet_manifest: "puppet/manifests/controller_site.pp"
    puppet_modules: "puppet/modules/:/etc/puppet/modules/"
    timeout: 3600

(add "version: 2.0.0" line), save it.
Run plugins sync:
fuel plugins --sync

re-run the upgrade "fuel2 update --env <ENV_ID> install"
upgrade started, I will post the results.

Revision history for this message
Denis Klepikov (dklepikov) wrote :

I tested it on my virtual environment and I was able to successfully upgrade environment from 9.0 to 9.1 after applying workaround.

Nikita Karpin (mkarpin)
Changed in fuel-plugins:
assignee: nobody → Nikita Karpin (mkarpin)
status: Confirmed → In Progress
Changed in mos:
status: Confirmed → In Progress
Revision history for this message
Nikita Karpin (mkarpin) wrote :

Thanks Denis, I also tested 9.x and 9.0 deployment manually and on ci with fix https://review.openstack.org/#/c/393109/, so deployment goes fine, now I updated the fix, and waiting for final CI run, then we will merge it

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-plugin-ldap (master)

Reviewed: https://review.openstack.org/393109
Committed: https://git.openstack.org/cgit/openstack/fuel-plugin-ldap/commit/?id=d681925807160bf280f28b51ee8e5cc831eefb26
Submitter: Jenkins
Branch: master

commit d681925807160bf280f28b51ee8e5cc831eefb26
Author: Mykyta Karpin <email address hidden>
Date: Thu Nov 3 08:36:22 2016 +0200

    Update task version

    In Fuel 9.0, 9.x we need to set task version to 2.0.0
    to comply with task based deployment

    Change-Id: I08ccf91314eedf7fdacf26c4cebafd1d5d9feaae
    Closes-Bug: #1638617

Changed in fuel-plugins:
status: In Progress → Fix Committed
Nikita Karpin (mkarpin)
Changed in mos:
status: In Progress → Fix Committed
tags: added: area-mos
tags: added: on-verification
Revision history for this message
TatyanaGladysheva (tgladysheva) wrote :

Verified on 9.2 snapshot #537.

tags: removed: on-verification
Changed in mos:
status: Fix Committed → Fix Released
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.