Document navigation

Gateways and Segments

Configure workload gateways and segments and establish their routing relationships. Connect to external networks, connect workload subnets, or deploy segments across sites as needed.

After configuring sites and Fabric, you can use the prepared transport zones, host networks, and edge clusters in ZNS to configure workload networks. Segments define Layer 2 workload networks. Gateways and routes establish Layer 3 connections between segments and between workload and external networks.

Segments are created and maintained according to resource ownership. Segment creation and cross-site deployment in this chapter apply to native segments managed by ZNS. Networks for ZSphere workload VMs have corresponding segments created through port groups; a native segment does not need to be created first. Port group, address range, and DHCP configuration is covered in VM Network Connection and Use. If a Geneve port group requires Layer 3 connectivity, first prepare the required gateway as described in this chapter, then select it when creating the port group.

Workload Network Configuration Process

Determine the combination of gateways and segments according to the required Layer 2 communication, cross-subnet access, and external access, then configure the connections and routes. If gateways are required, prepare Tier-0 and Tier-1 gateways before establishing gateway connections for segments. Segments that require only Layer 2 communication can be configured directly in their transport zones.

Configuration ActivityPurpose and Dependencies
Prepare GatewaysCreate a Tier-0 gateway on an edge cluster to provide workload network egress. Then create a Tier-1 gateway linked to that Tier-0 to provide Layer 3 routing for workload segments. Gateway sites and hosting resources must match the workload network plan.
Configure Native SegmentsSelect a VLAN or Overlay transport zone and define the Layer 2 workload network and addressing plan. Attach Overlay segments that require Layer 3 connectivity to a Tier-1 gateway in the same site. Connect VLAN segments through gateway router interfaces.
Configure Connections and RoutesConfigure router interfaces according to the VLAN connectivity and external network plans. Add static routes when a destination network must be reached through a specified next hop. Gateways, segments, and routes together form the required workload access paths.

When adding segments to an existing workload network, first check whether its transport zones and gateways are suitable, then add the required segments and connections.

Gateway Connectivity and Cross-Site Deployment

To connect workload subnets under different Tier-1 gateways, follow Create a Tier-1 Peering Connection to select both gateways and the connectivity scope. For same-site connections, configure the peering relationship directly. For cross-site connections, first prepare local Fabric at both ends and a site interconnect, then configure the peering relationship between the workload gateways.

To extend a segment across two sites, build on these inter-site connections and follow Deploy a Segment Across Sites to configure the peer transport zone, gateway, and member segment. The site interconnect provides inter-site transport, Tier-1 peering provides gateway connectivity, and cross-site segment deployment organizes workload network members at both ends.

Create a Tier-0 Gateway

Select an edge cluster and create a Tier-0 gateway to provide upstream connectivity for workload networks.

Before you begin

You have prepared an edge cluster in the target site by following Create an Edge Cluster and checked its members and configuration state.

Procedure

  1. In ZNS, choose Network > Connectivity > Tier-0 Gateway and click Create Tier-0 Gateway.
  2. Configure the gateway parameters.
    OptionDescription
    NameRequired. Enter 1–64 characters without spaces.
    DescriptionOptional. Enter no more than 256 characters.
    Edge ClusterSelect the edge cluster that will host the gateway, and check its site and members.
    HA ModeCurrently, only Active-Standby is supported.
    Router Link CIDROptional. Enter a valid CIDR according to the addressing plan for routing links between gateways, for example, 100.64.0.0/16.
  3. Check the edge cluster and addressing plan, and click OK.
  4. Return to the list and click the gateway name. In Overview, check the edge cluster, HA mode, and router link CIDR, and confirm that Configuration State is Deployed.

Results

The Tier-0 gateway is created and can be selected as the linked gateway when you follow Create a Tier-1 Gateway. To connect to VLAN networks, also follow Configure Gateway Router Interfaces.

Create a Tier-1 Gateway

Select a linked Tier-0 gateway and create a Tier-1 gateway for workload segments.

Before you begin

You have completed Create a Tier-0 Gateway, or a Tier-0 gateway that meets the workload network plan already exists.

