PDA

View Full Version : Network configuration question



griegsend
06-04-2002, 05:51 PM
This is my network setup (normally):

Cable modem => EQ PC Nic1
EQ PC Nic2 => Hub => Laptop running Linux (SEQ box)

Now pre-SEQ this worked fine. ICS is installed on the EQ PC (it runs WinXP Pro) and the laptop can be used to surf the Web, play my second EQ account or whatever. I configured the Linux setup on the laptop as a DHCP client so I can use the Internet in Linux.

Now SEQ comes into the picture. The current setup will not work because the EQ PC would need to broadcast any packet it receives onto the second subnet so the laptop can see it. I was prepared to replug the network as needed to:

Cable modem => Hub
Hub => EQ PC Nic1
Hub => SEQ PC

The cable internet service I use only allows the cable modem to recognise a single MAC address at a time and Windows can't (seem to) use one interface for the local subnet and the cable modem connection so this woud, annoyingly, disallow Internet use on the laptop while in this configuration but it would allow that PC to see packets that pass through the hub.

(Note: there is a way out of this: I can configure a second network connection between the laptop and the EQ PC over a USB cable and this will still allow Internet access but thats a side issue).

The problem? Months ago when I bought the hub I'd inadvertently bought a switching hub. Its not something I'd thought about at the time and even if I had I probably would've bought it anyway (SEQ wasn't in my mind then) so I'm kind astuck with it now.

The problem is that this leaves one choice: making the laptop the interface to the cable modem. I really don't want to do this though. The laptop isn't always there for a start. Also if I want to play EQ I need Windows on it but if I want to run SEQ I need to run Linux on it. Obviously this means a reboot which will kill my connection from my desktop EQ PC--annoying and not always practical.

So, I'm looking for a solution here that hopefully doesn't involve buying a new (non-switching) hub.

The ideal solution would be if I could get Windows to rebroadcast any packets it receives onto the subnet so SEQ can see them. I'm not at all confident that this is possible however.

Other than that, do I have any other options?

high_jeeves
06-04-2002, 06:29 PM
You need to buy a router, or try to run UDPEcho..

Search for information on either...

--Jeeves

rencro
06-04-2002, 06:37 PM
Or to practice your linux try 2 Nics in your Linux box and Masquerading your IP's

read more info here (http://seq.sourceforge.net/showthread.php?s=&threadid=566&highlight=masq) also be sure to read the the howto's here. (http://www.genuinemedia.com/linux/linux_howto.htm)

Good luck

griegsend
06-05-2002, 03:37 AM
The two NICs on the Linux laptop isn't really cost-effective because I'd need to buy a PCMCIA 10/100 card and it'd be cheaper to buy a new hub.

I'll check out UDPEcho. Thanks.

griegsend
06-05-2002, 07:29 AM
I've been looking at these router products you can get. Relatively inexpensive, they do NAT translation, act as DHCP servers, some have firewalls, they have a port on one side for the cable modem and 1-8+ ports on the other side for your local subnet. Only one problem: every one I've found so far has the ports switched. Argh. I've found 8 port 10Mbit hubs but, as yet, no 10/100 non-switched hubs. I really want to avoid having a Linux gateway as I've got better uses for a 3rd PC than that.

S_B_R
06-05-2002, 08:07 AM
Technically you don't need 2 NICs to do NAT on Linux. You net to make an alias for the one NIC you do have. and you need a hub. It's slightly more complicated than the usual NAT/IPTables setup but it can be done... The Network would look something like this.

CableModem
|
----Hub-----
| |
/ \ |
/ \ |
/ \ |
/ \ |
RealNIC AliasNIC |
| | |
Linux Box EQ PC
The "RealNIC" Would have your Internet IP address and the "AliasNIC" would have your internal IP address....

The other way I can think of would be Much simpler. The Linux Box doesn't have to have a routable IP address just to sniff packets. so if you had a TRUE hub you could set it up like this
CableModem
|
---------Hub--------
| |
Linux Box EQ PC
In this case your linux box would be given some bogus IP like 0.0.0.0 or something. The only thing here that is sort of a draw back is you wouldn't be able to surf the net from your Linux box. And if you are using PPPoE software from your ISP this wouldn't work either.

griegsend
06-05-2002, 11:16 AM
That Linux configuration, in theory, works but it has the problem I'm very keen to avoid: Linux as my gateway. I don't want that because I play EQ on that box as well and rebooting from Windows to Linux (or vice versa) will kill the connection of my other computer. I want a setup where my main Windows (desktop) PC is the gateway (or I have a router).

Routers: I've yet to find an integrated router/hub that doesn't use switching. D-Link, Linksys, Netgear and some other brand I can't remember all have broadband router products. They all use switching. The best I've found yet is some Netgear 4/6/8 port hubs that appear to be non-switched.

UDPEcho. Well I didn't find this on the Web and initially I didn't find it on here because I was only searching this forum. A search of all boards here found it. I downloaded winpcap 2.3 and installed it. I run updecho and get... no NICs found. Another thread has a post dated May 19 that says WinXP isn't supported (/sigh) and its just a matter of luck (basically) if it works or not.

Has anyone got this to work under WinXP? This would be my ideal solution (no new hardware required and its in the configuration I want). I'm not interested in running ME or 98SE. I like WinXP. Does udpecho work if you can figure out what the interfaces are called? If so, are there any tips on finding those names? Another thread had a post by a guy using windump. This is not a program I seem to have (not found at the command prompt). Is it hidden away? A third-party program? Other?

fryfrog
06-05-2002, 11:48 AM
if you happen to have a crap machine laying around you could build yourself a router (instead of spending $100 on one). all you need really is a floppy drive, a 386+ w/ 8mb ram and www.freesco.info. if you happen to have something more beefy (like maybe a pentium 100 w/ 32mb of ram and a spare cdrom drive you can use to install) ipcop.org is rather nice.

you need two network cards (i use 2x 3c509b's because i just have TONS of them laying around). it gives you a linux gateway device (albiet, very minimal don't run anything else linux) for free (or hopefully very cheap). if you wire stuff right, you might even be able to use your current hub.

what i mean is that if your lan side nic is only 10mbit and your linux/windows is 100mbit, that combination on a linksys hub will actually turn it into a REAL hub for the 100mbit plane and the 10mbit plane (but not between the two). that is how i personally solved my sniffing problem without ever knowing it. my setup has been like that since i installed eq then later seq, it just worked. one day someone said that their linksys which was identicle to mine didn't work and i was like "BS, dumbass"... but i unplugged the 10mbit stuff and sure enough i couldn't sniff anymore...

anyway, i wander. if i were you, that is what i would do. if i were you i would go for the slightly beefier system (who considers a p100 beefy anyway?) and try ipcop. its easy, as a nice very useful web interface and is spiffy. go for the beta version to, its slightly better imho. :)

Cambik
06-05-2002, 11:59 AM
Hook your cable modem to one of those swithing routers and then put a nonswitched standard hub in the router and everything will work fine.

my network looks like this

CABLE->--ROUTER-->--HUB-->-- EQ BOX, LINUX BOX, ETC....


This requires the extra hub but it works without having to use the linux box as a gateway.



I hate typos.....hehe

S_B_R
06-05-2002, 02:09 PM
Originally posted by griegsend
That Linux configuration, in theory, works but it has the problem I'm very keen to avoid: Linux as my gateway. I don't want that because I play EQ on that box as well and rebooting from Windows to Linux (or vice versa) will kill the connection of my other computer. I want a setup where my main Windows (desktop) PC is the gateway (or I have a router).

My second option doesn't require you to use linux as your gateway. It also doesn't require a router. It just requires a standard Hub, and that you are NOT using PPPoE, thats it...

