

기계 번역으로 제공되는 번역입니다. 제공된 번역과 원본 영어의 내용이 상충하는 경우에는 영어 버전이 우선합니다.

# Direct Connect 가상 인터페이스에 대한 접두사 할당 관리
<a name="prefix-allocations"></a>

Direct Connect 연결의 각 가상 인터페이스에 할당된 인바운드 라우팅 접두사 수를 관리할 수 있습니다. AWS Management Console AWS CLI, 또는 AWS SDKs 사용하여 연결의 접두사 풀을 보고, 가상 인터페이스에 접두사를 할당하고, 라우팅 요구 사항이 변경되면 할당을 조정합니다.

**중요**  
가상 인터페이스의 알려진 접두사 수가 할당된 수를 초과하는 경우 해당 가상 인터페이스의 BGP 세션은 유휴 상태(BGP DOWN)로 전환됩니다. 할당이 최소한 광고하려는 접두사 수만큼 큰지 확인합니다.

## 사전 조건
<a name="prefix-allocations-prerequisites"></a>

접두사 할당을 관리하기 전에 다음이 있는지 확인합니다.
+ 활성 Direct Connect 전용 연결 또는 LAG.
+ 하나 이상의 프라이빗 또는 전송 가상 인터페이스.
+ Direct Connect APIs(`directconnect:DescribeConnections`, , `directconnect:DescribeVirtualInterfaces`, `directconnect:DescribeDirectConnectGateways`, `directconnect:UpdateVirtualInterfaceAttributes`, `directconnect:CreateTransitVirtualInterface`)를 호출할 수 있는 권한`directconnect:CreatePrivateVirtualInterface`.

## 연결의 접두사 풀 보기
<a name="prefix-allocations-view-pool"></a>

연결의 접두사 풀을 보고 사용 가능한 접두사 수와 가상 인터페이스에 할당되는 방법을 확인할 수 있습니다.

------
#### [ Console ]

**연결의 접두사 풀을 보려면**

