Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] network configuration: netmask
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
Vieri
Guru
Guru


Joined: 18 Dec 2005
Posts: 533

PostPosted: Thu Oct 01, 2015 7:51 am    Post subject: [SOLVED] network configuration: netmask Reply with quote

Hi,

My LAN has several network address ranges that I cannot change (corporate decision). So hosts in the same physical LAN must be within any one of these three subnets:

Code:
10.215.144.0/22
10.215.246.0/23
10.215.248.0/24


No traffic restrictions between all of these hosts. So no VLANs needed. All hosts within these three subnets should be able to communicate freely within the LAN.

At first, I set up each host in the network with IP addresses and network masks such as:

EXAMPLE HOST 1:

Code:
config_eth0="10.215.146.90/16"
routes_eth0="default via 10.215.144.91"


EXAMPLE HOST 2:

Code:
config_eth0="10.215.247.91/16"
routes_eth0="default via 10.215.144.91"


EXAMPLE HOST 3:

Code:
config_eth0="10.215.248.92/16"
routes_eth0="default via 10.215.144.91"


That works well and hosts 1, 2 and 3 can communicate just fine.

Then I changed the setup and defined the following configurations:

EXAMPLE HOST 1:

Code:
config_eth0="10.215.146.90/22"
routes_eth0="10.215.246.0/23 dev eth0 proto kernel scope link src 10.215.146.90 metric 1
10.215.248.0/24 dev eth0 proto kernel scope link src 10.215.146.90 metric 1
default via 10.215.144.91"


EXAMPLE HOST 2:

Code:
config_eth0="10.215.247.91/23"
routes_eth0="10.215.144.0/22 dev eth0 proto kernel scope link src 10.215.247.91 metric 1
10.215.248.0/24 dev eth0 proto kernel scope link src 10.215.247.91 metric 1
default via 10.215.144.91"


EXAMPLE HOST 3:

Code:
config_eth0="10.215.248.92/24"
routes_eth0="10.215.144.0/22 dev eth0 proto kernel scope link src 10.215.248.92 metric 1
10.215.246.0/23 dev eth0 proto kernel scope link src 10.215.248.92 metric 1
default via 10.215.144.91"


This also works well and hosts 1, 2 and 3 can communicate just fine.

Now I'd like to know what the differences between the two are. Pros and cons.
Any concerns as far as bandwidth usage/"network chatter" when using an extensive netmask (16)?

Thanks,

Vieri


Last edited by Vieri on Fri Oct 02, 2015 8:47 am; edited 1 time in total
Back to top
View user's profile Send private message
szatox
Veteran
Veteran


Joined: 27 Aug 2013
Posts: 1717

PostPosted: Thu Oct 01, 2015 5:32 pm    Post subject: Reply with quote

Mask defines your network's broadcast address and scope of routing rules.
Using network 10.215/16 means your broadcast address is 10.215.255.255 and traffic to any IP within range 10.215.0.0-10.215.255.255 will not be routed via gateways (unless you specify a gateway for smaller range)
As long as your netmask doesn't generate conflicts, it's fine.
Back to top
View user's profile Send private message
Vieri
Guru
Guru


Joined: 18 Dec 2005
Posts: 533

PostPosted: Fri Oct 02, 2015 8:48 am    Post subject: Reply with quote

Thanks!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum