[Wylug-discuss] Semi-OT - Extending the LAN

Jim Jackson jj at comp.leeds.ac.uk
Mon Aug 15 12:56:21 BST 2005


On Wed, 10 Aug 2005, Anne Wilson wrote:

> Another fine mess I've got myself into :-)  OK - the position at the moment
> is this:
>
> The lan uses ip range 192.168.0, whereas the new router defaults to
> 192.168.1.  I changed the IP of one of the Mandrake boxes because I'm more
> familiar with that than with the XP box, and accessed the setup pages.  I
> made all the changes I thought necessary, then set its IP to a 192.168.0
> setting.  Somewhere among those settings I did something stupid, because
> the wan light went crazy.  At that point I decided that a factory reset
> was in order so that I could start again.  Unfortunately I can no longer
> access the setup pages at all.  It doesn't respond either to the factory
> default 192.168.1.1 or the 192.168.0.2 that I gave it.
>
> I may have to sleep on this in the hope of enlightenment.
>

A quick tip for people, when they need to connect to a box whose default
address is on another network. Simply configure your main etherent port 
with a secondary IP address on the same network as the box.
In effect you put your ethernet interface in both networks and can now 
speak to everything. If you enabled ip forwarding, you can make a one 
interface router :-)

secondary addresses are specified by adding an ':' seperated field to the 
interface name. eth0 has secondary addresses eth0:1 , eth0:2 .... etc You 
can specify several addresses. If you do this dynamically with ifconfig 
(see below) then on a reboot all is back to normal. If you want these 
addresses to be permanent then you'd probably have to fiddle with the 
start up scripts.

Eg.

[root at cslin146 root]# ifconfig eth0
eth0      Link encap:Ethernet  HWaddr 00:11:11:37:8B:38
           inet addr:129.11.146.146  Bcast:129.11.147.255  Mask:255.255.252.0
           inet6 addr: fe80::211:11ff:fe37:8b38/64 Scope:Link
           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
           RX packets:151489874 errors:0 dropped:0 overruns:0 frame:0
           TX packets:55415487 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 txqueuelen:1000
           RX bytes:3341132838 (3186.3 Mb)  TX bytes:46789904 (44.6 Mb)
           Interrupt:16

[root at cslin146 root]# ifconfig eth0:1 192.168.10.1

[root at cslin146 root]# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:11:11:37:8B:38
           inet addr:129.11.146.146  Bcast:129.11.147.255  Mask:255.255.252.0
           inet6 addr: fe80::211:11ff:fe37:8b38/64 Scope:Link
           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
           RX packets:151490457 errors:0 dropped:0 overruns:0 frame:0
           TX packets:55415747 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 txqueuelen:1000
           RX bytes:3341234121 (3186.4 Mb)  TX bytes:46832819 (44.6 Mb)
           Interrupt:16

eth0:1    Link encap:Ethernet  HWaddr 00:11:11:37:8B:38
           inet addr:192.168.10.1  Bcast:192.168.10.255  Mask:255.255.255.0
           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
           RX packets:0 errors:0 dropped:0 overruns:0 frame:0
           TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
           collisions:0 txqueuelen:1000
           RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
           Interrupt:16






More information about the Wylug-discuss mailing list