We had a situation where two user accounts were found with the same name and user ID in both the local_user and federated_user table. This meant that running `openstack user show --domain mydomain username2` would fail with "More than one user exists with the name 'username2'". Listing users would show only one user account, and using the user uuid to 'user show' was working fine.
I ended up removing the two rows from local_user to work around this.
The bug however, is that federated users with the same name as one that was already located in local_user shouldn't be created like that.
Keystone 15.0.0- 0ubuntu1~ cloud0 CODENAME= bionic saml-mellon- 3
DISTRIB_
Charm cs:keystone-306 keystone-
We had a situation where two user accounts were found with the same name and user ID in both the local_user and federated_user table. This meant that running `openstack user show --domain mydomain username2` would fail with "More than one user exists with the name 'username2'". Listing users would show only one user account, and using the user uuid to 'user show' was working fine.
I ended up removing the two rows from local_user to work around this.
The bug however, is that federated users with the same name as one that was already located in local_user shouldn't be created like that.
mysql> select * from local_user; ------- ------- ------- ------- ------+ ------- ------- ------- ------- ------+ ------- ------- ------- ------- ---+--- ------- ------- --+---- ------- -----+ ------- ------- ------- ------- ------+ ------- ------- ------- ------- ------+ ------- ------- ------- ------- ---+--- ------- ------- --+---- ------- -----+ eba2ed675106422 7a | 87fb238ef6d0430 cbda59b08e3a1ea 82 | admin | 0 | NULL | 6a00e435306f72f fc | a1effaa62628467 7ade0fbe3e85c59 bd | cinderv2_cinderv3 | 0 | NULL | ba2e5f1d3842c93 b1 | fa58dfa26889413 e85b4855837952b 74 | cinderv2_cinderv3 | 0 | NULL | 18fe043eb5782e0 ed | a1effaa62628467 7ade0fbe3e85c59 bd | gnocchi | 0 | NULL | 08fbba94b824f57 65 | fa58dfa26889413 e85b4855837952b 74 | gnocchi | 0 | NULL | 9ac2ef2accd5350 d3 | a1effaa62628467 7ade0fbe3e85c59 bd | neutron | 0 | NULL | e8230d80b752d4f 5c | fa58dfa26889413 e85b4855837952b 74 | neutron | 0 | NULL | 7b08deab6713bd4 ac | a1effaa62628467 7ade0fbe3e85c59 bd | nova_placement | 0 | NULL | ebf716d5cb56cd0 07 | fa58dfa26889413 e85b4855837952b 74 | nova_placement | 0 | NULL | 3b30d2c4e4ad9bb 05 | a1effaa62628467 7ade0fbe3e85c59 bd | octavia | 0 | NULL | b8d71eee67eabe4 c2 | fa58dfa26889413 e85b4855837952b 74 | octavia | 0 | NULL | b92848b9ea40ba7 1f | a1effaa62628467 7ade0fbe3e85c59 bd | barbican | 0 | NULL | 5b6cc37602fe346 a5 | fa58dfa26889413 e85b4855837952b 74 | barbican | 0 | NULL | 99b4e6a57a789e8 9c | a1effaa62628467 7ade0fbe3e85c59 bd | aodh | 0 | NULL | 080b5371a348356 b3 | fa58dfa26889413 e85b4855837952b 74 | aodh | 0 | NULL | 6b44f38a80949f7 d1 | a1effaa62628467 7ade0fbe3e85c59 bd | swift | 0 | NULL | 4b544070295a285 4f | fa58dfa26889413 e85b4855837952b 74 | swift | 0 | NULL | ab3c43fdf95790d cd | a1effaa62628467 7ade0fbe3e85c59 bd | designate | 0 | NULL | 080581f9acc9f79 05 | fa58dfa26889413 e85b4855837952b 74 | designate | 0 | NULL | 0b0d05d3112a038 40 | a1effaa62628467 7ade0fbe3e85c59 bd | glance | 0 | NULL | 091381e74d4fbca 21 | fa58dfa26889413 e85b4855837952b 74 | glance | 0 | NULL | 8b196bb81b8a4ce d5 | a1effaa62628467 7ade0fbe3e85c59 bd | heat_heat-cfn | 0 | NULL | 1aad22c3beb59c8 02 | fa58dfa26889413 e85b4855837952b 74 | heat_heat-cfn | 0 | NULL | a98cca6807ba238 8d | fa58dfa26889413 e85b4855837952b 74 | nagios | 0 | NULL | 888833e3a13df80 ff | fa58dfa26889413 e85b4855837952b 74 | prometheus- openstack- exporter | 0 | NULL | 0915cf9a08a53aa 96 | fa58dfa26889413 e85b4855837952b 74 | ceilometer | 0 | NULL | 294bbf168c28c38 aa | 12ba878696e54f7 c91a2ef9001d93e 99 | heat_domain_admin | 0 | NULL | 4ac8b90dc1722d9 f2 | 87fb238ef6d0430 cbda59b08e3a1ea 82 | cloudadmin | 0 | NULL | a8a8d7de55338d0 9b | 6d4704c1a6164c7 0a4763ac886bcf2 28 | landscape | NULL | NULL | 0ace34da1cffb2b 77 | 6d4704c1a6164c7 0a4763ac886bcf2 28 | voithadmin | 0 | NULL | 9b4563c9d69360c 86 | 6d4704c1a6164c7 0a4763ac886bcf2 28 | username1 | 0 | NULL | faf46e891469515 24 | 6d4704c1a6164c7 0a4763ac886bcf2 28 | username2 | 0 | NULL | f9f200bc40c51ee b6 | 6d4704c1a6164c7 0a4763ac886bcf2 28 | demouser | 0 | NULL | ------- ------- ------- ------- ------+ ------- ------- ------- ------- ------+ ------- ------- ------- ------- ---+--- ------- ------- --+---- ------- -----+
+-----+
| id | user_id | domain_id | name | failed_auth_count | failed_auth_at |
+-----+
| 3 | 1e0099400dd34ad
| 6 | 8840d047cca346e
| 9 | d71b70de0cdd4be
| 12 | d0750dcc8905439
| 15 | c870e8dc427841c
| 18 | 964d6a7b3d8d4a4
| 21 | e1e77e91a9ed4dd
| 24 | d090c19794dd4f2
| 27 | 9fbb011ce1fc495
| 30 | 1bad96de0fcd41a
| 33 | f4da2edc5e8f461
| 36 | a4d97a3a5a6644e
| 39 | 4d827a03abb2485
| 42 | 63b4389e35e4461
| 45 | 3222d274dd0347a
| 48 | 957f4a409dec46c
| 51 | 8a89ed1cd198481
| 54 | 1ee61ad58f0948e
| 57 | 32475aeb4dc0469
| 60 | 79b9411206524f0
| 63 | 35257eb811d84e0
| 66 | d07d3c3c619c447
| 69 | 5f35abc07a2141d
| 72 | 6a615b68427a480
| 75 | 82762b9e71b0423
| 78 | 0f04dc8d78e045c
| 81 | d3b07f907b454f7
| 84 | e36723354245416
| 141 | 77e255c3967c400
| 165 | 713a08bae9dc464
| 168 | e17783fa996a4ff
| 171 | f110007ded3548e
| 175 | af7dd6f186a3407
+-----+
mysql> select * from federated_user;
+----+- ------- ------- ------- ------- -----+- ------- --+---- ------- --+---- ------- ------- ------- ------+ ------- ------- ------- ------- -+ ------- ------- ------- ------- -----+- ------- --+---- ------- --+---- ------- ------- ------- ------+ ------- ------- ------- ------- -+ 9b4563c9d69360c 86 | fs-voith | mapped | username1 | username1 | 89189a5b004829d 11 | fs-voith | mapped | username3 | username3 | faf46e891469515 24 | fs-voith | mapped | username2 | username2 | a92385620a28376 0d | fs-voith | mapped | username4 | username4 | ------- ------- ------- ------- -----+- ------- --+---- ------- --+---- ------- ------- ------- ------+ ------- ------- ------- ------- -+
| id | user_id | idp_id | protocol_id | unique_id | display_name |
+----+-
| 3 | e17783fa996a4ff
| 6 | af0c5dd0f10b46d
| 51 | f110007ded3548e
| 52 | abdbfae630834c0
+----+-