Bug 1319591

Summary: hosted-engine --vm-status displays more than three hosts
Product: [oVirt] ovirt-hosted-engine-setup Reporter: RamaKasturi <knarra>
Component: ToolsAssignee: bugs <bugs>
Status: CLOSED NOTABUG QA Contact: meital avital <mavital>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: ---CC: bugs, didi, knarra, sabose, sbonazzo
Target Milestone: ovirt-4.1.0-betaFlags: sbonazzo: needinfo? (didi)
sabose: ovirt-4.1?
rule-engine: planning_ack?
rule-engine: devel_ack?
rule-engine: testing_ack?
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-12-27 08:01:04 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Gluster RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description RamaKasturi 2016-03-21 07:19:51 UTC
Description of problem:
hosted-engine --vm-status displays hosts more than three. When there are only three hosts added it should display only three.

[root@rhsqa1 ~]# hosted-engine --vm-status


--== Host 1 status ==--

Status up-to-date                  : False
Hostname                           : rhsqa1.lab.eng.blr.redhat.com
Host ID                            : 1
Engine status                      : unknown stale-data
Score                              : 3400
stopped                            : False
Local maintenance                  : False
crc32                              : 26283223
Host timestamp                     : 337712


--== Host 2 status ==--

Status up-to-date                  : False
Hostname                           : rhsqa3.lab.eng.blr.redhat.com
Host ID                            : 2
Engine status                      : unknown stale-data
Score                              : 0
stopped                            : False
Local maintenance                  : True
crc32                              : 272f6de9
Host timestamp                     : 249347


--== Host 3 status ==--

Status up-to-date                  : False
Hostname                           : rhsqa6.lab.eng.blr.redhat.com
Host ID                            : 3
Engine status                      : unknown stale-data
Score                              : 0
stopped                            : True
Local maintenance                  : False
crc32                              : cdae9b54
Host timestamp                     : 204537


--== Host 4 status ==--

Status up-to-date                  : False
Hostname                           : rhsqa6.lab.eng.blr.redhat.com
Host ID                            : 4
Engine status                      : unknown stale-data
Score                              : 0
stopped                            : True
Local maintenance                  : False
crc32                              : 8c3e6ebf
Host timestamp                     : 241621


--== Host 5 status ==--

Status up-to-date                  : False
Hostname                           : rhsqa6.lab.eng.blr.redhat.com
Host ID                            : 5
Engine status                      : unknown stale-data
Score                              : 3400
stopped                            : False
Local maintenance                  : False
crc32                              : 0e52be6d
Host timestamp                     : 336010


Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Add first host to hosted-engine deploy by running the command 'hosted-engine --deploy"
2. Now add the second host by running the command 'hosted-engine --deploy --answers.conf file and make sure that if fails.
3. Now run the command to add the host, while adding the host there is a question which asks to enter the host identification number. If you put 2, it complains saying the host is already there. Then you enter 3.
4. wait for the host to successfully add to the engine.
5. Run hosted-engine deploy command to add the third host and wait for the hos to get added successfully.

Actual results:
Once the host addition is successful, run the command 'hosted-engine --vm-status' this command displays 4 hosts even though there are three.

Expected results:
hosted-engine --vm-status command should the correct number of hosts.

Additional info:

Comment 1 Yedidyah Bar David 2016-03-21 09:18:59 UTC
(In reply to RamaKasturi from comment #0)
> Description of problem:
> hosted-engine --vm-status displays hosts more than three. When there are
> only three hosts added it should display only three.
> 
> [root@rhsqa1 ~]# hosted-engine --vm-status
> 
> 
> --== Host 1 status ==--
> 
> Status up-to-date                  : False
> Hostname                           : rhsqa1.lab.eng.blr.redhat.com
> Host ID                            : 1
> Engine status                      : unknown stale-data
> Score                              : 3400
> stopped                            : False
> Local maintenance                  : False
> crc32                              : 26283223
> Host timestamp                     : 337712
> 
> 
> --== Host 2 status ==--
> 
> Status up-to-date                  : False
> Hostname                           : rhsqa3.lab.eng.blr.redhat.com
> Host ID                            : 2
> Engine status                      : unknown stale-data
> Score                              : 0
> stopped                            : False
> Local maintenance                  : True
> crc32                              : 272f6de9
> Host timestamp                     : 249347
> 
> 
> --== Host 3 status ==--
> 
> Status up-to-date                  : False
> Hostname                           : rhsqa6.lab.eng.blr.redhat.com
> Host ID                            : 3
> Engine status                      : unknown stale-data
> Score                              : 0
> stopped                            : True
> Local maintenance                  : False
> crc32                              : cdae9b54
> Host timestamp                     : 204537
> 
> 
> --== Host 4 status ==--
> 
> Status up-to-date                  : False
> Hostname                           : rhsqa6.lab.eng.blr.redhat.com
> Host ID                            : 4
> Engine status                      : unknown stale-data
> Score                              : 0
> stopped                            : True
> Local maintenance                  : False
> crc32                              : 8c3e6ebf
> Host timestamp                     : 241621
> 
> 
> --== Host 5 status ==--
> 
> Status up-to-date                  : False
> Hostname                           : rhsqa6.lab.eng.blr.redhat.com
> Host ID                            : 5
> Engine status                      : unknown stale-data
> Score                              : 3400
> stopped                            : False
> Local maintenance                  : False
> crc32                              : 0e52be6d
> Host timestamp                     : 336010
> 
> 
> Version-Release number of selected component (if applicable):
> 
> 
> How reproducible:
> Always
> 
> Steps to Reproduce:
> 1. Add first host to hosted-engine deploy by running the command
> 'hosted-engine --deploy"
> 2. Now add the second host by running the command 'hosted-engine --deploy
> --answers.conf file and make sure that if fails.

It depends on when exactly it fails.

> 3. Now run the command to add the host, while adding the host there is a
> question which asks to enter the host identification number. If you put 2,
> it complains saying the host is already there. Then you enter 3.

Which version?

In 3.6, you can enter an existing number, and you'll be asked if you are reinstalling.

> 4. wait for the host to successfully add to the engine.
> 5. Run hosted-engine deploy command to add the third host and wait for the
> hos to get added successfully.
> 
> Actual results:
> Once the host addition is successful, run the command 'hosted-engine
> --vm-status' this command displays 4 hosts even though there are three.
> 
> Expected results:
> hosted-engine --vm-status command should the correct number of hosts.
> 
> Additional info:

See also bug 1116469 (eng) and bug 1293971 (doc), which add/document commands to clean up the metadata.

I think we can close as duplicate. If you want something else, please provide more details. Thanks.

Comment 2 RamaKasturi 2016-03-24 06:21:08 UTC
(In reply to Yedidyah Bar David from comment #1)
> (In reply to RamaKasturi from comment #0)
> > Description of problem:
> > hosted-engine --vm-status displays hosts more than three. When there are
> > only three hosts added it should display only three.
> > 
> > [root@rhsqa1 ~]# hosted-engine --vm-status
> > 
> > 
> > --== Host 1 status ==--
> > 
> > Status up-to-date                  : False
> > Hostname                           : rhsqa1.lab.eng.blr.redhat.com
> > Host ID                            : 1
> > Engine status                      : unknown stale-data
> > Score                              : 3400
> > stopped                            : False
> > Local maintenance                  : False
> > crc32                              : 26283223
> > Host timestamp                     : 337712
> > 
> > 
> > --== Host 2 status ==--
> > 
> > Status up-to-date                  : False
> > Hostname                           : rhsqa3.lab.eng.blr.redhat.com
> > Host ID                            : 2
> > Engine status                      : unknown stale-data
> > Score                              : 0
> > stopped                            : False
> > Local maintenance                  : True
> > crc32                              : 272f6de9
> > Host timestamp                     : 249347
> > 
> > 
> > --== Host 3 status ==--
> > 
> > Status up-to-date                  : False
> > Hostname                           : rhsqa6.lab.eng.blr.redhat.com
> > Host ID                            : 3
> > Engine status                      : unknown stale-data
> > Score                              : 0
> > stopped                            : True
> > Local maintenance                  : False
> > crc32                              : cdae9b54
> > Host timestamp                     : 204537
> > 
> > 
> > --== Host 4 status ==--
> > 
> > Status up-to-date                  : False
> > Hostname                           : rhsqa6.lab.eng.blr.redhat.com
> > Host ID                            : 4
> > Engine status                      : unknown stale-data
> > Score                              : 0
> > stopped                            : True
> > Local maintenance                  : False
> > crc32                              : 8c3e6ebf
> > Host timestamp                     : 241621
> > 
> > 
> > --== Host 5 status ==--
> > 
> > Status up-to-date                  : False
> > Hostname                           : rhsqa6.lab.eng.blr.redhat.com
> > Host ID                            : 5
> > Engine status                      : unknown stale-data
> > Score                              : 3400
> > stopped                            : False
> > Local maintenance                  : False
> > crc32                              : 0e52be6d
> > Host timestamp                     : 336010
> > 
> > 
> > Version-Release number of selected component (if applicable):
> > 
> > 
> > How reproducible:
> > Always
> > 
> > Steps to Reproduce:
> > 1. Add first host to hosted-engine deploy by running the command
> > 'hosted-engine --deploy"
> > 2. Now add the second host by running the command 'hosted-engine --deploy
> > --answers.conf file and make sure that if fails.
> 
> It depends on when exactly it fails.

In my case while adding the second host it keeps on saying, waiting for the vdsm to be operational for a long a time and just fails.
> 
> > 3. Now run the command to add the host, while adding the host there is a
> > question which asks to enter the host identification number. If you put 2,
> > it complains saying the host is already there. Then you enter 3.
> 
> Which version?
> 
> In 3.6, you can enter an existing number, and you'll be asked if you are
> reinstalling.

I tried to giving the existing number but i think it did not work. I will have to check this again.

> 
> > 4. wait for the host to successfully add to the engine.
> > 5. Run hosted-engine deploy command to add the third host and wait for the
> > hos to get added successfully.
> > 
> > Actual results:
> > Once the host addition is successful, run the command 'hosted-engine
> > --vm-status' this command displays 4 hosts even though there are three.
> > 
> > Expected results:
> > hosted-engine --vm-status command should the correct number of hosts.
> > 
> > Additional info:
> 
> See also bug 1116469 (eng) and bug 1293971 (doc), which add/document
> commands to clean up the metadata.

Instead of closing this as duplicate, we can put the commands which is used to clean metadata and close this saying not a bug. Does that work?
> 
> I think we can close as duplicate. If you want something else, please
> provide more details. Thanks.

Comment 3 Sahina Bose 2016-12-27 08:01:04 UTC
Refer Bug 1293971 for procedure to clean metadata