快速入門:建立 Azure SQL Database 受控執行個體Quickstart: Create an Azure SQL Database managed instance

本快速入門逐步解說如何在 Azure 入口網站中建立 Azure SQL Database 受控執行個體This quickstart walks you through how to create an Azure SQL Database managed instance in the Azure portal.


如需了解限制,請參閱支援的區域支援的訂用帳戶類型For limitations, see Supported regions and Supported subscription types.

登入 Azure 入口網站Sign in to the Azure portal

如果您沒有 Azure 訂用帳戶,請建立免費帳戶If you don't have an Azure subscription, create a free account.

登入 Azure 入口網站Sign in to the Azure portal.

建立受控執行個體Create a managed instance

下列步驟說明如何建立受控執行個體。The following steps show you how to create a managed instance.

  1. 選取 Azure 入口網站中左上角的 [建立資源] 。Select Create a resource in the upper-left corner of the Azure portal.

  2. 找出 [受控執行個體] ,然後選取 [Azure SQL 受控執行個體] 。Locate managed instance, and then select Azure SQL Managed Instance.

  3. 選取 [建立] 。Select Create.


  4. 使用下表中的資訊,填妥 SQL 受控執行個體表單中所要求的資訊。Fill out the SQL managed instance form with the requested information by using the information in the following table.

    設定Setting 建議的值Suggested value 說明Description
    訂用帳戶Subscription 您的訂用帳戶。Your subscription. 讓您有權建立新資源的訂用帳戶。A subscription that gives you permission to create new resources.
    受控執行個體名稱Managed instance name 任何有效名稱。Any valid name. 如需有效的名稱,請參閱命名規則和限制For valid names, see Naming rules and restrictions.
    受控執行個體系統管理員登入Managed instance admin login 任何有效的使用者名稱。Any valid username. 如需有效的名稱,請參閱命名規則和限制For valid names, see Naming rules and restrictions. 請勿使用 "serveradmin",因為這是保留的伺服器層級角色。Don't use "serveradmin" because that's a reserved server-level role.
    密碼Password 任何有效密碼。Any valid password. 密碼長度至少必須有 16 個字元,而且符合定義的複雜度需求The password must be at least 16 characters long and meet the defined complexity requirements.
    時區Time zone 您的受控執行個體所要觀察的時區。The time zone to be observed by your managed instance. 如需詳細資訊,請參閱時區For more information, see Time zones.
    定序Collation 您要用於受控執行個體的定序。The collation that you want to use for your managed instance. 如果您從 SQL Server 遷移資料庫,請使用 SELECT SERVERPROPERTY(N'Collation') 來檢查來源定序並使用該值。If you migrate databases from SQL Server, check the source collation by using SELECT SERVERPROPERTY(N'Collation') and use that value. 如需定序的相關資訊,請參閱設定或變更伺服器定序For information about collations, see Set or change the server collation.
    位置Location 要在其中建立受控執行個體的位置。The location in which you want to create the managed instance. 如需有關區域的資訊,請參閱 Azure 區域For information about regions, see Azure regions.
    虛擬網路Virtual network 選取 [建立新的虛擬網路] 或有效的虛擬網路與子網路。Select either Create new virtual network or a valid virtual network and subnet. 如果網路或子網路無法使用,您必須先修改成符合網路需求後,才能選取它作為新的受控執行個體目標。If a network or subnet is unavailable, it must be modified to satisfy the network requirements before you select it as a target for the new managed instance. 如需關於設定受控執行個體網路環境的需求資訊,請參閱設定受控執行個體的虛擬網路For information about the requirements for configuring the network environment for a managed instance, see Configure a virtual network for a managed instance.
    啟用公用端點Enable public endpoint 核取此選項以啟用公用端點Check this option to enable public endpoint 若要讓受控執行個體可透過公用資料端點來存取,您必須核取 [啟用公用端點] 。For managed instance to be accessible through the public data endpoint, Enable public endpoint needs to be checked.
    允許從此存取Allow access from 選取其中一個選項:Select one of the options:
    • Azure 服務Azure services
    • InternetInternet
    • 無存取權No access
    入口網站體驗可讓您對公用端點設定安全性群組。Portal experience enables configuring security group with public endpoint.

    根據您的案例,選取下列其中一個選項:Based on your scenario, select one of the following options:
    • Azure 服務 - 從 Power BI 或其他多租用戶服務連線時,建議使用此選項。Azure services - recommended when connecting from Power BI or other multi-tenant service.
    • 網際網路 - 可在您想要快速啟動受控執行個體時用於測試目的。Internet - use for test purposes when you want to quickly spin up a managed instance. 不建議用於生產環境。It’s not recommended for use in production environments.
    • 無存取權 - 此選項會建立拒絕安全性規則。No access - this option creates a deny security rule. 您必須修改這項規則,以便讓受控執行個體可透過公用端點來存取。You’ll need to modify this rule in order to make managed instance accessible through public endpoint.

    如需公用端點安全性的詳細資訊,請參閱搭配公用端點來安全地使用 Azure SQL Database 受控執行個體For more information on public endpoint security, see using Azure SQL Database managed instance securely with public endpoint.
    連線類型Connection type 在 Proxy 和重新導向連線類型之間做選擇。Choose between a Proxy and a Redirect connection type. 如需有關連線類型的詳細資訊,請參閱 Azure SQL Database 連線原則For more information about connection types, see Azure SQL Database connection policy.
    資源群組Resource group 新的或現有的資源群組。A new or existing resource group. 如需有效的資源群組名稱,請參閱命名規則和限制For valid resource group names, see Naming rules and restrictions.


  5. 若要以受控執行個體作為次要執行個體容錯移轉群組,請選取 [簽出],然後指定 DnsAzurePartner 受控執行個體。To use the managed instance as an instance failover group secondary, select the checkout and specify the DnsAzurePartner managed instance. 這是預覽版功能,不會顯示在下列螢幕擷取畫面中。This feature is in preview and isn't shown in the following screenshot.

  6. 選取 [定價層] 來調整計算和儲存體資源的大小,以及檢閱定價層選項。Select Pricing tier to size compute and storage resources and to review the pricing tier options. 預設值為一般用途定價層,其具也 32 GB 記憶體和 16 個虛擬核心。The General Purpose pricing tier with 32 GB of memory and 16 vCores is the default value.

  7. 使用滑桿或文字方塊來指定儲存體數量和虛擬核心數目。Use the sliders or text boxes to specify the amount of storage and the number of virtual cores.

  8. 當您完成時,選取 [套用] 來儲存您的選擇。When you're finished, select Apply to save your selection.

  9. 選取 [建立] 以部署受控執行個體。Select Create to deploy the managed instance.

  10. 選取 [通知] 圖示以檢視部署的狀態。Select the Notifications icon to view the status of the deployment.


  11. 選取 [部署正在進行中] 來開啟受控執行個體視窗,以進一步監視部署進度。Select Deployment in progress to open the managed instance window to further monitor the deployment progress.


