Get-​Azure​Subnet​Route​Table

Gets a route table for a subnet.

Syntax

Get-AzureSubnetRouteTable
   [-Detailed]
   [-Profile <AzureSMProfile>]
   -SubnetName <String>
   -VirtualNetworkName <String>
   [<CommonParameters>]

Description

The Get-AzureSubnetRouteTable cmdlet gets the route table that is associated with a subnet.

Examples

Example 1: Display routes for a subnet

PS C:\> Get-AzureSubnetRouteTable -VirtualNetworkName "VNetUSCentral" -SubnetName "ContosoSubnet" -Detailed
Routes                        Name                          Location                      Label
------                        ----                          --------                      -----
{internetroute}               PublicRT                      Central US                    Sample RT in Central US

This command displays the routes in the route table name that is associated with subnet named ContosoSubnet.

Required Parameters

-SubnetName

Specifies the subnet for which this cmdlet gets the route table.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VirtualNetworkName

Specifies the name of a virtual network that contains the subnet for which this cmdlet gets the route table.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Optional Parameters

-Detailed

Indicates that this cmdlet displays the routes in the route table that is associated with the subnet.

Type:SwitchParameter
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Profile

Specifies the Azure profile from which this cmdlet reads. If you do not specify a profile, this cmdlet reads from the local default profile.

Type:AzureSMProfile
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False