What do I need to set up a network with multiple IP addresses?
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
What do I need to set up a network with multiple IP addresses?
Hey,
I hope someone can help me or point me in the right direction as to setting up a network.
I have set up my own company that offers web site design and hosting for the web sites.
My current setup is as such: a cable internet connection (with modem) which is connected to a linksys wrt54g router. The router has 2 home computers, a server computer, and a laptop (wireless) connected to it. The home/laptop computers are running windows while the server computer is running RHEL4. I am using one of the home computers to do the web site design on (using dreamweaver) and have the server computer set up to host the sites.
The server computer is set up to allow ftp (well, vsftp) from my home computer that I do the design on. My server computer is set up and running my web site and is ready for other sites to be hosted on it.
With my Internet connection, my plan from my ISP has given me 2 static IP addresses to use. I can get more static IP's from them if required (for a fee, of course). But right now, I have only been able to figure out how to set up my router to use one of my IP's.
Because of my business, I want to be able to offer my clients the ability to do e-commerce, which would include the ability to accept credit card transactions through their website. From what I understand, for each website that requires credit card transactions, they would need to have access to 2 IP addresses; one to access the web site and another just for the credit card transaction. So, this could mean that I would have multiple IP addresses in the future as need be.
So, my question is this: What hardware do I need between my cable modem and my various computers to support having multiple IP addresses? Would a switch work? Or are there routers out there that allow you to set them up with multiple IP's and forward them to the server?
Or maybe another solution would be to set up another computer to act as a router? I have an old, spare computer at home that is doing nothing that I can set up and do nothing but route to the other computers. The only problem with this computer is that it has only one NIC in it, so if I went this route, I think I would need to get another NIC, right?
Please let me know if anyone can help me or point me in the right direction for info on setting this up.
So, my question is this: What hardware do I need between my cable modem and my various computers to support having multiple IP addresses?
Quote:
Originally Posted by kerinism1
Would a switch work?
Yes. Put it between the cable modem & the wrt54g. Then connect the box associated w/ the 2nd IP to another port on the switch, preferably through another router or firewall. I have a hub between my DSL modem & my LAN. Whenever I want to use one of my other 2 IP's, I connect to it. Just remember, by the act of 'Net connection sharing, the wrt54g is providing substantial firewall protection.
Quote:
Originally Posted by kerinism1
Or are there routers out there that allow you to set them up with multiple IP's and forward them to the server?
Although I couldn't name one, I'm sure there are. The Q is, how much do they cost?
Quote:
Originally Posted by kerinism1
Or maybe another solution would be to set up another computer to act as a router?
That could work.
Quote:
Originally Posted by kerinism1
I have an old, spare computer at home that is doing nothing that I can set up and do nothing but route to the other computers. The only problem with this computer is that it has only one NIC in it, so if I went this route, I think I would need to get another NIC, right?
At least 1 add'l, maybe 2 or 3 -- depends on how many sub-nets you think you need. The routing table/commands for this solution could get complicated.
My current setup is as such: a cable internet connection (with modem) which is connected to a linksys wrt54g router. The router has 2 home computers, a server computer, and a laptop (wireless) connected to it. The home/laptop computers are running windows while the server computer is running RHEL4. I am using one of the home computers to do the web site design on (using dreamweaver) and have the server computer set up to host the sites.
As you said your ISP gave you 2 IP's .One out of them you allocated to your dsl modem/router (dsl modem/router Model ? )..now your dsl modem/router is than connected to linksys ( what is the IP's your are using for configure lnksys ?.ie. lan side IP)...and from linksys your both the machines are connected is it like that ?
Now
what is the IP you got at Linksys wan port ?
what are the IPs of you machines connected to linksys ?
Is your website accessible from outside ?(afaik you need port forwarding in dsl and linksys)
Yes, my connection goes like this: internet --> cable modem --> router -->2 home computers, laptop and server computer.
The router has been set up with one static IP. The computers have all been provided their own internal IP from the router. Any program that needs to listen on a specific port, I have listening on the internal IP along with the appropriate port. The router is also set up to port forward and the website is accessible from outside.
Yes, my connection goes like this: internet --> cable modem --> router -->2 home computers, laptop and server computer.
The router has been set up with one static IP. The computers have all been provided their own internal IP from the router. Any program that needs to listen on a specific port, I have listening on the internal IP along with the appropriate port. The router is also set up to port forward.
I'm no expert on this, and it may be different with cable than DSL, but I have a block of 8 ip addresses. xxx.xxx.233.136/29. I set the wan ip of the router to 142, the internal IP of the router to 141. I then set the routers routing table to say that xxx.xxx.233.136/29 was accessible via its ethernet interface.
Each computer I wanted to have visible externally I just set the address to xxx.xxx.233.13{7,8,..}, set the netmask to 255.255.255.248, and the gateway to xxx.xxx.233.141, and it all just worked.
That was just with a plain cheap bog standard router.
Hey,
Or are there routers out there that allow you to set them up with multiple IP's and forward them to the server?
Why yes there is. Check out the LInksys RV042 or RV082. You could also, get another internet connection, such as a dsl line so your network can stay redundant. Which is good for website hosting / ecommerce transactions.
I looked at those 2 routers you mentioned and am not sure they will not work, either. I only have the one connection from my ISP and they are providing me the 2 static IP's through the one connection. Maybe I am missing something here and am getting confused.
My ISP has given me the IP's 1.2.3.4 and 1.2.3.5 with all the other necessary setup info. Right now, when I go to configure my router, I can only enter 1.2.3.4 into the Static IP section.
I hope this makes sense. If not, I am also going to look at the possibility of an NIC with multiple ports so that I can set up my old computer as a router
Oh yea, I get what your saying. I was just saying if you got a second modem, you could easily use the two IP's with a dual port router.
Sorry, i must have not made that clear. As for taking your little linksys router there, I don't think you will find a way to bind it to two IP's, but you might try flashing it with a linux firmware. I can see that possibly helping you. Look up DD-WRT or openwrt.
Don't try 2 modems on the same same connection, it:
probably won't work
may confuse the the equipment @ your ISP
(outside possibility) might piss off your ISP
The easiest way, not necessarily the cheapest, is to get a switch & another router. Connect the switch (uplink/WAN port) to the modem & the 2 routers to (regular/LAN ports on) the switch. You have static IP addresses, so configure the new router w/ the 2nd IP -- "1.2.3.5" in your example.
If you trust its firewalling ability, you can omit the 2nd router & connect a single computer to the switch. You still have to set it up w/ a static IP, again "1.2.3.5".
Yes, you can probably find a, probably commercial, router that will handle 2 external IP's "out of the box". I suspect that this will cost more in money, search time, & learning curve than the switch/2nd router solution.
Yes, you can flash the WRT55G, but how hard will it be to set up afterwards. No money cost, but there is still the learning curve. Also, I believe the "standard" WRT55G has been cheapened from the original ver. by including less RAM & flash memory. Will the one you own hold & run the Linux you need to make this work?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.