如果是子網路中的第一個執行個體,部署時間通常遠超過後續執行個體的部署時間。For the first instance in a subnet, deployment time is typically much longer than in subsequent instances. 請勿取消部署作業,因為它持續的時間超過您的預期。Don't cancel the deployment operation because it lasts longer than you expected.

檢閱資源並擷取完整伺服器名稱Review resources and retrieve your fully qualified server name

部署成功後,請檢閱所建立的資源,並擷取完整伺服器名稱以供稍後的快速入門使用。After the deployment is successful, review the resources that were created and retrieve the fully qualified server name for use in later quickstarts.

  1. 開啟受控執行個體的資源群組。Open the resource group for your managed instance. 檢視其在建立受控執行個體快速入門中為您所建立的資源。View its resources that were created for you in the create a managed instance quickstart.


  2. 選取路由表以檢閱為您建立的使用者定義路由 (UDR) 表。Select the route table to review the user-defined route (UDR) table that was created for you.


  3. 在路由表中,檢閱要從受控執行個體虛擬網路路由傳送流量的項目。In the route table, review the entries to route traffic from and within the managed instance virtual network. 如果您要手動建立或設定路由表,您必須在路由表中建立這些項目。If you create or configure your route table manually, you must be sure to create these entries in the route table.


  4. 回到資源群組,然後選取網路安全性群組以檢閱安全性規則。Return to the resource group, and select the network security group to review the security rules.


  5. 檢閱輸入和輸出安全性規則。Review the inbound and outbound security rules. 如果您已為受控執行個體設定公用端點,請參閱設定公用端點一文以取得詳細資訊。If you have configured public endpoints for your managed instance, see the article Configure public endpoint for more information.


  6. 回到資源群組,然後選取您的受控執行個體。Return to the resource group, and select your managed instance.


  7. 在 [概觀] 索引標籤上,找出 [主機] 屬性。On the Overview tab, locate the Host property. 複製受控執行個體的完整主機位址,以便在下一個快速入門中使用。Copy the fully qualified host address for the managed instance for use in the next quickstart.


    此名稱類似於 your_machine_name.a1b2c3d4e5f6.database.windows.netThe name is similar to your_machine_name.a1b2c3d4e5f6.database.windows.net.

後續步驟Next steps