Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multisite VCenter issue #421

Open
LooPep opened this issue Oct 28, 2024 · 1 comment
Open

Multisite VCenter issue #421

LooPep opened this issue Oct 28, 2024 · 1 comment

Comments

@LooPep
Copy link

LooPep commented Oct 28, 2024

Hey,

We have two IT infrastructures (let's say IT1 and IT2) on two differents sites (distinct perimeters), using different VCenters. Netbox-sync is already running (working good) on IT1 and connected to our unique Netbox instance (v3.7.4), and I want to run a new Netbox-sync on IT2.

The problem is, when running Netbox-sync on IT2 with it's own 'settings.ini' config file with 'permitted_subnets' correctly configured, all of the IT1 perimeter is getting overwrite and all of the IT1 VM's are getting 'Orphaned' Tag.

It seems that IT2 Netbox-sync ignores it's 'permitted_subnets' flag and is editing all of the items registered in Netbox.

IT2 Netbox-sync config sample :

[source/otpo1]

# Defines if this source is enabled or not
enabled = True

# type of source. This defines which source handler to use.
# Currently supported
#   * vmware    : VMWare vcenter
type = vmware

# host name / IP address of the vCenter
host_fqdn = 172.17.*.*

# TCP port to connect to
port = 443

# username and password to use to log into vCenter
username = ***************
password = **************

permitted_subnets = 172.17.0.0/16

cluster_site_relation = .* = Multisite EU-PO
cluster_tenant_relation = .* = INFRA-IT2
host_role_relation = .* = ESXi
vm_role_relation = .* = VMserver

collect_hardware_asset_tag = True

dns_name_lookup = True

# Do not sync notes from a VM in vCenter to the comments field on a VM in netbox
skip_vm_comments = False

# Do not sync template VMs
skip_vm_templates = True

# sync custom attributes defined for hosts and VMs in vCenter to NetBox as custom fields
#sync_custom_attributes = False
sync_custom_attributes = True

; enabling this option will add the ESXi host this VM is running on to the VM details
track_vm_host = True
@bb-Ricardo
Copy link
Owner

Hi,

Just configure both vCenter instances in the same config file and run the sync. Then it should work properly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants