ganeti icon indicating copy to clipboard operation
ganeti copied to clipboard

QA: test for resource queries assumes VGs are present

Open Ganeti-Issues-Migrator opened this issue 7 years ago • 6 comments

Originally reported of Google Code with ID 522.

<b>What steps will reproduce the problem?</b>
1. Run a QA with this configuration:
"enabled-disk-templates" : ["file"]
"instance-add-file" : "true"
all other instance-add: "false"

"Testing resource queries via remote API: fails:


---- 2013-07-09 15:50:23.650732 start Testing resource queries via remote API 
Command: ssh -oEscapeChar=none -oBatchMode=yes -lroot -t -oStrictHostKeyChecking=yes -oClearAllForwardings=yes -oForwardAgent=yes -oControlPath=/tmp/ganeti-qa-multiplexer.sHd11G -oControlMaster=no NODE1 'gnt-node info NODE1'
Shared connection to NODE1 closed.
GET /2/query/node/fields
GET /2/query/node/fields?fields=name,name,csockets
GET /2/query/node
GET /2/query/node?fields=csockets,dtotal,mtotal,ndparams,master_candidate,serial_no,name,role,ctime,sinst_list,uuid,custom_ndparams,cnodes,sptotal,hv_state,sinst_cnt,pinst_cnt,mfree,spfree,bootid,tags,drained,ctotal,vm_capable,disk_state,group,powered,sip,mtime,ndp/exclusive_storage,ndp/spindle_count,offline,master,cnos,mnode,pip,pinst_list,dfree,group.uuid,ndp/oob_program,master_capable
GET /2/query/node?fields=name
GET /2/query/node?fields=name,%20name%09,name%20
PUT /2/query/node?fields=name
PUT /2/query/node
PUT /2/query/node
PUT /2/query/node
PUT /2/query/node
GET /2/query/group/fields
GET /2/query/group/fields?fields=name,name,name
GET /2/query/group
GET /2/query/group?fields=name,pinst_cnt,ndp/oob_program,tags,node_cnt,ndp/exclusive_storage,custom_diskparams,mtime,custom_ipolicy,pinst_list,ndp/spindle_count,ipolicy,ctime,node_list,serial_no,custom_ndparams,diskparams,uuid,alloc_policy,ndparams
GET /2/query/group?fields=name
GET /2/query/group?fields=name,%20name%09,name%20
PUT /2/query/group?fields=name
PUT /2/query/group
PUT /2/query/group
PUT /2/query/group
GET /2/query/network/fields
GET /2/query/network/fields?fields=name,name,gateway6
GET /2/query/network
GET /2/query/network?fields=gateway6,inst_list,tags,network6,inst_cnt,reserved_count,name,external_reservations,map,network,group_list,uuid,group_cnt,mac_prefix,free_count,gateway,serial_no
GET /2/query/network?fields=name
GET /2/query/network?fields=name,%20name%09,name%20
PUT /2/query/network?fields=name
PUT /2/query/network
PUT /2/query/network
PUT /2/query/network
GET /2/query/cluster/fields
GET /2/query/cluster/fields?fields=name,name,ctime
GET /2/query/cluster
GET /2/query/cluster?fields=ctime,architecture,name,config_version,drain_flag,volume_group_name,mtime,software_version,tags,os_api_version,master_node,export_version,watcher_pause,cluster_name,protocol_version
---- 2013-07-09 15:50:58.331065 time=0:00:34.680333 Testing resource queries via remote API
Traceback (most recent call last):
  File "./ganeti-qa.py", line 923, in <module>
    main() 
  File "/ganeti/rapi/client.py", line 245, in wrapper
    return fn(*args, **kwargs)
  File "./ganeti-qa.py", line 918, in main
    RunQa()---- 2013-07-09 15:50:23.650732 start Testing resource queries via remote API 
