All Products
Search
Document Center

Microservices Engine:Configure a DNS server

Last Updated:Mar 11, 2026

You can configure a Domain Name System (DNS) server for your services to resolve internal domain names efficiently and securely. Adding custom DNS servers to the gateway's service configuration centralizes internal name resolution and eliminates dependency on external DNS, preventing service unavailability caused by external DNS failures or network performance fluctuation.

Use cases

ScenarioDescription
Custom internal DNSRoute queries for domain names that the default VPC DNS cannot resolve to your own DNS servers, such as private service registries or on-premises endpoints.
VPC-internal service routingResolve internal domain names to backend addresses so the cloud-native gateway routes requests accurately within the VPC.
Hybrid cloud environmentsManage DNS resolution for both cloud-hosted and on-premises services in a single configuration, keeping routing consistent across environments.

Configure DNS servers for a service

DNS server settings are part of each service's configuration. You configure them when adding a new service or editing an existing one.

Note

Currently, only DNS domain names are supported as service sources.

Before you begin

Make sure you have:

  • An MSE cloud-native gateway

  • (Optional) Alibaba Cloud DNS activated, if you want automatic internal DNS server assignment in your VPC

Open the service configuration

  1. Log on to the MSE console and select a region in the top navigation bar.

  2. In the left-side navigation pane, choose Cloud-native Gateway > Gateways.

  3. On the Gateways page, click the gateway ID.

  4. In the left-side navigation pane, click Routes, then click the Services tab.

  5. Open the service configuration:

    • To add a new service, click Add Service.

    • To update an existing service, click Edit in the Actions column of the target service.

Add DNS servers

  1. Click More Settings to expand the advanced configuration options.

  2. Add DNS server addresses using one of the following methods: Automatic assignment When you activate Alibaba Cloud DNS, Alibaba Cloud assigns internal DNS server addresses to your VPC. Clicking the auto-assign button retrieves these addresses and populates the DNS server list. Manual entry Click Add and enter a DNS server address. Repeat this step to add more servers.

    MethodStepsWhen to use
    Automatic assignmentClick Click to automatically specify DNS server IP addresses. The system populates the DNS server list with the internal DNS addresses that Alibaba Cloud DNS assigned to your VPC.You have activated Alibaba Cloud DNS and want to use VPC-assigned DNS addresses.
    Manual entryClick Add and enter a DNS server address. Repeat to add more servers (up to five).You manage your own DNS servers or need to specify addresses that differ from the VPC defaults.

    Automatic DNS server IP address assignment

    Manually add a DNS server address

  3. Save the service configuration.

Limits

ItemLimit
Maximum DNS servers5
Supported service source typesDNS domain names only