為專屬互連網路建立 99.9% 的可用性

注意:如為正式版等級應用程式,請參閱「為專屬互連網路建立 99.99% 的可用性」。Google 建議您設定高可用性。

99.9% 可用性的拓撲適用於可以容忍一些停機時間的一般應用程式。例如,貴機構可能會進行批次上傳,而其作業的時間點並不重要。如果連線無法使用,則系統會在連線復原時繼續執行作業。

如要瞭解本頁面使用的 Cloud Interconnect 術語,請參閱「重要術語」。

如要瞭解如何建立備援 Cloud Interconnect 連線,以便在備援情況下提供足夠的容量,請參閱最佳做法

需求條件

需要下列資源和設定才能達到 99.9% 的可用性:

  • 至少有兩個 Cloud Interconnect 連線。連線必須位於同一個都會區 (都會),但位於不同的邊緣可用性網域 (都會供應區域)。無論連線位於同一個設施或不同設施,只要位於兩個不同的邊緣可用性網域即可。

  • 至少一個 Cloud Router。每個 Cloud Interconnect 連線都必須連結至 Cloud Router。

拓撲範例

以下拓撲範例顯示位於同一個都會區但不同主機代管服務供應商機房的兩個 Cloud Interconnect 連線:lga-zone1-16lga-zone2-1422。Cloud Router 位於 us-central1 Google Cloud 地區vpc1 網路中。

具備 99.9% 可用性的備援連線 (按一下可放大)。
達到 99.9% 可用性的備援連線 (按一下可放大)

建立 99.9% 拓撲

以下各節將逐一介紹建立此拓撲的步驟。如要建立個人化的拓撲,請使用您自己的值取代範例輸入值。例如,使用您的虛擬私人雲端網路名稱取代 vpc1 網路名稱。

訂購 Cloud Interconnect 連線

您可以使用 Google Cloud 控制台或 Google Cloud CLI 訂購備援連線。

主控台

  1. 在 Google Cloud 控制台中,前往「Interconnect Hybrid Connectivity」頁面。

    前往互連網路混合式連線

  2. 按一下「開始使用」

  3. 選取「專屬互連網路」,然後按一下「繼續」

  4. 選取「訂購新的專屬互連網路」,然後按一下「繼續」

  5. 指定 Cloud Interconnect 連線的詳細資料:

    • 「Name」:輸入 int-lga1
    • 說明:輸入 Example Cloud Interconnect connection in LGA ZONE1
    • 「Location」:選擇 Digital Realty | Telx New York (111 8th Ave),這是 lga-zone1-16 位置的 PeeringDB 名稱。
    • 容量:使用預設容量 (10 Gb/s)。
  6. 點按「Next」

  7. 指定備援 Cloud Interconnect 連線的詳細資料:

    • 「Name」:輸入 int-lga2
    • 說明:輸入 Example Cloud Interconnect connection in LGA ZONE2
    • 位置:選擇 zColo New York - 60 Hudson St,這是 lga-zone2-1422 位置的 PeeringDB 名稱。
    • 容量:使用預設容量 (10 Gb/s)。
  8. 點按「Next」

  9. 指定聯絡資訊:

    • 公司名稱:輸入 The Customer。這個名稱會用於 LOA-CFA,做為獲授權要求 Cloud Interconnect 連線的一方。
    • 技術聯絡人:輸入 customer@customer.com。您不需要輸入自己的地址,系統會將您列入所有通知的聯絡人名單。
  10. 點按「Next」

  11. 檢查您的訂單內容。請檢查 Cloud Interconnect 連線詳細資料和聯絡資訊是否正確。如果一切都正確無誤,請按一下「下單」。如果沒有,請返回並編輯連結詳細資料。

  12. 在訂單確認頁面上查看後續步驟,然後按一下「完成」

