Skip to content

VM creation error Netbox v3.3.0 #220

@yaiqsa

Description

@yaiqsa

Hey there,

I have some issues that I guess are caused by the Netbox v3.3.0 update:

When running netbox-sync on a new database, I get the following errors:

  • First this one, about a site mismatch (I think the site field is just missing)
    2022-08-22 14:41:12,771 - INFO: Creating new NetBox 'virtual machine' object 'my-hostname' with data: {'tags': [{'name': 'NetBox-synced'}, {'name': 'Source: vcenter'}], 'name': 'my-hostname', 'cluster': 1,
     'status': 'active', 'memory': 8192, 'vcpus': 4, 'disk': 140, 'platform': 2, 'role': 2}
    2022-08-22 14:41:12,771 - DEBUG2: Sending POST to 'https://netbox.url/api/virtualization/virtual-machines/' with data 'b'{"tags": [{"name": "NetBox-synced"}, {"name": "Source: vcenter"
    }], "name": "my-hostname", "cluster": 1, "status": "active", "memory": 8192, "vcpus": 4, "disk": 140, "platform": 2, "role": 2}''.
    2022-08-22 14:41:12,804 - DEBUG2: Received HTTP Status 400.
    2022-08-22 14:41:12,804 - ERROR: NetBox returned: POST /api/virtualization/virtual-machines/ Bad Request
    2022-08-22 14:41:12,804 - ERROR: NetBox returned body: {'cluster': ['The selected cluster (my-cluster is not assigned to this site (None).']}
    2022-08-22 14:41:12,805 - ERROR: Request Failed for virtual machine. Used data: {'tags': [{'name': 'NetBox-synced'}, {'name': 'Source: vcenter'}], 'name': 'my-hostname', 'cluster': 1, 'status': 'active', 'memory': 8192, 'vcpus': 4, 'disk': 140, 'platform': 2, 'role': 2}
    2022-08-22 14:41:12,805 - DEBUG2: Adding unresolved dependencies back to object: ['primary_ip4']
    2022-08-22 14:41:12,805 - DEBUG2: Parsing 'virtual machine' data structure: my-hostname
    
  • Then this one, which I think is caused by the VM not being created:
    2022-08-22 14:41:22,441 - INFO: Creating new NetBox 'virtual machine interface' object 'vNIC 1 (Network) (my-hostname)' with data: {'tags': [{'name': 'NetBox-synced'}, {'name': 'Source: vcenter'}], 'name': 'vNIC 1 (Network)', 'mac_address': '10:00:00:00:00:01', 'description': 'Network adapter 1 (VirtualE1000e) (vlan ID: 0)', 'enabled': True, 'mtu': 9000, 'mode': 'access'}
    2022-08-22 14:41:22,441 - DEBUG2: Sending POST to 'https://netbox.url/api/virtualization/interfaces/' with data 'b'{"tags": [{"name": "NetBox-synced"}, {"name": "Source: vcenter"}], "name": "vNIC 1 (Network)", "mac_address": "10:00:00:00:00:01", "description": "Network adapter 1 (VirtualE1000e) (vlan ID: 0)", "enabled": true, "mtu": 9000, "mode": "access"}''.
    2022-08-22 14:41:22,469 - DEBUG2: Received HTTP Status 400.
    2022-08-22 14:41:22,470 - ERROR: NetBox returned: POST /api/virtualization/interfaces/ Bad Request
    2022-08-22 14:41:22,470 - ERROR: NetBox returned body: {'virtual_machine': ['This field is required.']}
    2022-08-22 14:41:22,470 - ERROR: Request Failed for virtual machine interface. Used data: {'tags': [{'name': 'NetBox-synced'}, {'name': 'Source: vcenter'}], 'name': 'vNIC 1 (Network)', 'mac_address': '10:00:00:00:00:01', 'description': 'Network adapter 1 (VirtualE1000e) (vlan ID: 0)', 'enabled': True, 'mtu': 9000, 'mode': 'access'}
    2022-08-22 14:41:22,470 - DEBUG2: Adding unresolved dependencies back to object: ['virtual_machine']
    2022-08-22 14:41:22,471 - DEBUG2: Parsing 'virtual machine interface' data structure: vNIC 1 (Network) (my-hostname)
    

When I use my production database I get some more errors, but they might be caused by these objects not being created properly.

Am I correct that this is a netbox 3.3.0 compatibility issue, or is it just my environment? And if it is an incompatibility, when might this be resolved?

Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    awaiting replyAwaiting reply from issue owner

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions