0-complexity / openvcloud

OpenvCloud
Other
2 stars 4 forks source link

AttributeError: 'cloudbroker_externalnetwork' object has no attribute 'pingsips' #1763

Closed FastGeert closed 6 years ago

FastGeert commented 6 years ago
Application Name jumpscale:worker:process
Category  
Job N/A
Type UNKNOWN
Level CRITICAL
State NEW
Creation Time 3-7-2018 21:56:20
Last Time 4-9-2018 11:57:17
Occurrences 6
Error Message Pub  
Function Name execute_ping_test
Function Line Number 275
Function File Name /tmp/jumpscripts/cloudscalers_deployment_test.py
Node cpu-12.ch-gen-1 (13)
Grid ch-gen-1(222)
------------------------------------------------------------------------------------------
  /tmp/jumpscripts/cloudscalers_deployment_test.py(line 297) (function action)
  ========== STACKFRAME==========

            account = vmachine['accounts'][0]
            connection = j.remote.cuisine.connect(externalip, publicport, account['password'], account['login'])
            connection.user(account['login'])
            connection.fabric.api.env['abort_on_prompts'] = True
            connection.fabric.api.env['abort_exception'] = RuntimeError
            execute_ssh_command(connection)
            execute_dd_test(connection)
-->         execute_ping_test(cloudspace, connection)
        except DeployMentTestFailure:
            pass  # exception is already handled
        except Exception as e:
            eco = j.errorconditionhandler.processPythonExceptionObject(e)
            eco.process()
            msg = "Unexpected error during deployment test [eco|/grid/error condition?id={}]".format(eco.guid)
            messages.append({'message': msg, 'category': category, 'state': "ERROR"})
  ============ LOCALS============
    ACCOUNTNAME : test_deployment
    CLOUDSPACENAME : ch-lug-dc01-001
    DeployMentTestFailure : <class 'JumpScale.jumpscript_b0e2b385ba2f2cb639d831c05bbec235.DeployMentTestFailure'>
    account : {u'password': u'jP5z2x8yU', u'login': u'cloudscalers', u'guid': u''}
    category : Deployment Test
    ccl : <JumpScale.grid.osis.OSISFactory.NameSpaceClient object at 0x7fc8e1b30110>
    check_stack : <function check_stack at 0x7fc8e3deb500>
    cloudspace : {u'updateTime': 1528703253, u'_meta': [u'osismodel', u'cloudbroker', u'cloudspace', 1], u'resourceLimits': {u'CU_M': -1.0, u'CU_D': -1, u'CU_NP': -1, u'CU_I': -1, u'CU_C': -1}, u'guid': 149, u'id': 149, u'accountId': 1, u'networkId': 141, u'deletionTime': 0, u'descr': u'', u'resourceProviderStacks': [], u'secret': u'19eb7d90-2e79-479d-aa63-5d092b06583c', u'gid': 222, u'location': u'ch-lug-dc01-001', u'externalnetworkId': 1, u'status': u'DEPLOYED', u'externalnetworkip': u'185.15.201.96/26', u'privatenetwork': u'192.168.103.0/24', u'name': u'ch-lug-dc01-001', u'allowedVMSizes': [], u'creationTime': 1528703189, u'acl': [{u'status': u'CONFIRMED', u'guid': u'', u'right': u'CXDRAU', u'type': u'U', u'userGroupId': u'admin'}, {u'status': u'CONFIRMED', u'guid': u'', u'right': u'ARCXDU', u'type': u'U', u'userGroupId': u'shafikd@itsyouonline'}], u'_ckey': u''}
    create_fwd : <function create_fwd at 0x7fc8e1b2e578>
    e : 'cloudbroker_externalnetwork' object has no attribute 'pingsips'
    execute_dd_test : <function execute_dd_test at 0x7fc8e1b2e758>
    execute_ping_test : <function execute_ping_test at 0x7fc8e1b2e7d0>
    execute_ssh_command : <function execute_ssh_command at 0x7fc8e1b2e668>
    externalip : 185.15.201.96
    get_account : <function get_account at 0x7fc8e1b2e398>
    get_cloudspace : <function get_cloudspace at 0x7fc8e1b2e488>
    get_create_vm : <function get_create_vm at 0x7fc8e1b2e500>
    get_image : <function get_image at 0x7fc8e1b2e410>
    image : {u'username': None, u'status': u'CREATED', u'acl': [], u'password': u'', u'description': u'', u'UNCPath': u'', u'size': 10, u'_meta': [u'cloudbroker', u'image', 1], u'referenceId': u'278ee585-3cb5-4d9b-b932-b932ab76c185', u'id': 1, u'gid': 222, u'provider_name': u'libvirt', u'guid': 1, u'type': u'Linux', u'accountId': 0, u'_ckey': u'', u'name': u'Ubuntu 16.04 x64'}
    imagename : Ubuntu 16.04 x64
    loc : ch-lug-dc01-001
    messages : [{'category': 'Deployment Test', 'message': 'Stack is in status ENABLED', 'uid': 'deployment_Stack_Status:cpu-12.ch-gen-1', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Found image Ubuntu 16.04 x64', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Found account test_deployment', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Found cloudspace ch-lug-dc01-001', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'VM already deployed redeploying at {{ts:1530725110}}', 'state': 'SKIPPED', 'uid': 'deploymenttest-vm'}, {'category': 'Deployment Test', 'message': 'Cloudspace in DEPLOYED state', 'deployment:waitspace': 'deployment:waitspace', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Created port forward 3300', 'state': 'OK', 'createfwd': 'createfwd'}, {'category': 'Deployment Test', 'message': 'TCP port 185.15.201.96:3300 reachable', 'state': 'OK', 'deployment:connectvm': 'deployment:connectvm'}, {'category': 'Deployment Test', 'message': 'Logged in via SSH and executed command', 'deployment:ssh': 'deployment:ssh', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Measured write speed on disk was 115.0MB/s', 'state': 'OK', 'uid': 'deployment:dd_test'}]
    pcl : <JumpScale.portal.portal.PortalClient.PortalClient instance at 0x7fc8e1b24c20>
    stack : {u'status': u'ENABLED', u'apikey': u'', u'_meta': [u'osismodel', u'cloudbroker', u'stack', 1], u'descr': u'libvirt node', u'eco': None, u'appId': u'', u'id': 13, u'passwd': u'', u'referenceId': u'13', u'error': 0, u'images': [1, 2, 8, 9, 10, 11, 12, 5, 16, 17], u'gid': 222, u'login': u'', u'guid': 13, u'type': u'LIBVIRT', u'apiUrl': u'qemu+ssh://10.8.1.22/system', u'name': u'cpu-12.ch-gen-1'}
    vmachine : {u'cloudspaceid': 149, u'status': u'RUNNING', u'updateTime': 1530638770, u'disks': [{u'status': u'', u'sizeMax': 10, u'name': u'Boot disk', u'descr': u'Machine disk of type B', u'acl': {}, u'type': u'B', u'id': 9495}, {u'status': u'', u'sizeMax': 10, u'name': u'Disk nr 1', u'descr': u'Machine disk of type D', u'acl': {}, u'type': u'D', u'id': 9496}, {u'status': u'', u'sizeMax': 0, u'name': u'Metadata iso', u'descr': u'', u'acl': {}, u'type': u'M', u'id': 9497}], u'locked': False, u'name': u'Tue Jul  3 19:26:00 2018 on cpu-12.ch-gen-1', u'storage': 20, u'sizeid': 1, u'hostname': u'vm-3685', u'creationTime': 1530638710, u'osImage': u'Ubuntu 16.04 x64', u'acl': [{u'status': u'CONFIRMED', u'type': u'U', u'right': u'ACDRUX', u'canBeDeleted': False, u'userGroupId': u'admin'}, {u'status': u'CONFIRMED', u'type': u'U', u'right': u'ACDRUX', u'canBeDeleted': False, u'userGroupId': u'deboeckj@itsyouonline'}, {u'status': u'CONFIRMED', u'type': u'U', u'right': u'ACDRUX', u'canBeDeleted': False, u'userGroupId': u'shafikd@itsyouonline'}], u'vcpus': 1, u'accounts': [{u'password': u'jP5z2x8yU', u'login': u'cloudscalers', u'guid': u''}], u'memory': 512, u'id': 3685, u'imageid': 1, u'interfaces': [{u'status': u'', u'macAddress': u'52:54:00:00:09:d3', u'referenceId': u'', u'deviceName': u'vm-3685-008d', u'type': u'bridge', u'params': u'', u'networkId': 0, u'guid': u'', u'ipAddress': u'192.168.103.245'}], u'description': None}
    wait_for_connection : <function wait_for_connection at 0x7fc8e1b2e5f0>
    waitforspace : <function waitforspace at 0x7fc8e1b2e6e0>

------------------------------------------------------------------------------------------
  /tmp/jumpscripts/cloudscalers_deployment_test.py(line 275) (function execute_ping_test)
  ========== STACKFRAME==========
                try:
                    connection.run('ping -c 1 {}'.format(ip))
                    messages.append({'message': "Pinged {} from vm".format(ip),
                                     'category': category, 'state': 'OK', 'uid': uid})
                    break
                except:
                    continue
            else:
-->             messages.append({'message': 'Failed to ping {} from vm'.format(', '.join(pool.pingsips)),
                                 'category': category, 'state': 'ERROR', 'uid': uid})

        try:
            stack = check_stack()
            image = get_image(stack)
            accountId = get_account()
  ============ LOCALS============
    category : Deployment Test
    ccl : <JumpScale.grid.osis.OSISFactory.NameSpaceClient object at 0x7fc8e1b30110>
    cloudspace : {u'updateTime': 1528703253, u'_meta': [u'osismodel', u'cloudbroker', u'cloudspace', 1], u'resourceLimits': {u'CU_M': -1.0, u'CU_D': -1, u'CU_NP': -1, u'CU_I': -1, u'CU_C': -1}, u'guid': 149, u'id': 149, u'accountId': 1, u'networkId': 141, u'deletionTime': 0, u'descr': u'', u'resourceProviderStacks': [], u'secret': u'19eb7d90-2e79-479d-aa63-5d092b06583c', u'gid': 222, u'location': u'ch-lug-dc01-001', u'externalnetworkId': 1, u'status': u'DEPLOYED', u'externalnetworkip': u'185.15.201.96/26', u'privatenetwork': u'192.168.103.0/24', u'name': u'ch-lug-dc01-001', u'allowedVMSizes': [], u'creationTime': 1528703189, u'acl': [{u'status': u'CONFIRMED', u'guid': u'', u'right': u'CXDRAU', u'type': u'U', u'userGroupId': u'admin'}, {u'status': u'CONFIRMED', u'guid': u'', u'right': u'ARCXDU', u'type': u'U', u'userGroupId': u'shafikd@itsyouonline'}], u'_ckey': u''}
    ip : 8.8.8.8
    messages : [{'category': 'Deployment Test', 'message': 'Stack is in status ENABLED', 'uid': 'deployment_Stack_Status:cpu-12.ch-gen-1', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Found image Ubuntu 16.04 x64', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Found account test_deployment', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Found cloudspace ch-lug-dc01-001', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'VM already deployed redeploying at {{ts:1530725110}}', 'state': 'SKIPPED', 'uid': 'deploymenttest-vm'}, {'category': 'Deployment Test', 'message': 'Cloudspace in DEPLOYED state', 'deployment:waitspace': 'deployment:waitspace', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Created port forward 3300', 'state': 'OK', 'createfwd': 'createfwd'}, {'category': 'Deployment Test', 'message': 'TCP port 185.15.201.96:3300 reachable', 'state': 'OK', 'deployment:connectvm': 'deployment:connectvm'}, {'category': 'Deployment Test', 'message': 'Logged in via SSH and executed command', 'deployment:ssh': 'deployment:ssh', 'state': 'OK'}, {'category': 'Deployment Test', 'message': 'Measured write speed on disk was 115.0MB/s', 'state': 'OK', 'uid': 'deployment:dd_test'}]
    pool : {
  "_ckey": "", 
  "_meta": [
    "osismodel", 
    "cloudbroker", 
    "externalnetwork", 
    1
  ], 
  "accountId": 0, 
  "gateway": "185.15.201.65", 
  "gid": 222, 
  "guid": 1, 
  "id": 1, 
  "ips": [
    "185.15.201.72", 
    "185.15.201.105", 
    "185.15.201.115", 
    "185.15.201.103", 
    "185.15.201.83", 
    "185.15.201.82", 
    "185.15.201.92", 
    "185.15.201.89", 
    "185.15.201.107", 
    "185.15.201.117", 
    "185.15.201.114", 
    "185.15.201.116", 
    "185.15.201.74"
  ], 
  "name": "Default Network", 
  "network": "185.15.201.64", 
  "pingips": [
    "8.8.8.8"
  ], 
  "subnetmask": "255.255.255.192", 
  "vlan": 2312
}
    uid : deployement:ping public ip