this post was submitted on 25 Mar 2024
86 points (96.7% liked)

[Outdated, please look at pinned post] Casual Conversation

6590 readers
1 users here now

Share a story, ask a question, or start a conversation about (almost) anything you desire. Maybe you'll make some friends in the process.


RULES

Related discussion-focused communities

founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 1 points 8 months ago* (last edited 8 months ago)

Lemme try: an IP is the address of your computer and only a single number. If you want to group clients you have to define a way to separate these 32bit number into a part that defines the group and a part that defines the number of the client in that group. That's what the netmask is for. Example:

IP: 10.0.0.1

Netmask: 255.255.0.0

In binary this gets more clear:

IP: 0000 1001.0000 0000.0000 0000.0000 0001

Netmask: 1111 1111.1111 1111.0000 0000.0000 0000

The netmask is always a bunch of 1 first, then 0 until you got 32 of it. 1 define the parts of the IP that define the group, 0 the client.

10.0 is the group, 0.1 is the number of the client in our example. All clients which IP begin with 10.0 are in the same group and can talk to each other without needing a router.