LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Network Mask (https://www.linuxquestions.org/questions/linux-newbie-8/network-mask-4175512566/)

kiss_freely 07-28-2014 11:52 PM

Network Mask
 
Hi all, I saw my IP address of WAN connection has a format 118.71.9.128/255.255.255.255. I have a little knowledge about subnet mask. so I don't know why my WAN IP address has all value of mask is 255 ?. I think that the ending value of mask is lower 255.

Thank you!

notKlaatu 07-29-2014 12:00 AM

Where do you see this?

The mask of you computer itself would be 255.255.255.255, because it only has one IP address, yes?

If that really is you subnet mask then...yes, that is awfully restricted and means that your network essentially consists of one node. But I don't think that is what it is saying. Context would help, though.

kiss_freely 07-29-2014 01:19 AM

Thank notKlaatu, but I really don't understand about network mask. I know that IP version 4 includes 32 bits and was divided into 2 parts (network and host). IP Address 118.71.9.128 belong to Class A with default mask is 255.0.0.0. The first 8 bits for network ID, the remaining 24 bits for host ID. If its mask is 255.255.255.255, all 32 bits for network. so which bit for host part?.

notKlaatu 07-29-2014 02:37 AM

Wull, the first set of numbers would be for the Class A, as you said. So that would be the 255 in the 255.x.x.x part. So if you're on some ISP's network of 118.x.x.x then a mask of '255' means that there's only ONE slot open (because out of 256, 255 are masked out; there is one left, and that one is, in your case, 118. In my case, since my IP address starts with 78, that's where I am).

The next part is the same; x.255.x.x simply says listen on ONE network slot. In your case, it's listening to 71.

The third is the same...255 means one slot is NOT masked, so your computer is listening to 9. That's usually what people are talking about when it comes to subnets. Because in a local network, you might have 487 computers but only 256 addresses. What do you do? you break your network into two subnets, like
192.168.0.x
and
192.168.1.x

If 192.168.0.x is being told to listen in only ONE slot, however, it will never hear any computer living on 192.168.1.x, right? So you would need to open up the mask from something like 255.255.255.x to, say, 255.255.254.x

Does that make sense? It gets confusing because there are a LOT of numbers involved, but you have to believe that most of them are arbitrary; if something has a "mask" of 255 out of 256, then no matter what, it's going to listen to ONE number. If you tell it that that number is 118, then it will listen to traffic on 118.. If you tell it that it's 14, then it'll listen to traffic on 14. It doesn't care WHAT the number is, it only knows that it only listenss to ONE number. If you open the mask to 254 out of 256, then it will listen to TWO numbers, and you can tell it ANY two numbers and it will listen.

Sys admin'ing is fun!

r0b0 07-29-2014 08:27 AM

Quote:

Originally Posted by kiss_freely (Post 5211137)
Hi all, I saw my IP address of WAN connection has a format 118.71.9.128/255.255.255.255. I have a little knowledge about subnet mask. so I don't know why my WAN IP address has all value of mask is 255 ?. I think that the ending value of mask is lower 255.

This is completely normal. It means that you are on a Point-To-Point link. There is no "subnet", there is no "local network". All communication from your address will be sent directly to the other end of the link - your ISP I assume - and they will take care of routing it further.

kiss_freely 07-30-2014 09:07 AM

Thank r0b0 & notKlaatu.

szboardstretcher 07-30-2014 09:15 AM

PPP links don't need subnets. Heck, they don't even need IP addresses.

There is a computer on either end of the link, that is it. So there is nowhere else for the traffic to go, but to the other end.


All times are GMT -5. The time now is 08:34 PM.