Help with content of /etc/network/interfaces file
Jay Ridgley
jridgley2 at austin.rr.com
Mon Feb 22 02:04:48 UTC 2010
Nils Kassube wrote:
> Jay Ridgley wrote:
>> > When I enter an ifconfig it shows the three nics, however, eth2 does
>> > not have an IP address. If I remove the comment flag(#) from the
>> > iface line and the auto line my network fails to come up. Any
>> > examples I have found seem to avoid this type of arrangement (two
>> > nics doing DHCP one a client (for the internet) and one a server
>> > (for the Access Point).
>
> If I understand it correctly, you have eth0 connected to the internet
> and you get your configuration via DHCP from your provider. On your eth1
> you have a first LAN where your DHCP server should hand out
> configuration to other machines and on eth2 you have a second LAN via
> that AP where your DHCP server should also hand out configuration data
> to other machines.
Not quite, eth0 is the DHCP client to the provider and provides my connection to
the INTERNET.
eth1 is a second nic on the same machine and eth2 is a third nic. eth1 is a
WIRED subnet with STATIC addresses (4 machines here including this one).
eth2 is for a WIRELESS subnet that is WIRED to the WIRELESS Access Point.
>
> Now, if you uncomment the eth2 entries, there are two interfaces with
> DHCP entries (eth0 + eth2). These entries mean that the ports should act
> as DHCP clients. I suppose that's why your network fails to come up.
eth2 is for a DHCP SERVER not a CLIENT.
>
>> > interfaces:
>> >
>> > iface eth0 inet dhcp
>> >
>> > auto eth0
>> >
>> > iface eth1 inet static
>> > address 192.168.139.2
>> > netmask 255.255.255.240
>> > gateway 192.168.139.2
>> > broadcast 192.168.139.15
>
> Are you sure that the gateway should be the same as the interface
> itself? That doesn't look right to me. IMHO the gateway should be the
> address of the internet port, i.e. the address received for eth0.
192.168.139.2 is the address of the machine which has the eth1 nic, it is also
my gateway, hence the duplication. This part is OK, it has NOT changed.
The problem seems to revolve around the iface eth2 entries in the interfaces
file(contained in my original post).
>
>> > dhcpd.conf:
>
>> > #DHCP subnet a wireless Access Point for eth2
>> >
>> > subnet 192.168.139.32 netmask 255.255.255.240 {
>> > range 192.168.139.35 192.168.139.39;
>> > option routers 192.168.139.2;
>
> 192.168.139.2 is not in this subnet - I don't think this entry can work.
192.168.139.2 is the GATEWAY for my network. What other IP should be used here?
Should the option routers be option gateway instead???
Cheers,
Jay
--
Jay Ridgley
jridgley2 at austin.rr.com
Registered Linux User ID - 9115
Registered Ubuntu User ID - 23320
More information about the ubuntu-users
mailing list