"fuel node" cmd lists some nodes twice

Bug #1328240 reported by Gil McGrath
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Released
High
Dima Shulyak
5.0.x
Fix Committed
High
Dima Shulyak

Bug Description

The 'fuel node' command lists some nodes twice (more than once). See below:
# fuel node
id | status | name | cluster | ip | mac | roles | pending_roles | online
---|----------|-------------------------|---------|-------------|-------------------|------------|---------------|-------
10 | ready | sb4-ceph1-pxe-i-15 | 3 | 10.20.1.7 | be:24:d3:b4:fa:44 | ceph-osd | | True
9 | ready | sb4-cnode2-pxe-i-14 | 3 | 10.20.1.6 | 8e:e9:2c:90:7e:46 | compute | | True
8 | ready | sb4-cnode1-pxe-i-13 | 3 | 10.20.1.5 | b2:ce:31:77:8c:4a | compute | | True
15 | ready | sb4-controller-pxe-i-12 | 3 | 10.20.1.9 | c6:c6:94:36:2a:47 | controller | | True
11 | ready | sb4-ceph-2-pxe-i-16 | 3 | 10.20.1.8 | 2e:fd:5e:95:fa:44 | ceph-osd | | True
19 | discover | Untitled (4c:38) | None | 10.20.1.211 | fc:15:b4:1c:4c:38 | | | False
18 | discover | Untitled (17:88) | None | 10.20.1.179 | fc:15:b4:1d:17:88 | | | False
17 | discover | Untitled (2d:28) | None | 10.20.1.235 | fc:15:b4:1c:2d:28 | | | False
21 | discover | Untitled (88:80) | None | 10.20.1.139 | fc:15:b4:1d:88:80 | | | False
20 | discover | Untitled (fd:10) | None | 10.20.1.219 | fc:15:b4:1c:fd:10 | | | False
16 | discover | pxe-i-11 | None | 10.20.1.213 | fc:15:b4:1c:4d:68 | | | False
16 | discover | pxe-i-11 | None | 10.20.1.213 | fc:15:b4:1c:4d:68 | | | False
21 | discover | Untitled (88:80) | None | 10.20.1.139 | fc:15:b4:1d:88:80 | | | False
8 | ready | sb4-cnode1-pxe-i-13 | 3 | 10.20.1.5 | b2:ce:31:77:8c:4a | compute | | True

Also - interesting that when I remove all discovered nodes the duplicate node in ready state goes away and there are no duplicate nodes in output. But, when i repower up the nodes and they are discovered the duplicate nodes on "fuel node" output shows up again for the node in ready state as well as the discovered nodes. Intereseting....

I do have a fuel snapshot - but I seem unable to attach it to this bug report (2.8 GB). I guess it is too large.

Dima Shulyak (dshulyak)
Changed in fuel:
milestone: none → 5.1
assignee: nobody → Fuel Python Team (fuel-python)
Revision history for this message
Dima Shulyak (dshulyak) wrote :

reproduced similar dehaviour, but all nodes were duplicated, it is issue not with cli but with nailgun api itself

Changed in fuel:
status: New → Confirmed
importance: Undecided → Medium
importance: Medium → High
Revision history for this message
Dima Shulyak (dshulyak) wrote :

please attach localhost/pg_dump from snapshot

Revision history for this message
Gil McGrath (gmcgrath) wrote :

Fuel snapshot attached

Revision history for this message
Dima Shulyak (dshulyak) wrote :

note: according to this https://groups.google.com/forum/#!topic/sqlalchemy/ZTevy2g7pOg

yield_per should not be used with eager loading:
1. it is useless with subquery
2. can lead to different results with joinedload

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-web (master)

Fix proposed to branch: master
Review: https://review.openstack.org/99661

Changed in fuel:
assignee: Fuel Python Team (fuel-python) → Dima Shulyak (dshulyak)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-web (master)

Reviewed: https://review.openstack.org/99661
Committed: https://git.openstack.org/cgit/stackforge/fuel-web/commit/?id=bff8b1bd05168ea65f6738d5e7ce2d7c62d4f480
Submitter: Jenkins
Branch: master

commit bff8b1bd05168ea65f6738d5e7ce2d7c62d4f480
Author: Dima Shulyak <email address hidden>
Date: Thu Jun 12 16:12:48 2014 +0300

    Ensure all nested attributes loaded once

    - subqueryload_all for each nested attributes ensures that
      attribute is loaded once
    - minor refactoring of get admin_interface logic in
      network manager to use sql relations instead of queries each time
    - removed yield_per from eagerload methods
      see: http://docs.sqlalchemy.org/en/rel_0_9/orm/query.html#sqlalchemy.orm.query.Query.yield_per
    - by deafault collection.eager will use joinedload for each provided field

    Change-Id: Ifea46654335bf9ea91835880fbf9d6c96b8b63e7
    Closes-Bug: #1328240

Changed in fuel:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to fuel-web (stable/5.0)

Fix proposed to branch: stable/5.0
Review: https://review.openstack.org/102473

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to fuel-web (stable/5.0)

Reviewed: https://review.openstack.org/102473
Committed: https://git.openstack.org/cgit/stackforge/fuel-web/commit/?id=82de9a6e4e8f04b670806220f8a49dfbe82304a0
Submitter: Jenkins
Branch: stable/5.0

commit 82de9a6e4e8f04b670806220f8a49dfbe82304a0
Author: Dima Shulyak <email address hidden>
Date: Thu Jun 12 16:12:48 2014 +0300

    Ensure all nested attributes loaded once

    - subqueryload_all for each nested attributes ensures that
      attribute is loaded once
    - minor refactoring of get admin_interface logic in
      network manager to use sql relations instead of queries each time
    - removed yield_per from eagerload methods
      see: http://docs.sqlalchemy.org/en/rel_0_9/orm/query.html#sqlalchemy.orm.query.Query.yield_per
    - by deafault collection.eager will use joinedload for each provided field

    Change-Id: Ifea46654335bf9ea91835880fbf9d6c96b8b63e7
    Closes-Bug: #1328240

Revision history for this message
Anastasia Palkina (apalkina) wrote :

Verified on ISO #274
"build_id": "2014-06-27_00-31-14",
"mirantis": "yes",
"build_number": "274",
"ostf_sha": "a4978638de3951dbc229276608a839a19ece2b70",
"nailgun_sha": "5f2944a8d5077a1c96acb076ba9194f670b818e8",
"production": "docker",
"api": "1.0",
"fuelmain_sha": "bf8660309601cee2f8f3e1bb881d272e638dcffa",
"astute_sha": "694b5a55695e01e1c42185bfac9cc7a641a9bd48",
"release": "5.1",
"fuellib_sha": "acc99fcd0ba9eeef0a504dc26507eb91ce757220"

[root@fuel ~]# fuel node
id | status | name | cluster | ip | mac | roles | pending_roles | online
---|--------------|------------------|---------|-------------|-------------------|------------|---------------|-------
11 | provisioned | Untitled (14:b7) | 3 | 10.20.0.7 | 08:00:27:1c:14:b7 | cinder | | True
12 | provisioning | Untitled (f6:53) | 5 | 10.20.0.142 | 08:00:27:9e:f6:53 | controller | | True
10 | provisioned | Untitled (a0:65) | 3 | 10.20.0.6 | 08:00:27:ee:a0:65 | compute | | True
15 | discover | Untitled (5f:ae) | None | 10.20.0.240 | 08:00:27:49:5f:ae | | | True
13 | provisioning | Untitled (3b:49) | 5 | 10.20.0.166 | 08:00:27:6e:3b:49 | controller | | True
8 | provisioned | Untitled (ae:68) | 3 | 10.20.0.4 | 08:00:27:6b:ae:68 | controller | | True
16 | discover | Untitled (bf:61) | None | 10.20.0.213 | 08:00:27:8c:bf:61 | | | True
14 | provisioning | Untitled (34:d5) | 5 | 10.20.0.203 | 08:00:27:8a:34:d5 | controller | | True
9 | provisioned | Untitled (51:5e) | 3 | 10.20.0.5 | 08:00:27:82:51:5e | controller | | True
7 | deploying | Untitled (aa:21) | 3 | 10.20.0.3 | 9e:59:64:40:e2:40 | controller | | True

Dmitry Pyzhov (dpyzhov)
no longer affects: fuel/5.1.x
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.