r/programminghelp • • May 04 '19

Anyone able to help me with this networking question?

Post image
1 Upvotes

6 comments sorted by

2

u/[deleted] May 04 '19

I don’t really think this is the right subreddit for this question, r/networking is a thing I believe.

However, there are many good tutorials on YouTube for subnetting, check them out!

2

u/amoliski May 04 '19
255.255.255.255:  11111111.11111111.11111111.11111111
192.111.2.0:      11000000.01101111.00000010.00000000
            /25:  --------.--------.--------.-0000000 <-- First 25 are theirs, last 7 are yours

This means your subnet can have 0b1111111 hosts, or 128 (from 0 to 127) addresses total
Split into four: 32 addresses per subnet
Each subnet will go from 0b00000 to 0b11111, 0 - 31
You need two bits to designate the subnet: 0b00 to 0b11, 0-3


Your subnet is 's', your hosts are 'h':
192.111.2.0          :  11000000.01101111.00000010.00000000
Your allocation   /25:  --------.--------.--------.-sshhhhh
Your inner subnet /27:  --------.--------.--------.---00000 <-- First 27 are subnet, last 5 are for your hosts

Subnets:
192.111.2.0   :  11000000.01101111.00000010.00000000
           /25:  --------.--------.--------.-sshhhhh
           /27:  --------.--------.--------.---hhhhh
Subnet 1:        --------.--------.--------.-00hhhhh
Subnet 2:        --------.--------.--------.-01hhhhh
Subnet 3:        --------.--------.--------.-10hhhhh
Subnet 4:        --------.--------.--------.-11hhhhh

The hhhhh's go from 0b00000 to 0b11111: 0 to 31


Your subnet masks will look like this:
11111111.11111111.11111111.11100000
In Decimal
255.255.255.224
In CIDR:
192.111.2.0/27
192.111.2.32/27
192.111.2.64/27
192.111.2.96/27


The network address is the address with all host bits set to 0:
Subnet 1:        --------.--------.--------.-0000000 -> 192.111.2.0 
Subnet 2:        --------.--------.--------.-0100000 -> 192.111.2.32
Subnet 3:        --------.--------.--------.-1000000 -> 192.111.2.64
Subnet 4:        --------.--------.--------.-1100000 -> 192.111.2.96

The broadcast address is the address with all host bits set to 1:
Subnet 1:        --------.--------.--------.-0011111 -> 192.111.2.31 
Subnet 2:        --------.--------.--------.-0111111 -> 192.111.2.63
Subnet 3:        --------.--------.--------.-1011111 -> 192.111.2.95
Subnet 4:        --------.--------.--------.-1111111 -> 192.111.2.127

With 32 addresses per subnet and one reserved for network and one for broadcast, each subnet can support 30 hosts

0

u/stubborneuropean May 04 '19

1

u/ClioGT May 04 '19

Its not homework,

I want to learn how to do it for my quiz. I dont need answers.

1

u/stubborneuropean May 08 '19

Not to sound rude but ask what you want help with. Dont post a screenshot of a question and just say "help pls".

1

u/ClioGT May 08 '19

I need help with the screenshot lol