CIDR question

easternNY

Honorable
May 30, 2012
1
0
10,510
Hi,

noob here with a question on CIDR notation.

What is the difference between 192.168.1.1/24 and 192.168.1.0/24?

They cover the same IP ranges and subnets, but I'm curious of the difference of .0/24 and .1/24.

Many thanks in advance
 
You're missing something. 192.168.1.1 is not the same as 192.168.1.0. 192.168.1.0 is the network address and is not normally used or is reserved. 192.168.1.1 is a private IP address. The /24 just tells you these two addresses come from the same class C address space.
 

mitchflossin

Distinguished
Dec 13, 2009
73
0
18,640
Although Hawkeye22 is right, technically, there is no difference in either of those IP addresses. The /24 says the first 24 bits must match but it doesn't care about the last 8. Whether it's 192.168.1.1 /24, 192.168.1.0 /24, 192.168.1.159 /24 and so on.. as long as the /24 is there, it's essentially saying 192.168.1.anything. If it were a /32, then there would be a difference, and .0 wouldn't be an acceptable host (reserved for the network address).

 

Simo606

Honorable
May 11, 2012
292
0
10,860
/24 can be represented many different ways and they all mean the same thing.

As represented by a subnet mask /24 is: 255.255.255.0

As represented by binary /24 is: 11111111.11111111.11111111.00000000. 4 octets of 8 bits each. The 1's represent network bits, there are 24 in total in a /24 network, with 8 host bits left. Only the host bits can change for this particular classful network of /24. Classful network are /8, /16 and /24. Classless network are everything in between from /1 to /32 excluding /8, /16 and /24.

To address your question now.

192.168.1.0 and 192.168.1.1 are indeed in the same network, which I am sure you are aware of.

Typically the first address of a network is the: network address = 192.168.1.0 /24 - based from network range provided in question.
And the last address is typically the: broadcast address = 192.168.1.255 /24

Also note that network addresses must be even numbers. Don't worry though, when you create subnets the first address can be nothing but an even number if you create the subnets correctly.

So the difference is:
192.168.1.0 is the network address
192.168.1.1 is a host address (used to assign to any host IP interface)

Regardless of it's relevance here is a great chart to refer to:
http://wb2bwu.org/drupal617/sites/default/files/pictures/VLSM_chart.jpg