Command: ssh -oEscapeChar=none -oBatchMode=yes -lroot -t -oStrictHostKeyChecking=yes -oClearAllForwardings=yes -oForwardAgent=yes -oControlPath=/tmp/ganeti-qa-multiplexer.sHd11G -oControlMaster=no NODE1 'gnt-node info NODE1'
Shared connection to NODE1 closed.
GET /2/query/node/fields
GET /2/query/node/fields?fields=name,name,csockets
GET /2/query/node
GET /2/query/node?fields=csockets,dtotal,mtotal,ndparams,master_candidate,serial_no,name,role,ctime,sinst_list,uuid,custom_ndparams,cnodes,sptotal,hv_state,sinst_cnt,pinst_cnt,mfree,spfree,bootid,tags,drained,ctotal,vm_capable,disk_state,group,powered,sip,mtime,ndp/exclusive_storage,ndp/spindle_count,offline,master,cnos,mnode,pip,pinst_list,dfree,group.uuid,ndp/oob_program,master_capable
GET /2/query/node?fields=name
GET /2/query/node?fields=name,%20name%09,name%20
PUT /2/query/node?fields=name
PUT /2/query/node
PUT /2/query/node
PUT /2/query/node
PUT /2/query/node
GET /2/query/group/fields
GET /2/query/group/fields?fields=name,name,name
GET /2/query/group
GET /2/query/group?fields=name,pinst_cnt,ndp/oob_program,tags,node_cnt,ndp/exclusive_storage,custom_diskparams,mtime,custom_ipolicy,pinst_list,ndp/spindle_count,ipolicy,ctime,node_list,serial_no,custom_ndparams,diskparams,uuid,alloc_policy,ndparams
GET /2/query/group?fields=name
GET /2/query/group?fields=name,%20name%09,name%20
PUT /2/query/group?fields=name
PUT /2/query/group
PUT /2/query/group
PUT /2/query/group
GET /2/query/network/fields
GET /2/query/network/fields?fields=name,name,gateway6
GET /2/query/network
GET /2/query/network?fields=gateway6,inst_list,tags,network6,inst_cnt,reserved_count,name,external_reservations,map,network,group_list,uuid,group_cnt,mac_prefix,free_count,gateway,serial_no
GET /2/query/network?fields=name
GET /2/query/network?fields=name,%20name%09,name%20
PUT /2/query/network?fields=name
PUT /2/query/network
PUT /2/query/network
PUT /2/query/network
GET /2/query/cluster/fields
GET /2/query/cluster/fields?fields=name,name,ctime
GET /2/query/cluster
GET /2/query/cluster?fields=ctime,architecture,name,config_version,drain_flag,volume_group_name,mtime,software_version,tags,os_api_version,master_node,export_version,watcher_pause,cluster_name,protocol_version
---- 2013-07-09 15:50:58.331065 time=0:00:34.680333 Testing resource queries via remote API
Traceback (most recent call last):
  File "./ganeti-qa.py", line 923, in <module>
    main() 
  File "/ganeti/rapi/client.py", line 245, in wrapper
    return fn(*args, **kwargs)
  File "./ganeti-qa.py", line 918, in main
    RunQa()
  File "./ganeti-qa.py", line 772, in RunQa
    RunClusterTests()
  File "./ganeti-qa.py", line 234, in RunClusterTests
    RunTestIf(test, fn)
  File "./ganeti-qa.py", line 111, in RunTestIf
    RunTest(fn, *args, **kwargs)
  File "./ganeti-qa.py", line 95, in RunTest
    retval = fn(*args, **kwargs)
  File "/ganeti/qa/qa_rapi.py", line 332, in TestRapiQuery
    "fields": [namefield] * 4,
  File "/ganeti/qa/qa_rapi.py", line 150, in _DoTests
    data = _rapi_client._SendRequest(method, uri, None, body)
  File "/ganeti/rapi/client.py", line 550, in _SendRequest
    raise GanetiApiError(msg, code=http_code)
ganeti.rapi.client.GanetiApiError: 500 Internal assertion error: please report this as a bug.
Error message: 'Failed validation: normal field volume_group_name fails validation (value is None) in row [(0, 1373377129.935143), (0, ('64bit', 'x86_64')), (0, 'CLUSTER'), (0, 2090000), (0, False), (0, None), (0, 1373377809.2898901), (0, '2.9.0~alpha1'), (0, []), (0, 20), (0, 'NODE1'), (0, 0), (3, None), (0, 'CLUSTER'), (0, 2090000)]'; location:
  File "/usr/local/lib/python2.6/dist-packages/ganeti/query.py", line 830, in _VerifyResultRow
    (utils.CommaJoin(errs), row))
: Server got itself in trouble

real    12m50.421s
user    0m16.830s
sys     0m6.580s

~                                                                                                                                   
~                                              
  File "./ganeti-qa.py", line 772, in RunQa
    RunClusterTests()
  File "./ganeti-qa.py", line 234, in RunClusterTests
    RunTestIf(test, fn)
  File "./ganeti-qa.py", line 111, in RunTestIf
    RunTest(fn, *args, **kwargs)
  File "./ganeti-qa.py", line 95, in RunTest
    retval = fn(*args, **kwargs)
  File "/ganeti/qa/qa_rapi.py", line 332, in TestRapiQuery
    "fields": [namefield] * 4,
  File "/ganeti/qa/qa_rapi.py", line 150, in _DoTests
    data = _rapi_client._SendRequest(method, uri, None, body)
  File "/ganeti/rapi/client.py", line 550, in _SendRequest
    raise GanetiApiError(msg, code=http_code)
ganeti.rapi.client.GanetiApiError: 500 Internal assertion error: please report this as a bug.
Error message: 'Failed validation: normal field volume_group_name fails validation (value is None) in row [(0, 1373377129.935143), (0, ('64bit', 'x86_64')), (0, 'CLUSTER'), (0, 2090000), (0, False), (0, None), (0, 1373377809.2898901), (0, '2.9.0~alpha1'), (0, []), (0, 20), (0, 'NODE1'), (0, 0), (3, None), (0, 'CLUSTER'), (0, 2090000)]'; location:
  File "/usr/local/lib/python2.6/dist-packages/ganeti/query.py", line 830, in _VerifyResultRow
    (utils.CommaJoin(errs), row))
: Server got itself in trouble

real    12m50.421s
user    0m16.830s
sys     0m6.580s
---- 2013-07-09 15:50:23.650732 start Testing resource queries via remote API 
Command: ssh -oEscapeChar=none -oBatchMode=yes -lroot -t -oStrictHostKeyChecking=yes -oClearAllForwardings=yes -oForwardAgent=yes -oControlPath=/tmp/ganeti-qa-multiplexer.sHd11G -oControlMaster=no NODE1 'gnt-node info NODE1'
Shared connection to NODE1 closed.
GET /2/query/node/fields
GET /2/query/node/fields?fields=name,name,csockets
GET /2/query/node
GET /2/query/node?fields=csockets,dtotal,mtotal,ndparams,master_candidate,serial_no,name,role,ctime,sinst_list,uuid,custom_ndparams,cnodes,sptotal,hv_state,sinst_cnt,pinst_cnt,mfree,spfree,bootid,tags,drained,ctotal,vm_capable,disk_state,group,powered,sip,mtime,ndp/exclusive_storage,ndp/spindle_count,offline,master,cnos,mnode,pip,pinst_list,dfree,group.uuid,ndp/oob_program,master_capable
GET /2/query/node?fields=name
GET /2/query/node?fields=name,%20name%09,name%20
PUT /2/query/node?fields=name
PUT /2/query/node
PUT /2/query/node
PUT /2/query/node
PUT /2/query/node
GET /2/query/group/fields
GET /2/query/group/fields?fields=name,name,name
GET /2/query/group
GET /2/query/group?fields=name,pinst_cnt,ndp/oob_program,tags,node_cnt,ndp/exclusive_storage,custom_diskparams,mtime,custom_ipolicy,pinst_list,ndp/spindle_count,ipolicy,ctime,node_list,serial_no,custom_ndparams,diskparams,uuid,alloc_policy,ndparams
GET /2/query/group?fields=name
GET /2/query/group?fields=name,%20name%09,name%20
PUT /2/query/group?fields=name
PUT /2/query/group
PUT /2/query/group
PUT /2/query/group
GET /2/query/network/fields
GET /2/query/network/fields?fields=name,name,gateway6
GET /2/query/network
GET /2/query/network?fields=gateway6,inst_list,tags,network6,inst_cnt,reserved_count,name,external_reservations,map,network,group_list,uuid,group_cnt,mac_prefix,free_count,gateway,serial_no
GET /2/query/network?fields=name
GET /2/query/network?fields=name,%20name%09,name%20
PUT /2/query/network?fields=name
PUT /2/query/network
PUT /2/query/network
PUT /2/query/network
GET /2/query/cluster/fields
GET /2/query/cluster/fields?fields=name,name,ctime
GET /2/query/cluster
GET /2/query/cluster?fields=ctime,architecture,name,config_version,drain_flag,volume_group_name,mtime,software_version,tags,os_api_version,master_node,export_version,watcher_pause,cluster_name,protocol_version
---- 2013-07-09 15:50:58.331065 time=0:00:34.680333 Testing resource queries via remote API
Traceback (most recent call last):
  File "./ganeti-qa.py", line 923, in <module>
    main() 
  File "/ganeti/rapi/client.py", line 245, in wrapper
    return fn(*args, **kwargs)
  File "./ganeti-qa.py", line 918, in main
    RunQa()
  File "./ganeti-qa.py", line 772, in RunQa
    RunClusterTests()
  File "./ganeti-qa.py", line 234, in RunClusterTests
    RunTestIf(test, fn)
  File "./ganeti-qa.py", line 111, in RunTestIf
    RunTest(fn, *args, **kwargs)
  File "./ganeti-qa.py", line 95, in RunTest
    retval = fn(*args, **kwargs)
  File "/ganeti/qa/qa_rapi.py", line 332, in TestRapiQuery
    "fields": [namefield] * 4,
  File "/ganeti/qa/qa_rapi.py", line 150, in _DoTests
    data = _rapi_client._SendRequest(method, uri, None, body)
  File "/ganeti/rapi/client.py", line 550, in _SendRequest
    raise GanetiApiError(msg, code=http_code)
