question

slalithp avatar image
slalithp asked ·

Virtual Network and subnets

Hi, I have a virtual network 192.168.0.0/16 . now, i want to know why do we have to create subnets and what is the whole point of creating subnets when we can directly access the 65,536 ip addresses available in the specified virtual network ip address space.

azure-virtual-machines-networking
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

msrini-MSFT avatar image
msrini-MSFT answered ·

Hi,

In Azure, when you create VNET, you create Address space. In your case, the address space is 192.168.0.0/16. Once that is created, you need to create subnets on which you will be able to deploy any resources.

Address space is the super set and the subnets are the subsets of Address space. If you want to use all the address space, then create a subnet with prefix 192.168.0.0/16 and you will have 65K IPs available for you.

Let me know if you have any further questions.

5 comments Share
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

So, can't i deploy resources on the Virtual network instead of subnets?

0 Votes 0 · ·

When you deploy a resource in a VNET, let say VM, you need to select a subnet. There are no option where you can select the address space. So you need a subnet to deploy a VM, VMSS, ILB, Application Gateway, etc.

2 Votes 2 · ·

okay, nice. can you please kindly tell me why did they develop it in such a way that i have to deploy my resources only in subnet and cannot in vnet?

0 Votes 0 · ·
Show more comments