Procedure

  1. In ZNS, choose Network > Connectivity > Tier-1 Gateway and click Create Tier-1 Gateway.
  2. Enter the basic information and select the upstream gateway.
    OptionDescription
    NameRequired. Enter 1–64 characters without spaces.
    DescriptionOptional. Enter no more than 256 characters.
    Linked Tier-0 GatewayRequired. The Tier-1 gateway uses the edge cluster of the selected Tier-0. Check that the gateway's site matches the workload segment plan.
    HA ModeCurrently, only Active-Standby is supported.
  3. Configure Route Advertisement as needed.

    All NAT IPs and All LB VIP Routes are disabled by default. Enable the corresponding option to advertise the workload addresses to the upstream network. Enabling advertisement does not create NAT rules or load balancing services. Configure those services and upstream network routes separately.

  4. To limit traffic rates, select router QoS profiles for the corresponding directions under Ingress QoS Profile and Egress QoS Profile.

    To prepare a profile, see Create a Router QoS Profile.

  5. Check the configuration and click OK.
  6. Return to the list and open the gateway. In Overview, check the site, edge cluster, linked Tier-0, and route advertisement rules, and confirm that Configuration State is Deployed.

Results

The Tier-1 gateway is created. Overlay segments in the same site can be attached to it. VLAN segments connect to the gateway through router interfaces.

Create a Segment

Select a transport zone in ZNS and create a VLAN or Overlay workload segment.

Before you begin

  • You have configured transport zones for the target clusters by following Configure Transport Zones for Clusters, and the relevant hosts are connected to Fabric.
  • You have planned the VLAN ID or Overlay network and the required gateway addresses and prefix lengths.
  • If an Overlay segment requires Layer 3 routing, a Tier-1 gateway exists in the same site. To create one, see Create a Tier-1 Gateway.

About this task

This procedure creates a native segment managed by ZNS. Segments corresponding to ZSphere port groups are created and maintained in ZSphere. Those procedures are described in VM Network Connection and Use.

Procedure

  1. In ZNS, choose Network > Connectivity > Segments and click Create Segment.
  2. Enter the segment's basic network settings.
    OptionDescription
    Name, DescriptionThe name is required and must contain 1–64 characters without spaces. The description is optional and must not exceed 256 characters.
    Transport ZoneSelect a non-DCI transport zone assigned to the target site. Its type determines whether VLAN or Overlay parameters are displayed.
    VLAN IDRequired when a VLAN transport zone is selected. The range is 0–4094. A value of 0 means no VLAN tag.
    VNIOptional when an Overlay transport zone is selected. The range is 1–16777215. Leave blank for automatic allocation.
    Attached GatewayFor an Overlay segment, select a Tier-1 gateway in the same site as the transport zone if needed. VLAN segments do not attach to Tier-1 through this field. Configure a router interface if Layer 3 connectivity is required.
    IPv4 GatewayOptional. If configured, specify both Gateway Address and Prefix Length. The prefix length is 0–32, for example, 192.168.10.1 and 24.
    IPv6 GatewayOptional. If configured, specify both Gateway Address and Prefix Length. The prefix length is 0–128, for example, 2001:db8:10::1 and 64.
  3. For a single-site segment, leave Deploy Segment Across Sites disabled.

    To deploy across sites during creation, follow Deploy a Segment Across Sites to configure both gateways and the peer transport zone before submitting.

  4. Check the transport zone, VLAN ID or VNI, and gateway settings, and click OK.
  5. Return to the segment list and open the new segment. In Overview, check the transport zone, traffic type, attached gateway, and IPAM configuration, and confirm that Configuration State is Deployed.

Results

The segment is created. To configure MTU, QoS, or SpoofGuard profiles, follow Adjust Segment Configuration.

To provide automatic address configuration for this segment, prepare the service by following Configure a Segment DHCP Service.

Configure Gateway Router Interfaces

Create router interfaces on a Tier-0 or Tier-1 gateway to connect it to VLAN segments.

Before you begin

  • The target gateway and the VLAN segment for the interface are prepared. To create a segment, see Create a Segment.
  • You have planned the interface IPv4 address, prefix length, and link MTU. For an external interface, also prepare the edge cluster that will host it.

