The vmware_nsx.dhcp_meta.lsnmanager Module

class vmware_nsx.dhcp_meta.lsnmanager.LsnManager(plugin)

Bases: object

Manage LSN entities associated with networks.

cluster
lsn_create(context, network_id)

Create a LSN associated to the network.

lsn_delete(context, lsn_id)

Delete a LSN given its id.

lsn_delete_by_network(context, network_id)

Delete a LSN associated to the network.

lsn_exists(context, network_id)

Return True if a Logical Service Node exists for the network.

lsn_get(context, network_id, raise_on_err=True)

Retrieve the LSN id associated to the network.

lsn_metadata_configure(context, subnet_id, is_enabled)

Configure metadata service for the specified subnet.

lsn_port_create(context, lsn_id, subnet_info)

Create and return LSN port for associated subnet.

lsn_port_delete(context, lsn_id, lsn_port_id)

Delete a LSN port from the Logical Service Node.

lsn_port_dhcp_configure(context, lsn_id, lsn_port_id, subnet)

Enable/disable dhcp services with the given config options.

lsn_port_dhcp_host_add(context, network_id, subnet_id, host)

Add dhcp host entry to LSN port configuration.

lsn_port_dhcp_host_remove(context, network_id, subnet_id, host)

Remove dhcp host entry from LSN port configuration.

lsn_port_dhcp_setup(context, network_id, port_id, port_data, subnet_config=None)

Connect network to LSN via specified port and port_data.

lsn_port_dispose(context, network_id, mac_address)

Delete a LSN port given the network and the mac address.

lsn_port_get(context, network_id, subnet_id, raise_on_err=True)

Retrieve LSN and LSN port for the network and the subnet.

lsn_port_get_by_mac(context, network_id, mac, raise_on_err=True)

Retrieve LSN and LSN port given network and mac address.

lsn_port_meta_host_add(context, network_id, subnet_id, host)

Add dhcp host entry to LSN port configuration.

lsn_port_meta_host_remove(context, network_id, subnet_id, host)

Remove dhcp host entry from LSN port configuration.

lsn_port_metadata_setup(context, lsn_id, subnet)

Connect subnet to specified LSN.

lsn_port_update(context, network_id, subnet_id, dhcp=None, meta=None)

Update the specified configuration for the LSN port.

class vmware_nsx.dhcp_meta.lsnmanager.PersistentLsnManager(plugin)

Bases: vmware_nsx.dhcp_meta.lsnmanager.LsnManager

Add local persistent state to LSN Manager.

lsn_create(context, network_id)
lsn_delete(context, lsn_id)
lsn_get(context, network_id, raise_on_err=True)
lsn_port_create(context, lsn_id, subnet_info)
lsn_port_delete(context, lsn_id, lsn_port_id)
lsn_port_get(context, network_id, subnet_id, raise_on_err=True)
lsn_port_get_by_mac(context, network_id, mac, raise_on_err=True)
lsn_port_save(context, lsn_port_id, subnet_id, mac_addr, lsn_id)

Save LSN Port information to the DB.

lsn_save(context, network_id, lsn_id)

Save LSN-Network mapping to the DB.

vmware_nsx.dhcp_meta.lsnmanager.register_lsn_opts(config)