1. [https://console.aws.amazon.com/directconnect/v2/home](https://console.aws.amazon.com/directconnect/v2/home)에서 **Direct Connect** 콘솔을 엽니다.

1. 탐색 창에서 **연결**을 선택합니다.

1. 연결을 선택합니다.

1. 연결 세부 정보 페이지에서 **인바운드 접두사** 카드를 찾습니다.

1. **풀 크기**, **할당되지 않음**, **할당됨** 값을 검토합니다. IPv4 및 IPv6 값은 별도로 표시됩니다.

------
#### [ Command line ]

[describe-connections](https://docs.aws.amazon.com/cli/latest/reference/directconnect/describe-connections.html) 명령을 사용합니다.

```
aws directconnect describe-connections \
    --connection-id {{dxcon-abc12345}}
```

응답에서 다음 필드를 확인합니다.
+ `prefixPoolSizeIpv4` 및 `prefixPoolSizeIpv6`- 풀의 총 접두사 수입니다.
+ `prefixPoolUnallocatedCountIpv4` 및 `prefixPoolUnallocatedCountIpv6`- 가상 인터페이스에 할당되지 않은 접두사 수입니다.

------

## 가상 인터페이스를 생성할 때 접두사 할당 설정
<a name="prefix-allocations-create-vif"></a>

가상 인터페이스를 생성할 때 가상 인터페이스에 대한 접두사 할당을 설정할 수 있습니다. 이렇게 하면 새 가상 인터페이스에 대한 연결 접두사 풀의 일부가 예약됩니다.

------
#### [ Console ]

**가상 인터페이스를 생성할 때 접두사 할당을 설정하려면**

1. [https://console.aws.amazon.com/directconnect/v2/home](https://console.aws.amazon.com/directconnect/v2/home)에서 **Direct Connect** 콘솔을 엽니다.

1. 탐색 창에서 **가상 인터페이스**를 선택합니다.

1. **가상 인터페이스 생성**을 선택합니다.

1. 유형, VLAN 및 BGP ASN을 포함하여 가상 인터페이스 설정을 구성합니다.

1. **인바운드 접두사 할당** 섹션에서 할당할 IPv4 및 IPv6 접두사 수를 입력합니다.

1. **가상 인터페이스 생성**을 선택합니다.

------
#### [ Command line ]

[create-private-virtual-interface](https://docs.aws.amazon.com/cli/latest/reference/directconnect/create-private-virtual-interface.html) 명령을 사용합니다. 다음 예시에서는 접두사 할당을 사용하여 프라이빗 가상 인터페이스를 생성합니다.

```
aws directconnect create-private-virtual-interface \
    --connection-id {{dxcon-abc12345}} \
    --new-private-virtual-interface '{
        "virtualInterfaceName": "{{my-private-vif}}",
        "vlan": {{101}},
        "asn": {{65000}},
        "directConnectGatewayId": "{{d2113d06-a0d8-476b-91a7-8555d9973d12}}",
        "prefixPoolAllocatedCountIpv4": {{500}},
        "prefixPoolAllocatedCountIpv6": {{100}}
    }'
```

------

## 기존 가상 인터페이스에서 접두사 할당 업데이트
<a name="prefix-allocations-update"></a>

기존 가상 인터페이스에서 접두사 할당을 업데이트하여 해당 인터페이스에 예약된 접두사 수를 늘리거나 줄일 수 있습니다.

------
#### [ Console ]

**가상 인터페이스에서 접두사 할당을 업데이트하려면**

1. [https://console.aws.amazon.com/directconnect/v2/home](https://console.aws.amazon.com/directconnect/v2/home)에서 **Direct Connect** 콘솔을 엽니다.

1. 탐색 창에서 **가상 인터페이스**를 선택합니다.

1. 업데이트할 가상 인터페이스를 선택합니다.

1. **편집**을 선택합니다.

1. **IPv4 접두사 할당** 값, **IPv6 접두사 할당** 값 또는 둘 다를 업데이트합니다.

1. **가상 인터페이스 업데이트를** 선택합니다.

------
#### [ Command line ]

[update-virtual-interface-attributes](https://docs.aws.amazon.com/cli/latest/reference/directconnect/update-virtual-interface-attributes.html) 명령을 사용합니다.

```
aws directconnect update-virtual-interface-attributes \
    --virtual-interface-id {{dxvif-abc12345}} \
    --prefix-pool-allocated-count-ipv4 {{500}} \
    --prefix-pool-allocated-count-ipv6 {{100}}
```

------

## Direct Connect 게이트웨이 총 접두사 할당 보기
<a name="prefix-allocations-view-dxgw"></a>

Direct Connect 게이트웨이에 연결된 모든 가상 인터페이스에서 총 접두사 할당을 볼 수 있습니다.

------
#### [ Console ]

**Direct Connect 게이트웨이 총 접두사 할당을 보려면**

1. [https://console.aws.amazon.com/directconnect/v2/home](https://console.aws.amazon.com/directconnect/v2/home)에서 **Direct Connect** 콘솔을 엽니다.

1. 탐색 창에서 **Direct Connect 게이트웨이**를 선택합니다.

1. 게이트웨이를 선택합니다.

1. 게이트웨이 세부 정보 페이지에서 **총 접두사 풀 할당** 값을 검토합니다.

------
#### [ Command line ]

[describe-direct-connect-gateways](https://docs.aws.amazon.com/cli/latest/reference/directconnect/describe-direct-connect-gateways.html) 명령을 사용합니다.

```
aws directconnect describe-direct-connect-gateways \
    --direct-connect-gateway-id {{d2113d06-a0d8-476b-91a7-8555d9973d12}}
```

응답에서 `totalPrefixPoolAllocations` 필드를 확인합니다.

------

## 할당 변경 확인
<a name="prefix-allocations-expected-results"></a>

접두사 할당을 업데이트하면 새 값이 즉시 적용됩니다. BGP 세션은 광고된 접두사 수가 새 할당을 초과하지 않는 한 계속 유지됩니다. API는 할당을 VIF에서 현재 사용 중인 접두사 수 미만으로 줄이기 위한 요청을 거부합니다.

## 문제 해결
<a name="prefix-allocations-troubleshooting"></a>

다음은 접두사 할당을 관리할 때 발생할 수 있는 일반적인 문제입니다.

접두사를 추가하면 BGP 세션이 종료됩니다.  
광고된 접두사 수가 할당된 수를 초과했습니다. `UpdateVirtualInterfaceAttributes` API 또는 콘솔을 사용하여 할당을 늘립니다.

할당을 줄일 수 없음  
VIF의 할당된 값을 현재 사용 중인 접두사 수 미만으로 줄일 수 없습니다. 먼저 온프레미스 디바이스에서 광고하는 접두사 수를 줄인 다음 할당을 줄입니다.

할당을 늘릴 수 없음  
연결의 접두사 풀이 완전히 할당될 수 있습니다. 연결에서 `prefixPoolUnallocatedCountIpv4` 및 `prefixPoolUnallocatedCountIpv6` 값을 확인합니다. 먼저 다른 가상 인터페이스에 대한 할당을 줄여야 할 수 있습니다.

Direct Connect 게이트웨이 합계가 10,000을 초과함  
단일 Direct Connect 게이트웨이에 연결된 가상 인터페이스에서 결합된 모든 IPv4 및 IPv6 할당의 합계는 10,000을 초과할 수 없습니다. 다른 가상 인터페이스에 대한 할당을 줄이거나 두 번째 게이트웨이를 사용합니다.