Procedure

  1. In ZNS, under Network > Connectivity, choose Tier-0 Gateway or Tier-1 Gateway and click the target gateway name.
  2. Open Router Interfaces for Tier-0 or Interfaces for Tier-1, and click Create Router Interface.
  3. Configure the interface parameters.
    OptionDescription
    Name, DescriptionThe name is required and must contain 1–64 characters without spaces. The description is optional and must not exceed 255 characters.
    Interface TypeTier-0 supports Service and External. Tier-1 supports only Service. Service interfaces inherit the gateway's edge cluster. External interfaces require a separate edge cluster selection.
    IP Address/CIDRRequired. Currently supports an IPv4 address and prefix length, for example, 192.168.1.3/24.
    SegmentRequired. Only VLAN segments are supported. Check that the VLAN ID matches the physical network connected to the interface.
    Edge ClusterRequired for the External type. Select the resources that will host the interface.
    MTUOptional. The range is 576–9000. Match the MTU plan for the connected network.
  4. Check the interface address, VLAN segment, and edge cluster, and click OK.
  5. Return to Router Interfaces for Tier-0 or Interfaces for Tier-1, and check the interface type, IP address, netmask, segment, edge cluster, and MTU.

Results

A router interface is added to the target gateway. To reach other networks through a specified next hop, follow Configure Gateway Static Routes and verify the relevant network connectivity.

Configure Gateway Static Routes

Specify destination networks and next hops on a Tier-0 or Tier-1 gateway to configure static routes to the target networks.

Before you begin

The target gateway and relevant connections are prepared, and you have planned the destination network and next hop. If the next hop is reached through a VLAN network, first complete Configure Gateway Router Interfaces.

Procedure

  1. In ZNS, under Network > Connectivity, choose Tier-0 Gateway or Tier-1 Gateway and open the target gateway.
  2. Open Static Routes and click Create Static Route.
  3. Configure the route parameters.
    OptionDescription
    NameRequired. Enter 1–64 characters without spaces.
    IP VersionSelect IPv4 or IPv6. The default is IPv4.
    Destination CIDREnter a CIDR matching the selected IP version, for example, 10.0.0.0/8 or 2001:db8::/64.
    Next HopEnter a next-hop address with the same IP version as the destination network, for example, 192.168.1.1. The next hop must be reachable through the prepared gateway connections.
  4. Check the destination network and next hop, and click OK.
  5. Return to Static Routes and check the destination network, next hop, IP version, and configuration state. Verify that the destination network is reachable from the relevant workload network.

Results

The static route is configured on the target gateway. Return routes from the destination network must also match the actual access path.

View Segments and Ports

Check segment network settings, address usage, and associated ports, and identify resource ownership and management interfaces.

Procedure

  1. In ZNS, choose Network > Connectivity > Segments and find the target segment by name.
  2. Check Owning Compute Manager and Configuration State.

    If Owning Compute Manager shows ZNS, the segment is a native segment managed in this interface. If it shows a compute platform name, click the name to view the compute manager. Segments managed by their owning platforms cannot be edited, deleted, or expanded to other sites in ZNS. Manage them in the owning platform.

  3. Click the segment name and check its network settings in Overview.
    InformationWhat to Check
    Basic InformationCheck the UUID, segment type, traffic type, VNI/VLAN ID, MTU, and configuration state.
    IPAM ConfigurationCheck the IPv4 and IPv6 gateway addresses, CIDRs, and IP ranges against the addressing plan actually used by the VMs.
    Associated ResourcesCheck the transport zone, attached gateway, QoS profile, and SpoofGuard profile. For cross-site segments, also check the peer segment.
  4. To check address usage, open IP Address Statistics and view the segment's address usage records.
  5. Open Ports and check port names, owning compute managers, types, configuration states, and associated profiles.

    The VIF type identifies a VM NIC port. This type cannot be edited or deleted here. Manage the VM NIC in the platform associated with its owning compute manager.

  6. For a cross-site segment, open Cross-Site Deployment and check sites, member segments, transport zones, Tier-1 gateways, and member runtime states.

    Check member segment states, gateway creation states, gateway service states, takeover states, and DCI Gateway states. If member runtime states are not yet available, refresh later. For abnormal states, check host connections, transport zones, gateways, and the site interconnect at the relevant site.

Results

