Need help to understand subnetting question

hkuvehkuve Registered Users Posts: 2 ■□□□□□□□□□
I have 192.168.4.0 network and it's subnetted with /26 mask and I need to know please what is the ip address can be assigned to host within the same subnet ??

from 192.168.4.X to 192.168.4.x

Thanks

Comments

  • bdepak.003bdepak.003 Member Posts: 16 ■□□□□□□□□□
    Since it is /26, so 6 bits are left, so 2^6=64, 2^6-2 = 62 (Usable host per subnet)

    /26 = 0, 64, 128, 192, 256

    i.e, 62 host per subnet

    192.168.4.1 to 192.168.4.62
    192.168.4.65 to 192.168.4.126
    192.168.4.129 to 192.168.4.190
    192.168.4.193 to 192.168.4.254

    I believe this will make you clear, if you still have any problems to understand please feel free to ask.
  • RouteMyPacketRouteMyPacket Member Posts: 1,104
    Perfect explanation bdepak but I prefer to keep it simplistic for people new to subnetting. Subnetting appears to be a monster to the inexperienced eye/mind. The 2^6 power bla bla bla is overkill IMO

    128 64 32 16 8 4 2 1

    You have a /26 right? Ok so we know the first 24 are used so that gives us

    255.255.255.x So what is our 4th octet going to be?

    Now using our scale above, let's use the first two (128 64 ) of them to get our 26 bits

    128 + 64 = 192

    Ok so we now have a subnet mask of 255.255.255.192

    Now how many hosts do we have with this /26 network?

    256 - 192 = 64

    Ok, we have 64 hosts so let's break this down properly because we know we cannot use the "network" and "broadcast" addresses right? Which will be what? They will be 0 and 63 so let's see what we have here

    192.168.4.0/26 will be

    192.168.4.1 - 192.168.4.62 (these are our available IP's on this segment).

    Now if we really needed more segments from your original /24 (192.168.4.0) then we can break them as follows (all /26 FYI)

    192.168.4.0 - 192.168.4.63 (our network we needed right?)
    192.168.4.64 - 192.168.4.127
    192.168.4.128 - 192.168.4.191
    192.168.4.192 - 192.168.4.254

    Keep it simplistic, subnetting is not this major undertaking so many explain it to be. There are numerous ways to achieve our subnetting goals, it's about finding the "method" that works for you.


    Through experience and repetition you will simply look at and see the CIDR notations and immediately know the network segments in your head.
    Modularity and Design Simplicity:

    Think of the 2:00 a.m. test—if you were awakened in the
    middle of the night because of a network problem and had to figure out the
    traffic flows in your network while you were half asleep, could you do it?
  • bdepak.003bdepak.003 Member Posts: 16 ■□□□□□□□□□
    Thanks for your advice RouteMyPacket. Compliment for your explanation.
  • hkuvehkuve Registered Users Posts: 2 ■□□□□□□□□□
    Thanks all for your help

    can I ask another question please?

    If I have ip address of 192.168.1.42 255.255.255.248 , what is the subnet address?

    Thanks
  • tayro12tayro12 Member Posts: 17 ■□□□□□□□□□
    Hi hkuve,

    255.255.255.248 = /29 that means it has increment of 8 that means,

    192.168.1.42
    255.255.255.248

    your focus would be the .42 since 255 means value will remain the same, count by 8, so 8 + 8 = 16 + 8 = 24 + 8 = 32 + 8 = 40 if you add another 8 it will overlap with .42 hence your network is: 192.168.1.40

    other info:
    192.168.1.47 = Broadcast

    usable IP address are: 192.168.1.41 - 192.168.1.46
  • bbarrickbbarrick Member Posts: 242 ■■■□□□□□□□
  • Sy KosysSy Kosys Member Posts: 105 ■■■□□□□□□□
    The increment is 8.

    Simple reverse math to verify:
    Since the binary range is 0 to 255, that is a total of 256 numbers (in base 10 counting, what we normally do as humans).
    Subtract the octet that is NOT 255 (248 in the above example) FROM the value of 256
    >>>> 256 - 248 = 8 <<<<

    The subnet value subtracted from 256 will ALWAYS equal the block size (increment). Presuming the 4th octet is the one being changed:
    256 - 252 = /30 = Block/Increment of 4
    256 - 224 = /27 = 32 block size
    256 - 192 = /26 = 64 block size
    256 - 128 = /25 = 128 block size

    For changes in the other octets, the math is the same and the block size is the same, just the slash notation is obviously different (and subsequently so is the subnet mask).
    "The size of your dreams must always exceed your current capacity to achieve them. If your dreams do not scare you, they are not big enough.”
    ― Ellen Johnson Sirleaf
  • bbarrickbbarrick Member Posts: 242 ■■■□□□□□□□
    I shouldn't post so early in the morning. I don't know where 3 came from, that was me before the coffee.
  • tayro12tayro12 Member Posts: 17 ■□□□□□□□□□
    @bbarrick

    it's 8

    Please find a simple table to help remember the increment.

    Increment: 128 64 32 16 8 4 2 1
    Mask: 128 192 224 240 248 252 254 255
    /9 /10 /11 /12 /13 /14 /15 /16
    /17 /18 /19 /20 /21 /22 /23 /24
    /25 /26 /27 /28 /29 /30 /31 /32


    hope this helps.
  • Sy KosysSy Kosys Member Posts: 105 ■■■□□□□□□□
    bbarrick wrote: »
    I shouldn't post so early in the morning. I don't know where 3 came from, that was me before the coffee.
    lol i hear ya man...im trying to settle my nerves, icnd2 exam in 3hrs and im a bit loopy. One more java may do the trick ;)
    "The size of your dreams must always exceed your current capacity to achieve them. If your dreams do not scare you, they are not big enough.”
    ― Ellen Johnson Sirleaf
  • yengiangyengiang Member Posts: 33 ■■■□□□□□□□
    Back to the 192.168.4.0/26

    Please explain.

    Which two addresses can be assigned to hosts within the same subnet? (Choose two.)

    A. 192.168.4.61
    B. 192.168.4.63
    C. 192.168.4.67
    D. 192.168.4.125
    E. 192.168.4.128
    F. 192.168.4.132

    Thanks
  • VenomSdMVenomSdM Member Posts: 20 ■■■□□□□□□□
    Correct answer are C and D ihmo

    192.168.4.0/26 is a class C so we can take /24 as default mask.
    We would have 26-24=2 so 2^2= 4 subnets
    We would gave 32-26=6 so 2^6-2=64-2=62 hosts available per subnet

    Subnet 1 ---> network:192.168.4.0 ## hosts available from 192.168.4.1 to 192.168.4.62 ## broadcast: 192.168.0.4.63
    Subnet 2 ---> network:192.168.4.64 ## hosts available from 192.168.4.65 to 192.168.4.126 ## broadcast: 192.168.0.4.127
    Subnet 3 ---> network:192.168.4.128 ## hosts available from 192.168.4.129 to 192.168.4.190 ## broadcast: 192.168.0.4.191
    Subnet 4 ---> network:192.168.4.192 ## hosts available from 192.168.4.193 to 192.168.4.254 ## broadcast: 192.168.0.4.255
  • Sy KosysSy Kosys Member Posts: 105 ■■■□□□□□□□
    yengiang wrote: »
    Back to the 192.168.4.0/26

    Please explain.

    Which two addresses can be assigned to hosts within the same subnet? (Choose two.)

    A. 192.168.4.61
    B. 192.168.4.63
    C. 192.168.4.67
    D. 192.168.4.125
    E. 192.168.4.128
    F. 192.168.4.132

    Thanks

    First thing to do is find your networks, based upon the address given and the CIDR notation.
    192.168.4.0 will be the first network, now use the slash notation (/26) to find the increment/block size/next network.
    4 Octets of 8 bits each is 32bits total. 26 bits are reserved for the network, leaving 32 - 26 = 6 bits remaining for hosts.
    2^6 = 64, that is the block size (block, meaning size of the subnet in the main network address of 192.168.4.0).

    Now we know the block size, lets write down the subnet addresses:
    192.168.4.0 .... 192.168.4.64 .... 192.168.4.128 .... 192.168.4.192
    (the next network address from here would be 192.168.5.0, which is out of scope from the 4.0 network being subnetted)

    Now that we have the subnetworks listed, work on the broadcast addresses. Easily enough done, they are simply 1 less than the next subnet:
    Network 192.168.4.0 Broadcast 192.168.4.63
    Network 192.168.4.64 Broadcast 192.168.4.127
    Network 192.168.4.128 Broadcast 192.168.4.191
    Network 192.168.4.192 Broadcast 192.168.4.255

    Network addresses known, broadcast addresses figured out, last thing is the valid host range. Remember using 2^6=64 to get the increment? Since one of those 64 is for the network, another for the broadcast, use (2^6)-2 to calculate how many hosts (62, in this case):
    Net 192.168.4.0 ... Range 192.168.4.1 - 192.168.4.62 ... Bcast 192.168.4.63
    Net 192.168.4.64 ... Range 192.168.4.65 - 192.168.4.126 ... Bcast 192.168.4.127
    Net 192.168.4.128 ... Range 192.168.4.129 - 192.168.4.190 ... Bcast 192.168.4.191
    Net 192.168.4.192 ... Range 192.168.4.193 - 192.168.4.254 ... Bcast 192.168.4.255

    Now where do your 6 listed addresses fit? Which subnetwork do they go? AND are they a host, network, or broadcast address?
    A. 192.168.4.61 is a valid host within the 192.168.4.0 network
    B. 192.168.4.63 is the broadcast address within the 192.168.4.0 network
    C. 192.168.4.67 is a valid host within the 192.168.4.64 network
    D. 192.168.4.125 is a valid host within the 192.168.4.64 network

    E. 192.168.4.128 is a network address
    F. 192.168.4.132 is a valid host within the 192.168.4.128 network

    Going thru the CCNA course last year at school, I wrote a spreadsheet that helps validate the VLSM subnetting. Can't attach it to this, maybe i can send via PM lol.

    HTH
    "The size of your dreams must always exceed your current capacity to achieve them. If your dreams do not scare you, they are not big enough.”
    ― Ellen Johnson Sirleaf
  • yengiangyengiang Member Posts: 33 ■■■□□□□□□□
    Thank you so much.

    Should I post a new thread or use this one if I have another subnetting question?
  • VenomSdMVenomSdM Member Posts: 20 ■■■□□□□□□□
    Thy this one, i'm happy to help and in the same time i pratice for my exam :D
Sign In or Register to comment.