griegsend
06-05-2002, 03:25 PM
Yes your second option is basically the same as my second configuration (from my initial post). BTW the surfing the web problem I think could be solved by bridging a connection between the laptop and the desktop PC over USB (so theres essentially a triangle of connections between the hub, desktop and laptop except one side is USB not UTP).

I don't have a spare old PC lying around. Before I moved I had a 486 which made a very nice Linux box but thats long gone. I'd prefer to spend the money on a compact router which is more portable and takes up less space.

Yes the router and unswitched hub works but that involves purchasing two new items and ditching my current hub. Not preferred. I'm hopin gtheres a solution for WinXP and UDPEcho *crosses fingers*.

Ah 3c509bs. That brings back memories. Back 5-6 years ago when I worked for an ISP and we were building Linux boxes (then Redhat 3.0.3 Picasso? release) that was our network card of choice. We bought them by th ehundreds. Nice, study 10Mbit card.

So... UDPEcho under XP anyone? :)

S_B_R
06-05-2002, 03:55 PM
Originally posted by griegsend
So... UDPEcho under XP anyone? :)

Nope it doesn't work. Winpcap needs to be fixed and UDPEcho will need to be fixed to work with changes in Winpcap...

I'm guessing that fixing winpcap to work with WinXP is no minor change. Since WinXP TCP stack now uses raw sockets, which is totally different than WinNT or Win9X...

high_jeeves
06-05-2002, 04:27 PM
actually, winpcap does work in XP (i use it quite regularly)...

It seems that the naming of the adapters breaks UDPecho.. perhaps it should be rewritten to use indexing instead of the actual name? (just my suggestion to the author)

--Jeeves

griegsend
06-06-2002, 06:46 AM
Well its not my ideal solution but the Netbear 4 port hub is on its way...

Spewn
06-07-2002, 01:17 AM
*sigh* I've been trying to think of how I can get showeq to work on my network as well :/ I've got two computers, and a spare p120 sitting around(that I'd planned on running seq on). Cablemodem ->hub->two computers is the current setup. And yes, it's a hub, not a switch. The question I have is will the third machine(the linux p120) be able to read the packets intended for my machine(which has it's own external IP, not an internal private one, both the current machines have external IP's of their own), or do they both have to be on the same IP network. Don't really know that much about linux/seq in this respect.

S_B_R
06-07-2002, 08:00 AM
If that is a true hub then any packets passing through it can be seen by any/all machines connected to it.

Dedpoet
06-07-2002, 09:12 AM
If the p120 is on the hub with your eq box, it should work fine, as long as it's a true hub. Just give your seq machine a non-routable class c address like 192.168.1.x or something.

Be prepared for a lot of compile time on that 120 :)

Spewn
06-07-2002, 10:55 AM
yeah it's a true hub, a multiport repeater if you will :P Main reason why I asked is I learned from cisco about how two machines on different subnets can't "talk" to each other without a router or something in between them, and I wasn't sure if the linux box would be able to read the packets. If it can though, that's great, thanks :) (and yeah I know it'll take forever to compile on the p120, but it's sitting gathering dust now so it's not like IT will mind :P)

S_B_R
06-07-2002, 11:49 AM
Originally posted by Spewn
yeah it's a true hub, a multiport repeater if you will :P Main reason why I asked is I learned from cisco about how two machines on different subnets can't "talk" to each other without a router or something in between them, and I wasn't sure if the linux box would be able to read the packets.

This is true for the most part. But since SEQ puts your NIC into promiscuous mode (unless you tell it not to), it will see every packet that crosses the hub.

winseq
06-09-2002, 01:15 PM
It seems that the naming of the adapters breaks UDPecho.. perhaps it should be rewritten to use indexing instead of the actual name? (just my suggestion to the author)

I'm pretty sure v0.2 already does this. Although it's technically still name based, as the index used is generated from the name list it acquires.