[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Gateway with one NIC / dhcp problems
I've done something similar to this with TWO NICs -- where the
infrastructure was already in place and rewiring was going to take
some serious time and the line was a 56kbps line.
In this case, I had:
ISP's router -> Hub -> OpenBSD -> Same Hub -> internal network.
(10.10.10.x) (10.10.11.x)
The ISP's router was doing NAT, but 1:1 NAT, so there was NO barrier
between the workstations and the network.
It worked, and it provided decent (though imperfect) protection.
I probably could have done it with one NIC, but other than one port
savings on the hub, I didn't see any benefit, and besides, the hope
was (and came true) that the machine would be moved to a "proper"
location and "proper" hookup eventually.
I would NOT do this with a cable hookup, however. This was a 56kbps
line, collisions were not an issue. Cable modem connections can be so
fast, they can almost saturate the ethernet cable at times...you will
have _serious_ performance problems.
If I'm understanding part of your problem, you are seeing your ONE
physical NIC show up twice -- ep0 and ep1. Shut off the PNP "feature"
of the NIC, this should go away and solve your problem.
Buy another NIC. You need it. It is far cheaper than one month of
cable internet. 8)
BTW: Don't snip your diagnostic messages. We (often) need everything
so we can see the entire situation, not just the pieces.
Nick.
Kelvin wrote:
>
> Hi,However there is a 3COM network card in the box. Since most of the time,
> a gateway has two NIC
> cards. one connected to the internet and the other to LAN, I'm wondering
> if it'l be possible to setup this box as my gateway.
> I've got a hub. So I'm thinking:
>
> cablemodem -> hub -> obsd box (with only ONE nic) -> same hub -> LAN
>
> obviously, ive only got one IP. and pls do not advise me to get a router -
> too expensive :<
>
> >From the Obsd FAQ:
> IP Network Address Translation will work on machines with only one NIC,
> however since packets will be going in and out of the same interface,
> ethernet collisions will slow down performance considerably.
>
> 2)
> another problem cropped up. ISP uses dhcp.
> And I have a 3com NIC on the box
> snip dmesg output:
> ep0 at isa0 port 0x300/16 irq 10: address 00:a0:24:45:57:ed, utp (default
> utp)
> ...
> ep1 at isapnp0 "3Com 3C509B EtherLink III, TCM5095, PNP80F7, " port 0x210/16
> irq 5: address 00:a0:24:45:57:ed, utp (default utp)
>
> ep0 and ep1 were also detected during install.
> however during network installation. only ep1 managed to receive dhcp
> configuration from isp.
> ep0 only spewed out some nonsense which i cant rememeber
>
> anyhow, i boot up. and following the FAQ, i did echo dhcp > hostname.ep1
> restarted. but dhcp still gave alot of errors. i.e still no internet
> so i tried echo dhcp > hostname.ep0 .. also failed.
> since during installation i managed to get a valid ip and connect to ftp to
> download the installation files. surely, it cant be a network problem?
>
> until i get the second NIC, i'l not setup NAT. so my sole purpose now is to
> get the box up and running on the internet.
>
> Heres a snip of ifconfig -a output:
>
> inet6 fe80::1%lo0 prefixlen 64 scopeid 0x4
> inet6 ::1 prefixlen 128
> inet 127.0.0.1 netmask 0xff000000
> lo1: flags=8008<LOOPBACK,MULTICAST> mtu 32972
> ep0: flags=8863<UP,BROADCAST,NOTRAILERS,RUNNING,SIMPLEX,MULTICAST> mtu 1500
> media: Ethernet 10baseT
> inet6 fe80::2a0:24ff:fe45:57ed%ep0 prefixlen 64 scopeid 0x1
> inet 0.0.0.0 netmask 0xff000000 broadcast 255.255.255.255
> ep1: flags=8863<UP,BROADCAST,NOTRAILERS,RUNNING,SIMPLEX,MULTICAST> mtu 1500
> media: Ethernet 10baseT
> inet6 fe80::2a0:24ff:fe45:57ed%ep1 prefixlen 64 scopeid 0x2
> inet 0.0.0.0 netmask 0xff000000 broadcast 255.255.255.255
>
> Advice/Suggestions?
> Thanx in advance
>
> -kay
>
--
http://www.holland-consulting.net/