Bug 1746600

Summary: unable to remove duplicate guest devices due to memory
Product: Red Hat CloudForms Management Engine Reporter: Tuan <tuado>
Component: ProvidersAssignee: Adam Grare <agrare>
Status: CLOSED EOL QA Contact: Jaroslav Henner <jhenner>
Severity: high Docs Contact: Red Hat CloudForms Documentation <cloudforms-docs>
Priority: high    
Version: 5.10.8CC: dmetzger, jfrey, jhardy, mheppler, nansari, ngupta, niroy, obarenbo, simaishi
Target Milestone: GAKeywords: TestOnly, ZStream
Target Release: 5.12.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1757026 1767819 (view as bug list) Environment:
Last Closed: 2020-03-25 18:02:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: Bug
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: RHEVM Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1757026, 1767819    

Comment 2 Adam Grare 2019-08-29 11:58:19 UTC
This is the result of the previous code being wrong for so long, and creating so many duplicate records that when we try to delete them all it takes a lot of time and memory.

I created a utility to delete these so that the refresh worker can run normally, https://github.com/ManageIQ/manageiq/pull/19219

./tools/cleanup_duplicate_host_guest_devices.rb [--ems-name=EMS_NAME or --ems-id=EMS_ID] will query and print how many duplicates were found but not delete them.  Passing --no-dry-run will actually remove them.

Comment 3 Jaroslav Henner 2019-09-13 11:58:10 UTC
It seems to me I will need the customer DB for verifying this.

Comment 8 Satoe Imaishi 2019-11-01 13:29:51 UTC
Also need: https://github.com/ManageIQ/manageiq/pull/19235

Comment 10 Joe Rafaniello 2019-11-11 15:17:57 UTC
*** Bug 1767866 has been marked as a duplicate of this bug. ***

Comment 11 mheppler 2019-11-12 15:07:22 UTC
Hi,

Customer have question about this bug:

"And I would also like to know what was the background for this bug. Why was so many devices duplicated?"

Please, can you provide some valuable answer for customer?

Thank you, mheppler

Comment 18 Adam Grare 2020-05-12 12:03:26 UTC
*** Bug 1832715 has been marked as a duplicate of this bug. ***