2 Computers, 1 Static IP?

Hey all-- I’ve been in Linux for about 36 hours now, and I think I’m in a little over my head. I have a LAN with three devices (Desktop, Laptop and Wii). The DSL modem is connected directly to the desktop via USB, and is connected to a wireless router via Ethernet, which serves the laptop and Wii. My goal is to make the Desktop (now running openSuse 11.1) serve as a web server. I now have 1 static IP from my ISP to facilitate this.

Can I configure my network so that the desktop can be accessed via the static IP, while the other devices can continue their dynamic IP careers unhindered?

From what I’ve found (the 10% that I understood…), it seems like I can do this with port forwarding or bridging. Not that I have the slightest clue how to do that… :sarcastic:

Thanks in advance for any help!

Unfortunately I don’t know how the USB connection looks from the viewpoint of IP addresses. However you can do it this way, if you connect your desktop with Ethernet. Bandwidth will be better too.

modem in bridging mode
wireless router
desktop, laptop and wii

Because the modem is in bridging mode, the external address of the router will be your external address. The router will NAT to an internal LAN subnet, probably something like 192.168.0.x. Give the desktop a static address in that subnet, something outside the dynamic range provided by the router. Then set up a portforward from port 80 external to the desktop port 80.

Exactly how this is done in the router’s web menus depends on the router, but the principle is the same.

Be careful with webserver security. Make sure any web apps you run can stand up to crack and defacement attempts.

Configuration options and step by step instructions could fill a thick pamphlet, more than is typically covered in a Forum post.

Here are a few concepts to get you stared…

Your ISP’s gateway device is generally setup by your ISP although sometimes it can be setup according to your wishes. There are 2 fundamental modes, “Bridging” which is what Ken describes which makes the device transparent so that the Public Static IP address is configured on your PC and if your ISP gateway device has only one ethernet output it’s probably configured that way.

Oftentimes if the device has multiple ethernet ports, although it can still be configured as a bridging device (all PCs would need their own unique Public addresses), it’s usually instead configured as a router (All PCs are assigned Private addresses and share the single Public address).

You’ll need to talk to your ISP, but I strongly suspect that your device is performing as a router for any device connected through the Ethernet ports and for all practical purposes as a Bridging device for any PC attached through the USB connection (I don’t want to get into the Ethernet over USB technology, only finesse the practical aspect that the PC isn’t issued an Ethernet IP address but is considered to connect to the Internet using the Gateway device’s IP address).

If you can verify this, then the bottom lines are these…

  • Your PC connected using USB can be “seen” from the Internet, but probably requires Firewall rules permitting inbound traffic
  • Other machines require Port Forwarding (not simply Packet Filter) rules because unlike your USB/PC using the Public IP address, they have Private addresses so your rules need to “translate” or “map” something uniquely identifiable arriving at your Public IP address to the Private address of the machine you want to be exposed to the Internet.

Even on a simple SOHO ISP device, configuring all this the first time you see it may be daunting, if you’re in a hurry you may want to find a friend or hire someone qualified to set this up for you.

Thanks both-- We have a workable solution!