You have identified segment and port ownership and checked network settings and association states. Configuration states indicate resource configuration progress. Workload reachability must also be verified against actual addressing and routing.

Create a Tier-1 Peering Connection

Connect two Tier-1 gateways and enable communication between all local subnets or specified CIDRs.

Before you begin

  • Both Tier-1 gateways are created, and you have identified the local subnets that need to communicate.
  • For a cross-site connection, you have established an available interconnect between the two sites by following Create and Manage Site Interconnects. This is not required for a same-site connection.

Procedure

  1. In ZNS, choose Network > Connectivity > Peering Connections and click Create Peering Connection.
  2. Enter a Name of 1–64 characters without spaces.
  3. Select Tier-1 Gateway A and Tier-1 Gateway B, and check their sites.

    The endpoints must use different gateways. A same-site connection does not require a site interconnect. For a cross-site connection, the system automatically queries and uses the interconnect between the gateways' sites. If none is found, prepare an interconnect first. Retry a failed query. If site information is missing or the interconnect relationship is inconsistent, check gateway site membership and the interconnect configuration first.

  4. Choose whether to enable Connect All Local Subnets.
    SelectionConnectivity Scope
    Enabled, the defaultAll local subnets on both Tier-1 gateways can communicate.
    DisabledSpecify local subnets connected to the two gateways in Advertised CIDRs. IPv4 and IPv6 CIDRs are supported, one per line or separated by commas. Duplicate CIDRs are not allowed.
    Important:
    The connectivity mode cannot be changed after creation. In specified-CIDR mode, you can change the CIDRs after creation. To change the connectivity mode, handle related dependencies and recreate the connection.
  5. Check both gateways, the site interconnect, and the connectivity scope, and click OK.
  6. Return to the list and open the peering connection. Check both gateways, sites, connectivity mode, advertised CIDRs, and configuration state, and verify connectivity between the target workload subnets.

Results

A peering connection is established between the Tier-1 gateways. To deploy a cross-site segment at both ends, continue with Deploy a Segment Across Sites.

Deploy a Segment Across Sites

Configure a peer transport zone and Tier-1 gateway to deploy a segment across sites during creation or expand an existing segment to another site.

Before you begin

  • Site Fabric, host connections, and non-DCI Overlay transport zones within each site are prepared at both ends.
  • An available site interconnect exists between the two sites. For configuration details, see Site Interconnect.
  • The source and peer Tier-1 gateways are prepared, and you have completed Create a Tier-1 Peering Connection.
  • To expand an existing segment, use an Overlay segment managed by ZNS and attached to the source Tier-1 gateway. This procedure does not apply to system segments, compute-platform-managed segments, or segments already deployed across sites.

About this task

Important:
After a segment is expanded to another site, it cannot be changed directly back to a single-site deployment. Deleting either member segment affects the entire cross-site network. For the deletion scope, see Delete a Segment.

Procedure

  1. In ZNS, choose Network > Connectivity > Segments and select an entry according to whether the segment already exists.
    ScenarioAction
    Deploy Across Sites During CreationClick Create Segment and follow Basic Segment Network Settings to enter the name, source Overlay transport zone, gateway addresses, and other parameters. Select the source Tier-1 under Attached Gateway and enable Deploy Segment Across Sites.
    Expand an Existing SegmentChoose Expand to Other Sites from the segment's Actions, or open its details and select this option from More actions.
  2. Select a Peer Transport Zone.

    The peer zone must belong to a different site from the source and must be a non-DCI Overlay transport zone within that site. Check the zone and its associated clusters to ensure that they can host the peer workloads.

  3. Select a Peer Tier-1 Gateway.

    Select a gateway in the peer transport zone's site that is already peered with the source Tier-1. The segment creation form filters candidates by these conditions. Select the source gateway and peer transport zone before selecting the peer gateway.

  4. Optionally enter a Peer VNI from 1 to 16777215. Leave blank for automatic allocation in the peer transport zone.
  5. Check the source segment, both gateways, and the peer zone. Confirm that you accept that the segment cannot be changed directly back to a single-site deployment, and click OK.
  6. Open the cross-site segment's details and check the results under Cross-Site Deployment.
    • Check the effective site count, site interconnect, and both sites. Confirm that member segments, transport zones, and Tier-1 gateways match the plan.
    • Check member segment states, gateway creation states, gateway service states, takeover states, and DCI Gateway states. If member runtime states are not yet available, refresh later. Missing states do not indicate that deployment is complete.
    • If a member or DCI state is abnormal, check host connections, transport zones, gateways, and the interconnect at the relevant site. Verify cross-site workload connectivity after resource configuration is complete.