ganeti.rapi.client.GanetiApiError: 500 Internal assertion error: please report this as a bug.
Error message: 'Failed validation: normal field volume_group_name fails validation (value is None) in row [(0, 1373377129.935143), (0, ('64bit', 'x86_64')), (0, 'CLUSTER'), (0, 2090000), (0, False), (0, None), (0, 1373377809.2898901), (0, '2.9.0~alpha1'), (0, []), (0, 20), (0, 'NODE1'), (0, 0), (3, None), (0, 'CLUSTER'), (0, 2090000)]'; location:
  File "/usr/local/lib/python2.6/dist-packages/ganeti/query.py", line 830, in _VerifyResultRow
    (utils.CommaJoin(errs), row))
: Server got itself in trouble

I guess the test should make sure that it is skipped if no LVM disk template is enabled.
~                                                                                                                                   
~                                              
~                                                                                                                                   
~                                              

Originally added on 2013-07-10 09:03:14 +0000 UTC.

Ganeti-Issues-Migrator avatar Jun 23 '17 12:06 Ganeti-Issues-Migrator

-- Empty comment --

Originally added on 2013-08-27 07:48:57 +0000 UTC.

Changed State: Accepted Added to Milestone: Release2.10

Ganeti-Issues-Migrator avatar Jun 23 '17 14:06 Ganeti-Issues-Migrator

Move all issues assigned to 2.10 to 2.11, because their priority would not justify an inclusion in 2.10.

Originally added on 2014-02-19 10:07:59 +0000 UTC.

Added to Milestone: Release2.11 Removed from Milestone: Release2.10

Ganeti-Issues-Migrator avatar Jun 23 '17 23:06 Ganeti-Issues-Migrator

Moving all issues that won't be addressed in 2.11 anymore to 2.12.

Originally added on 2014-05-14 11:28:37 +0000 UTC.

Added to Milestone: Release2.12 Removed from Milestone: Release2.11

Ganeti-Issues-Migrator avatar Jun 24 '17 05:06 Ganeti-Issues-Migrator

Removed the milestone as it's long past. As an effort to migrate all our issues to Github, I'll let someone from the community pick it up if they are interested. We'd be happy to accept patches about this.

See https://groups.google.com/forum/#!topic/ganeti/b2-eukpsXpk for more details.

Originally added on 2016-12-15 11:30:40 +0000 UTC.

Changed State: PatchesWelcome Removed from Milestone: Release2.12

Ganeti-Issues-Migrator avatar Jun 25 '17 04:06 Ganeti-Issues-Migrator

feature: tests

geor-g avatar Sep 26 '18 13:09 geor-g

could this be a duplicate of #208?

anarcat avatar Jul 06 '20 19:07 anarcat