17

Why are Class C IP addresses preferred over A and B in private networks?

My possible answer is "In class C, the number of host IP address available in the network is less than class A or B thus making it easier for DHCP to manage." But I'd like to double confirm.

mauris
  • 283
  • 1
  • 3
  • 9
  • are you asking for home use or more generally? – quack quixote Feb 22 '10 at 18:40
  • 1
    also note classes A/B/C/D/E are obsolete terms (see http://en.wikipedia.org/wiki/Classful_network#The_replacement_of_classes ); today we use CIDR, and "class C" is equivalent to "x.x.x.x/24"; see http://en.wikipedia.org/wiki/Classless_Inter-Domain_Routing#Prefix_aggregation – quack quixote Feb 22 '10 at 18:55
  • 2
    @quack: True except when you're referring to RFC1918 addresses. CIDR and VLSM is really only relevant to publicly routable addresses. RFC1918 addresses can still be considered classful. – joeqwerty Feb 22 '10 at 19:34
  • 1
    @joeqwerty: have you *read* RFC1918? *it* refers to the 3 private sections by CIDR. http://www.faqs.org/rfcs/rfc1918.html i use it at home to carve out my own 10.x.x.0/24. – quack quixote Feb 22 '10 at 21:24
  • 1
    I know, I know. I'm just saying that most people learned ip addressing as classful addressing, and that's what sticks in their minds when they talk about ip addressing. I read the question and understood what the OP meant when he referred to ip address "classes". – joeqwerty Feb 22 '10 at 21:34
  • 1
    @joeqwerty: then don't state that RFC1918 is an exception to the rule when it isn't. that's just confusing. i learned IP addressing as classful too, and i'm not opposed to it as a teaching tool. but there's a difference between simplifying for a learner and misstating the facts, and your comments on this post are more the latter than the former. – quack quixote Feb 22 '10 at 21:41
  • @quack: I'm not trying to argue, but I feel that your argument is wrong. RFC1918 refers to the private ip address ranges in their classful, pre-CIDR notation form. RFC1519 defines CIDR and it's intended goals had nothing to do with defining, allocating, or managing the private ip address ranges laid out in RFC1918. – joeqwerty Feb 22 '10 at 22:30
  • @quack: Also, all due respect in my responses to you. No offense intended. – joeqwerty Feb 22 '10 at 22:31
  • This reminds me of C++ guys getting annoyed by the antiquated term STL, when it should be referred to as the standard library. – doug65536 Oct 02 '16 at 23:07

4 Answers4

26

I don't think they're preferred. I've seen plenty of networks using RFC1918 class A, B, and C addressing schemes. Use the class that suits your needs:

  1. How many subnets do you need?

  2. How many hosts per subnet do you need?

  3. What routing needs do you have to route traffic between subnets?

  4. Do you anticipate having a large number of hosts per subnet and want to reduce the size of your broadcast domains?

joeqwerty
  • 109,901
  • 6
  • 81
  • 172
7

It would be nice if people stopped talking about class A B and C networks. Such things haven't been used in a very long time and are worse than meaningless and are best used as "gotcha" questions on interviews or punchlines of jokes about greybeards.

By class A, do you mean a network with a /8 netmask or do you mean that the first octet is between 0 and 127? By class B do you mean a /16 or the first octet is between 128 and 192? Why are you talking about classful networks in the first place?

For private addresses, the distinction is silly. RFC1918 defines several networks that shouldn't be globally routed, including 10.0.0.0/8 (a true class A), 172.16.0.0/12 (in a class B network range but consisting of 16 contiguous "class B" networks), or 192.168.0.0/16 (which is 256 contiguous "class C" networks).

As Kazoom said, people talk about subnets based on their subnet mask, not the size of the first octet (which implied subnet mask in the "classful" days).

And, if you're asking this question because it is part of some coursework, you should get pissed at your instructor for not getting his head out of the early 1990s (1993, according to wikipedia). Your instructor is wasting your time and probably money as well, unless your class is "the history of the internet and antique routing protocols" which hopefully also would include uucp and bitnet as well as rip and decnet and maybe SNA.

chris
  • 11,944
  • 6
  • 42
  • 51
  • 2
    @chris: With all due respect, I think people refer to them as classful addresses because that's what they learned and are familiar with. Most people deal with RFC1918 internal addresses and as such refer to them as class A, B, and C. If your internal network is 172.21.0.0 with a mask of 255.240.0.0 (172.16.0.0/12 in CIDR notation), then that is in fact a class B classful description. It's a matter of nomenclature semantics as far as I can see. – joeqwerty Feb 22 '10 at 20:26
  • 4
    @Joe, while Chris's response may have crossed a bit into troll territory, he makes good points. The class notation has been antiquated for 17 yreas, and people really should have switched by now. – Chris S Feb 22 '10 at 21:01
  • True enough. Time for old dogs to learn new tricks I suppose. – joeqwerty Feb 22 '10 at 21:02
  • @joeqwerty. You are incorrect. A classful network *must* have the netmask align with an 8 bit boundary. This is why they were gotten rid of. a 172.21.0.0 class B network would have to have a netmask of 255.255.0.0. That's why people got rid of the notion of "classful" network notation. If even an expert uses the "class" notation incorrectly, how can anyone be expected to usefully use it in conversation? – chris Feb 22 '10 at 23:56
  • 1
    @chris: You're right. I was looking at the CIDR notation when I wrote my comment. A network of 172.21.0.0 with a mask of 255.255.0.0 would be a class B network in the 172.16/12 block. – joeqwerty Feb 23 '10 at 00:14
  • 2
    @chris: I think even experts use the "class" notation incorrectly precisely because it's been dead for so long. For some reason "class C" seems to have stuck around and morphed to mean "any arbitrary /24". I've seen some very knowledgeable people refer to a given address as a "class C" even though its leading bits aren't necessarily 110. – Gerald Combs Feb 23 '10 at 17:27
1

No good reason.

I personally use chunks of 10. it's easy to remember, and I've got plenty of room to subnet, if I want to. :-D

Ronald Pottol
  • 1,703
  • 1
  • 11
  • 19
1

If a /24 is good enough for Linksys, Netgear, Buffalo, Apple, and every other consumer-grade device manufacturer then it's good enough for me.

Gerald Combs
  • 6,441
  • 25
  • 35
  • 1
    a /24 is *not* a "class C" network. a class C network is one where the first octet is between 192 and 223 *and* the subnet mask is 255.255.255.0 (or /24 in modern cidr notation). – chris Feb 23 '10 at 01:59
  • 2
    Perhaps the joke was too obscure/subtle? http://www.barrypopik.com/index.php/texas/entry/if_english_was_good_enough_for_jesus_its_good_enough_for_texas – Gerald Combs Feb 23 '10 at 17:05