Results

The segment's cross-site deployment relationship is established. You can view members at both ends and their runtime states in its details.

Adjust Gateway and Segment Configurations

Modify existing gateway, segment, and peering configurations to adjust upstream connections, route advertisement, and associated profiles for workload requirements.

In ZNS, open the relevant object list under Network > Connectivity. Maintenance options are available in each row's Actions and under More actions in the details. Before making changes, check the object, references, and workload usage.

Modify a Tier-0 Gateway

Changing the edge cluster changes the resources hosting the gateway. First check the target cluster and related workload networks.

  1. Open Tier-0 Gateway and choose Edit for the target gateway.
  2. Modify Name, Description, or Edge Cluster. The name must contain 1–64 characters without spaces. The description must not exceed 256 characters. HA mode and router link CIDR are not modified in this window.
  3. Check the target edge cluster and click OK. Check the configuration state and associated resources in Overview, and verify the affected workloads.

Modify Tier-1 Upstream Connections and QoS Profiles

Changing the linked Tier-0 or QoS profiles changes workload traffic paths or rate limits and may interrupt connections or change throughput. Check associated segments, gateways, and services before making changes.

  1. Open Tier-1 Gateway and choose Edit for the target gateway.
  2. Modify Name, Description, Linked Tier-0 Gateway, Ingress QoS Profile, or Egress QoS Profile as needed. The name must contain 1–64 characters without spaces. The description must not exceed 256 characters. The selected Tier-0 determines the Tier-1 gateway's edge cluster. Select QoS profiles by direction. Clearing a profile stops using it to limit traffic in that direction. To prepare a profile, see Create a Router QoS Profile.
  3. Check the upstream connection and profiles, and click OK.
  4. In Overview, check the linked gateway, edge cluster, QoS profiles, and configuration state. Check workload connectivity and rate-limiting results.

Set Tier-1 Route Advertisement Rules

Route advertisement determines which NAT IPs and load balancing VIPs are advertised to the upstream network. Disabling the relevant advertisement may make workload addresses unreachable from upstream networks. Enabling advertisement also requires the actual services and upstream network routes.

  1. Open Tier-1 Gateway and choose Set Route Advertisement Rules for the target gateway.
  2. Enable or disable All NAT IPs and All LB VIP Routes as needed.
  3. Confirm the impact on access to the affected workload addresses, and click OK.
  4. Return to Overview and check the route advertisement rules. Verify access to the relevant workload addresses from the upstream network.

Adjust Segment Configuration

Perform this operation only on non-system segments managed by ZNS. Modify compute-platform-managed segments in the owning platform. To identify ownership, see View Segments and Ports.

  1. Open Segments and choose Edit for the target segment.
  2. Adjust the following parameters as needed.

    OptionDescription
    Name, DescriptionThe name must contain 1–64 characters without spaces. The description must not exceed 256 characters.
    MTUThe range is 64–9000. Required for VLAN segments and optional for Overlay segments. Inconsistency with other nodes on the path may affect packet transmission.
    IPv4 Gateway, IPv6 GatewayChange addresses and prefix lengths as needed. Enter each address and prefix as a pair. The IPv4 prefix length is 0–32, and the IPv6 prefix length is 0–128. The CIDRs and IP ranges in this window are read-only and cannot be edited directly here.
    Attached GatewayFor an Overlay segment, select a Tier-1 in the same site or clear the existing attachment. This option is not available for VLAN segments. Changing or removing the gateway changes the segment's Layer 3 connectivity.
    QoS ProfileSelect or clear the rate-limiting profile associated with the segment. To prepare a profile, see Create a Segment QoS Profile.
    SpoofGuard ProfileSelect or clear the address anti-spoofing profile associated with the segment. To prepare a profile, see Create a SpoofGuard Profile.

    These two associations are used by ports created later. Changing or clearing the segment associations does not automatically replace existing ports' profile references. To modify profile parameters or the protection state, see Manage Network Policies.

  3. Confirm that changes to gateway addresses, routing, and associated profiles match the actual workloads, and click OK.
  4. Return to Overview to check the configuration state, IPAM settings, and associated resources, and check workload connectivity. The editing window does not provide changes to the transport zone, VLAN ID, or VNI.

