Remove-IpamAddress

Remove-IpamAddress

Removes a set of addresses from IPAM.

構文

Parameter Set: ByAddress
Remove-IpamAddress [-IpAddress] <IPAddress[]> [[-ManagedByService] <String[]> ] [[-ServiceInstance] <String[]> ] [-AddressSpace <String[]> ] [-AsJob] [-CimSession <CimSession[]> ] [-Force] [-NetworkType <VirtualizationType[]> ] [-PassThru] [-ThrottleLimit <Int32> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: InputObject (cdxml)
Remove-IpamAddress -InputObject <CimInstance[]> [-AsJob] [-CimSession <CimSession[]> ] [-Force] [-PassThru] [-ThrottleLimit <Int32> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

詳細説明

The Remove-IpamAddress cmdlet removes a set of addresses from IP Address Management (IPAM). The cmdlet removes the specified IP address records permanently from the IPAM database. Specify the IP addresses to remove or use the InputObject parameter to specify an IpamAddress object to remove.

The cmdlet does not remove any reservations on the Dynamic Host Configuration Protocol (DHCP) server or Domain Name System (DNS) records. You can use Windows PowerShell for DHCP Server to remove a reservation from the DCHP server. You can use Windows PowerShell for DNS to remove the DNS records associated with the IP addresses that you remove.

パラメーター

-AddressSpace<String[]>

Specifies an array of address spaces. The cmdlet removes the addresses that belong to the address spaces that you specify. If you specify this parameter, you must specify the IpAddress parameter.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

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

True (ByPropertyName)

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

false

-AsJob

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

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

false

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

false

-CimSession<CimSession[]>

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

エイリアス

Session

必須?

false

位置は?

named

既定値

なし

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

false

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

false

-Force

ユーザーの確認を求めずにコマンドを強制的に実行します。

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

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

false

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

false

-InputObject<CimInstance[]>

このコマンドレットへの入力を指定します。このパラメーターを使用するか、パイプを使用して入力をこのコマンドレットに渡すことができます。

エイリアス

なし

必須?

true

位置は?

named

既定値

なし

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

True (ByValue)

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

false

-IpAddress<IPAddress[]>

Specifies an array of IP addresses.

エイリアス

なし

必須?

true

位置は?

2

既定値

なし

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

True (ByPropertyName)

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

false

-ManagedByService<String[]>

Specifies an array of services that manage the IP addresses that you specify in the IpAddress parameter. If you specify this parameter, you must specify the IpAddress parameter.

The values that you specify for this parameter must exist in the set of values that you defined for the ManagedByService custom field in IPAM.

エイリアス

MB

必須?

false

位置は?

3

既定値

なし

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

True (ByPropertyName)

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

false

-NetworkType<VirtualizationType[]>

Specifies the network type of the address. このパラメーターに対して使用できる値:

-- Provider
-- Customer
-- NonVirtualized

The default value is NonVirtualized.

If you specify Default for the AddressSpace parameter, the valid values for this parameter are Provider and NonVirtualized. If you specify a provider type of address space for the AddressSpace parameter, you must specify Provider for this parameter. If you specify a customer type of address space for the AddressSpace parameter, you must specify Customer for this parameter.

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

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

True (ByPropertyName)

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

false

-PassThru

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

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

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

false

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

false

-ServiceInstance<String[]>

Specifies an array of instances of the services that manage the IP addresses. Specify the instances of the services that you specified for the ManagedByService parameter. If you specify this parameter, you must specify the IpAddress parameter. The value that you specify for this parameter must exist in the set of values that you defined for the ServiceInstance custom field in IPAM.

エイリアス

SI

必須?

false

位置は?

4

既定値

なし

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

True (ByPropertyName)

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

false

-ThrottleLimit<Int32>

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

エイリアス

なし

必須?

false

位置は?

named

既定値

なし

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

false

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

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)。

入力

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

出力

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

  • IpamAddress

    Represents an IP address on the IPAM server.

Example 1: Remove all IP addresses in range

This example removes all IP addresses in a range.

The first command uses the Get-IpamRange cmdlet to get an IpamRange object that contains the addresses that belong to a range of IP addresses. The command stores the object in the $Range variable.

The second command uses the Get-IpamAddress cmdlet to get an IpamAddress object that contains the IP addresses that map to the range stored in the $Range variable. The command passes the IpamAddress object to the Remove-IpamAddress cmdlet by using the pipeline operator. The command removes the addresses in the range stored in the $Range variable.

PS C:\> $Range = Get-IpamRange -StartIPAddress 10.12.3.1 -EndIPAddress 10.12.3.254PS C:\>Get-IpamAddress -MappingToRange $Range | Remove-IpamAddress

Example 2: Remove all expired physical addresses managed by IPAM

This command gets an IpamAddress object that contains the physical addresses managed by IPAM that have expired. The command passes the IpamAddress object to the Remove-IpamAddress cmdlet by using the pipeline operator. The Remove-IpamAddress cmdlet removes the IpamAddress object.

PS C:\> Get-IpamAddress -AddressFamily IPv4 -AddressCategory Private -ManagedByService IPAM | Where-Object {$_.ExpiryStatus -eq "Expired"} | Remove-IpamAddress

Example 3: Remove a customer IP address

This command removes the customer IP address 172.16.10.16 from the default address space.

PS C:\> Remove-IpamAddress -IpAddress 172.16.10.16 -AddressSpace "Default"

Example 4: Remove a provider IP address

This command removes the provider IP address 172.16.10.19 from the default address space.

PS C:\> Remove-IpamAddress -IpAddress 172.16.10.19 -AddressSpace "Default" -NetworkType Provider

関連トピック

Get-IpamAddress

Add-IpamAddress

Set-IpamAddress

Import-IpamAddress

Export-IpamAddress

Get-IpamAddressSpace