Add-IpamSubnet

Add-IpamSubnet

Adds a subnet to IPAM.

構文

Parameter Set: AddIpamSubnet0
Add-IpamSubnet [-Name] <String> [-NetworkId] <String> [-AddressSpace <String> ] [-AsJob] [-CimSession <CimSession[]> ] [-CustomConfiguration <String> ] [-Description <String> ] [-NetworkSite <String> ] [-NetworkType <VirtualizationType> ] [-Owner <String> ] [-PassThru] [-ThrottleLimit <Int32> ] [-VirtualSubnetId <UInt32> ] [-VlanId <UInt16[]> ] [-VmmLogicalNetwork <String> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

詳細説明

The Add-IpamSubnet cmdlet adds an IP subnet to an IP Address Management (IPAM) server. Use the cmdlet to add a NonVirtualized, Provider or Customer IP subnet in IPAM. If the network type of the subnet to add is Provider or NonVirtualized, the cmdlet will add it to the default address space, unless you specify an address space. If the network type of the range to add is Customer, you must specify an address space.

You can associate virtualized subnets, either provider or customer, with a logical network and a network site. These properties represent an abstraction of a physical network and are inherited by all ranges and addresses that map to this subnet.

パラメーター

-AddressSpace<String>

Specifies an address space to which this IP address subnet belongs. If you not specify an address space, the cmdlet retrieves data for all address spaces configured in IPAM.

エイリアス

なし

必須?

false

位置は?

named

既定値

Default

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-AsJob

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-CimSession<CimSession[]>

リモート セッションまたはリモート コンピューターでコマンドレットを実行します。New-CimSession コマンドレットや Get-CimSession コマンドレットの出力など、コンピューター名またはセッション オブジェクトを入力します。既定値は、ローカル コンピューターで実行中の現在のセッションです。

エイリアス

Session

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-CustomConfiguration<String>

Specifies semicolon-separated name/value pairs. This parameter specifies custom metadata that is associated with the address space.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-Description<String>

Specifies a description of the subnet.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-Name<String>

Specifies a name for the subnet.

エイリアス

なし

必須?

true

位置は?

2

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-NetworkId<String>

Specifies the network and the prefix for the given subnet. Specify the network ID in Classless Interdomain Routing (CIDR) notation in the format Network/Prefix.

エイリアス

なし

必須?

true

位置は?

3

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-NetworkSite<String>

Specifies a network site that is associated with a logical network and forms an abstraction of the physical network. A logical network can contain many network sites. This property is inherited by all ranges and addresses associated with the given subnet.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-NetworkType<VirtualizationType>

Specifies an array of of network types for the addresses to add. このパラメーターに対して使用できる値:

-- Provider
-- Customer
-- NonVirtualized

If the value of the AddressSpace parameter is Default, then this parameter can take the value Provider or NonVirtualized. If the value of the AddressSpace parameter is Provider, then the value of this parameter, if specified, must be Provider. Specifying any other value for this parameter will result in an error. Similarly, if the value of the AddressSpace parameter is Customer, then the value of this parameter, if specified, must be Customer. Specifying any other value for this parameter will result in an error.

If you do not specify this parameter, the network type defaults to NonVirtualized.

エイリアス

なし

必須?

false

位置は?

named

既定値

NonVirtualized

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-Owner<String>

Specifies the name of an owner for the subnet.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-PassThru

作業中の項目を表すオブジェクトを返します。既定では、このコマンドレットによる出力はありません。

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-ThrottleLimit<Int32>

このコマンドレットを実行するために確立できる最大同時操作数を指定します。このパラメーターを省略するか、値として 0 を入力した場合、Windows PowerShell® では、コンピューターで実行している CIM コマンドレットの数に基づいて、コマンドレットに対する最適なスロットル制限を計算します。スロットル制限は現在のコマンドレットのみに適用され、セッションまたはコンピューターには適用されません。

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-VirtualSubnetId<UInt32>

Specifies a virtual subnet ID. When you use network virtualization, this property, along with Customer address and Provider address is used to route packets to a particular customer VM.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-VlanId<UInt16[]>

Specifies an array of unique identifiers for VLANs.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-VmmLogicalNetwork<String>

Specifies the abstraction of a physical network that describes a particular function in your environment such as backend or frontend.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

パイプライン入力を許可する

True (ByPropertyName)

ワイルドカード文字を許可する

false

-Confirm

コマンドレットを実行する前に、ユーザーに確認を求めます。

必須?

false

位置は?

named

既定値

false

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-WhatIf

コマンドレットを実行するとどのような結果になるかを表示します。コマンドレットは実行されません。

必須?

false

位置は?

named

既定値

false

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

<CommonParameters>

このコマンドレットは次の共通パラメーターをサポートします。-Verbose、-Debug、-ErrorAction、-ErrorVariable、-OutBuffer、-OutVariable.詳細については、以下を参照してください。 about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216)。

入力

入力型は、コマンドレットにパイプできるオブジェクトの型です。

出力

出力型は、コマンドレットによって生成されるオブジェクトの型です。

  • CimInstance#ROOT/microsoft/ipam/MSFT_IPAM_Subnet

    Represents an IP Subnet in IPAM Server.

Example 1: Add a subnet

This command adds an IPv4 subnet and associates it with VLANs.

PS C:\>Add-IpamSubnet -Name Contoso_2 -NetworkId 10.12.0.0/16 -VlanId 13,10 -PassThru

Example 2: Add a subnet to the default address space

This command adds an IPV4 subnet with network type provider to the default address space.

PS C:\> Add-IpamSubnet -Name Contoso_3 -NetworkId 10.13.0.0/16 -NetworkType Provider -VmmLogicalNetwork Storage -NetworkSite Site03 -VlanId 13,10 -PassThru

Example 3: Add a subnet for a customer network type

This command adds an IPv4 subnet with network type customer.

PS C:\> Add-IpamSubnet -Name Contoso_3 -NetworkId 10.13.0.0/16 -NetworkType Customer -AddressSpace NetCat -VmmLogicalNetwork Storage -NetworkSite Site03 -VirtualSubnetId 10 -PassThru

Example 4: Add a subnet and attach metadata

This command adds physical subnets and attaches AD Site metadata to the subnets.

PS C:\> Add-IpamSubnet -Name Contosov6_10 -NetworkId 2001:db8::ff00/120 -CustomConfiguration "Country=United States;ADSite=Site01" | Format-List Name, NetworkId, Overlapping, CustomConfiguration

関連トピック

Export-IpamSubnet

Get-IpamSubnet

Import-IpamSubnet

Remove-IpamSubnet

Set-IpamSubnet