Adjust a Peering Connection

Open Peering Connections and perform the operation for the required change:

  • Rename: Choose Rename, enter a name of 1–64 characters without spaces, and click OK.
  • Adjust the connectivity scope: Edit Advertised CIDRs is available only in specified-CIDR mode. Enter local subnets connected to the two gateways. IPv4 and IPv6 CIDRs are supported, one per line or separated by commas, without duplicates. Leaving the field blank removes all advertised CIDRs. Reducing the scope affects communication between the corresponding subnets. Confirm the scope and click OK, then check the connection details and verify the relevant subnets.

The connectivity mode cannot be changed. In all-local-subnets mode, CIDRs are not specified here.

Clean Up Unused Gateways and Segments

Check workload usage and associations, then clean up unused segments, Tier-1 peering connections, and gateways.

In ZNS, open the relevant object list under Network > Connectivity. First handle VM connections, related network services, and resource references. Then clean up segments, peering connections, Tier-1 gateways, and Tier-0 gateways according to their actual dependencies. To remove NAT and load balancing services, see Delete a NAT Rule and Clean Up Unused Load Balancing Resources, respectively. Deletion cannot be undone. To restore service, recreate the resources and restore the relevant configurations.

Delete a Segment

Only delete non-system segments managed by ZNS here. For segments managed by ZSphere, return to ZSphere to handle the corresponding port groups and NIC connections.

Deletion is rejected if the segment still has VM NIC ports or its router interfaces are referenced by NAT rules or static routes. Handle these workload dependencies before deletion.

  1. Open Segments, check the target segment and associated workloads, and choose Delete from Actions.
  2. Check the segment name and impact scope in the confirmation window.

    Warning:
    Deleting a segment interrupts workloads that still use its network. When a source or peer segment in a cross-site deployment is deleted, ZNS deletes both member segments and their cross-site deployment relationship. Peering connections, Tier-1 and Tier-0 gateways, site interconnects, and DCI Gateways are retained. Deleting one member cannot be used to withdraw only one site.
  3. Confirm that workloads and associated resources have been handled, enter delete, and click Confirm to Delete.
  4. Return to the segment list and check the result. For cross-site deletion, check that both segments have been deleted and that the retained gateways and connections still match the plan.

Delete a Peering Connection

Deletion interrupts connectivity established through the connection between the Tier-1 gateways. The gateways themselves are retained. A connection with associated resources cannot be deleted. First handle dependencies such as cross-site networks using the connection.

  1. Open Peering Connections, check both gateways and the connectivity scope, and choose Delete from the target connection's Actions.
  2. Check the connection name and workload impact at both ends, enter delete, and click Confirm to Delete.
  3. Return to the list and check the result. Confirm that both gateways are retained and check other network connections that must remain available.

Delete a Tier-1 Gateway

First check the gateway's associated segments, peering connections, router interfaces, static routes, and network services. Handle workloads and references that must be retained.

  1. Open Tier-1 Gateway and choose Delete for the target gateway.
  2. Check the gateway name. Deletion may interrupt routing, NAT, and load balancing workloads through the gateway. Confirm that the relevant workloads and configurations have been handled, enter delete, and click Confirm to Delete.
  3. Return to the list to confirm deletion, and check segments, upstream gateways, and workload networks that must be retained.

Delete a Tier-0 Gateway

First check Tier-1 gateways, router interfaces, static routes, and network services using this egress gateway. To retain a Tier-1 gateway, first change its upstream connection by following Modify Tier-1 Upstream Connections and QoS Profiles.

  1. Open Tier-0 Gateway and choose Delete for the target gateway.
  2. Check the gateway name. Deletion may interrupt north-south traffic through the gateway. Confirm that egress workloads and dependencies have been handled, enter delete, and click Confirm to Delete.
  3. Return to the list and check the result. Verify egress connections and workload access that must be retained.