Subnet question

Subnet question

Post by Anthony Ewel » Sun, 18 Apr 1999 04:00:00



Hi,

Can I get away with this in (Red Hat 5.2) Linux?  And am I making any
errors in my mask, etc.?

     Linux Server

     Two Kingston KNE100TX ethernet card:

         Subnet mask: 255.255.255.240   (FF.FF.FF.F0)  for server and
all clients

              eth0 address: 192.168.255.1
                   Client addresses: 192.168.255.2..127
                   Client default route: 192.168.255.1

              eth1 address: 192.168.255.129
                   Client addresses 192.168.255.130..254
                   Client default route: 192.168.255.129

Am I correct that only traffic with an address on the other subnet gets
routed?

Will samba melt down under this arrangement?

Many thanks,
--Tony

 
 
 

Subnet question

Post by Luca Filipoz » Sun, 18 Apr 1999 04:00:00



Quote:> Hi,

> Can I get away with this in (Red Hat 5.2) Linux?  And am I making any
> errors in my mask, etc.?

>      Linux Server

>      Two Kingston KNE100TX ethernet card:

>          Subnet mask: 255.255.255.240   (FF.FF.FF.F0)  for server and
> all clients

>               eth0 address: 192.168.255.1
>                    Client addresses: 192.168.255.2..127
>                    Client default route: 192.168.255.1

>               eth1 address: 192.168.255.129
>                    Client addresses 192.168.255.130..254
>                    Client default route: 192.168.255.129

> Am I correct that only traffic with an address on the other subnet gets
> routed?

Close, but your subnet is wrong. You need to use 255.255.255.128. This
will give you two subnets:
range     192.168.255.1 - 192.168.255.126
broadcast 192.168.255.127
network   192.168.255.0

range     192.168.255.129 - 192.168.244.254
broadcast 192.168.255.255
network   192.168.255.128

so make
eth0 192.168.255.1
eth1 192.165.255.129

and the default routes
lan1 192.168.255.1
lan2 192.168.255.129

Hope this helps,

Luca
--


 
 
 

Subnet question

Post by mist » Mon, 19 Apr 1999 04:00:00



Quote:>> Am I correct that only traffic with an address on the other subnet gets
>> routed?

Trafic on one subnet will not pass to the other unless you have
masquerading active on the Linux box.

I would not use .255, as this is a special address, use something like
192.168.1.* and 192.168.0.* for the two different subnets. Then you can do
something like

ifconfig eth0 192.168.0.1 netmask 255.255.255.0 broadcast 192.168.0.255 up
ifconfig eth0 192.168.1.1 netmask 255.255.255.0 broadcast 192.168.1.255 up

route add -net 192.168.0.0 eth0
route add -net 192.168.1.0 eth1

Or whatever.
--
Mist.

 
 
 

Subnet question

Post by Luca Filipoz » Mon, 19 Apr 1999 04:00:00




> X-Newsreader: Turnpike (32) Version 4.01  <fTyN96W1tu9l6sxEnpGztlbjJE>


> >> Am I correct that only traffic with an address on the other subnet gets
> >> routed?

> Trafic on one subnet will not pass to the other unless you have
> masquerading active on the Linux box.

> I would not use .255, as this is a special address, use something like
> 192.168.1.* and 192.168.0.* for the two different subnets. Then you can do
> something like

> ifconfig eth0 192.168.0.1 netmask 255.255.255.0 broadcast 192.168.0.255 up
> ifconfig eth0 192.168.1.1 netmask 255.255.255.0 broadcast 192.168.1.255 up

> route add -net 192.168.0.0 eth0
> route add -net 192.168.1.0 eth1

> Or whatever.

192.168.255.0/255.255.255.0 is a valid class C subnet.
--

 
 
 

1. interesting subnet question

If you have two machines with the following setings,

[ Machine 1 ] IP: 192.168.0.1, Subnet: 255.255.255.0
[ Machine 2 ] IP: 192.168.0.2, Subnet: 255.255.255.252

will the M1 be able to ping M2? What about the other way round? The subnet
of M2 allows it to talk to IP addresses 192.168.0.1-192.168.0.3, right?

What do the RFCs say about this?

cheers,

C3

2. MAKEDEV

3. Subnet Questions from the IP Sub-Networking Mini-Howto

4. setfsuid

5. Subnet Question

6. SCSI card driver question

7. subnet question

8. How to make rup flush its stdout?

9. Subnet question to see if I understand

10. Routing difficulty with USWEST and Redhat 5.2 (Local Subnet Question)

11. Routing/Subnet question.

12. subnet question

13. Basic DMZ routing/subnet question