gcloud

  • 訂購兩個 Cloud Interconnect 連線,名稱分別為 int-lga1int-lga2

    gcloud compute interconnects create int-lga1 \
      --customer-name "The Customer" \
      --description "Example Cloud Interconnect connection in LGA ZONE1" \
      --interconnect-type DEDICATED \
      --link-type ETHERNET_10G_LR \
      --location lga-zone1-16 \
      --requested-link-count 1 \
      --noc-contact-email customer@customer.com
    gcloud compute interconnects create int-lga2 \
      --customer-name "The Customer" \
      --description "Example Cloud Interconnect connection in LGA ZONE2" \
      --interconnect-type DEDICATED \
      --link-type ETHERNET_10G_LR \
      --location lga-zone2-1422 \
      --requested-link-count 1 \
      --noc-contact-email customer@customer.com

訂購 Cloud Interconnect 連線後,Google 會傳送確認電子郵件給您,並分配通訊埠給您。分配完成之後,Google 會為您的連線產生 LOA-CFA,並用電子郵件傳送給您。系統也會將所有自動化電子郵件傳送給 NOC 聯絡人和訂購連線的使用者。

只有在佈建並測試連線後,您才能使用 Cloud Interconnect 連線。如要進一步瞭解佈建程序,請參閱佈建總覽

建立雲端路由器

如要建立 Cloud Router,請按照本節的說明操作。

主控台

  1. 前往 Google Cloud 控制台的「Create a Cloud Router」頁面。

    前往建立 Cloud Router

  2. 指定 Cloud Router 詳細資料:

    • 名稱:輸入 router1 做為 Cloud Router 的名稱。
    • 「Network」:選取 vpc1,這是內部部署網路延伸目的地的網路名稱。
    • 「Region」:選取 us-central1,這是 Cloud Router 通告所有子網路的地區,如範例拓撲中所示。
    • 「Google ASN」:輸入 64513,這是範例 Cloud Router 的 ASN。
  3. 在「路徑」下方,選取「公告 Cloud Router 可使用的所有子網路 (預設)」,然後按一下「建立」

gcloud

  • us-central1 地區的 vpc1 網路中建立 Cloud Router,並使用 ASN 64513

    gcloud compute routers create router1 \
      --asn 64513 \
      --network vpc1 \
      --region us-central1

建立 VLAN 連結

可以開始使用 Cloud Interconnect 連線 (處於 ACTIVE 狀態) 後,請建立 VLAN 連結,以將連線與 Cloud Router 連接在一起。建立備援連結,每個連結一個。在本範例中,int-lga1int-lga2 都會連線至 router1

主控台

  1. 在 Google Cloud 控制台中,前往「VLAN attachments」(VLAN 連結) 分頁。

    前往 VLAN 連結

  2. 按一下 [Add VLAN attachment] (新增 VLAN 連結)

  3. 選取「專屬互連網路」,然後按一下「繼續」

  4. 選取「In this project」

  5. 選取 int-lga1 Cloud Interconnect 連線,然後按一下「繼續」

  6. 選取「Add VLAN attachment」

    • 「Name」:輸入 attachment-lga1-central1
    • Router:選取 router1 Cloud Router。
  7. 按一下「建立」,連結的建立作業需要一些時間才能完成。

  8. 針對該連結,如要將 BGP 工作階段新增至 router1,請按一下「Configure」。VLAN 連結已填入 Google 和對等 BGP IP 位址。

  9. 記錄每個連結的 IP 位址、ASN 和 VLAN 標記。這些是設定內部部署路由器的必要資訊。

  10. 如要新增 BGP 工作階段,請按一下「儲存設定」。在內部部署路由器上設定 BGP 之前,BGP 工作階段會一直保持停用狀態。

  11. int-lga2 連線建立另一個名為 attachment-lga2-central1 的連結。使用 router1 做為這個連結的 Cloud Router。

gcloud

  1. 建立兩個連結,一個用於 int-lga1 Cloud Interconnect 連線和 router1 Cloud Router,另一個用於 int-lga2 連線和 router1

    gcloud compute interconnects attachments create attachment-lga1-central1 \
       --interconnect int-lga1 \
       --router router1
    gcloud compute interconnects attachments create attachment-lga2-central1 \
       --interconnect int-lga2 \
       --router router1
  2. 描述 attachment-lga1-central1 連結以擷取其分配的資源,例如 VLAN ID 和 BGP 對等互連位址;使用這些值設定 Cloud Router 和內部部署路由器:

    gcloud compute interconnects attachments describe attachment-lga1-central1 \
       --region us-central1

    先前的指令會輸出以下資訊:

    cloudRouterIpAddress: 169.254.58.49/29
    creationTimestamp: '2017-08-15T08:34:11.137-07:00'
    customerRouterIpAddress: 169.254.58.50/29
    id: '5630382895290821276'
    interconnect:
    https://www.googleapis.com/compute/v1/projects/customer-project/global/interconnects/int-lga1
    kind: compute#interconnectAttachment
    name: attachment-lga1-central1
    operationalStatus: ACTIVE
    privateInterconnectInfo:
      tag8021q: 1000
    region: https://www.googleapis.com/compute/v1/projects/customer-project/regions/us-central1
    router: https://www.googleapis.com/compute/v1/projects/customer-project/regions/us-central1/routers/router1
    selfLink: https://www.googleapis.com/compute/v1/projects/customer-project/regions/us-central1/interconnectAttachments/attachment-lga1-central1
      
  3. 記錄下列值:

    • tag8021q:指定 VLAN ID,即 1000。VLAN ID 可用於識別通過這個連結的流量。使用這個值可在內部部署路由器上設定具有標記的 VLAN 子介面。
    • 「cloudRouterIpAddress」cloudRouterIpAddress:Cloud Router IP 位址,即 169.254.58.49/29。將這個位址指派給 Cloud Router 介面,並將這個位址指定為內部部署路由器上的相鄰 BGP。
    • 「customerRouterIpAddress」customerRouterIpAddress:客戶路由器 IP 位址,即 169.254.58.50/29。在 Cloud Router 上,將這個位址指定為獲指派 Cloud Router IP 位址的介面上的 BGP 對等位址,並將這個位址指派給內部部署路由器上的 VLAN 子介面。
  4. router1 Cloud Router 上,為 attachment-lga1-central1 連結新增一個介面:

    gcloud compute routers add-interface router1 \
      --interface-name router1-1 \
      --interconnect-attachment attachment-lga1-central1 \
      --ip-address 169.254.58.49 \
      --mask-length 29 \
      --region us-central1
  5. 將 BGP 對等點新增至介面。在這個範例中,內部部署 ASN 為 12345

    gcloud compute routers add-bgp-peer router1 \
      --interface router1-1 \
      --peer-name central1 \
      --peer-ip-address 169.254.58.50 \
      --peer-asn 12345 \
      --region us-central1
  6. 說明 attachment-lga2-central1 連結,然後在 router1 Cloud Router 上設定另一個 BGP 工作階段。

設定地端部署路由器

如要設定內部部署路由器,請使用 VLAN 連結中的資訊。以下範例是 Juniper 路由器設定中的節錄內容。您可以使用此範例做為設定自有路由器的起點。詳情請參閱「設定內部部署路由器」。

interface ae20 {
  flexible-vlan-tagging;
  native-vlan-id 1;
  aggregated-ether-options {
    lacp {
      active;
     }
   }
  unit 1000 {
    vlan-id 1000;
    family inet {
      address 169.254.58.50/29;
    }
  }
}

protocols bgp {
  group google {
    type external;
    multihop {
      ttl 4;
    }
    hold-time 60;
    peer-as 64513;
    local-as 12345;
    local-address 169.254.58.50;
    neighbor 169.254.58.49 {
      ...
    }
  }
}

後續步驟