LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 04-12-2010, 09:40 AM   #1
Yakideo
Member
 
Registered: Jan 2010
Posts: 39

Rep: Reputation: 16
Multiple ip addresses


My ISP can give me up to 5 ip addresses. Is it possible to "forward" one of them to a machine to get rid of nat? I was thinking of "forwarding" one public ip to my machine and let the rest of the network share one ip using nat.

Currently I use dnsmasq and debian.

Thanks.
 
Old 04-12-2010, 03:48 PM   #2
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,993

Rep: Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628Reputation: 3628
It would depend on the topology of your system. If you have a public IP on any lan computer it would be easy to allow it access to and router to the internet. Simply put the ip and gateway in and go. As for topology you may have to explain so that we get the correct gateway.
 
Old 04-13-2010, 06:20 AM   #3
nowonmai
Member
 
Registered: Jun 2003
Posts: 481

Rep: Reputation: 48
It depends on what your router is capable of.
TBH, I would doubt it, if it's a standard consumer router.
If you set up a linux box as your router, no problem... just create the iptables rules to forward all for a given destination to whatever box you require.
 
Old 04-13-2010, 06:55 AM   #4
cola
Senior Member
 
Registered: Sep 2007
Posts: 1,045

Rep: Reputation: 65
Quote:
Originally Posted by Yakideo View Post
My ISP can give me up to 5 ip addresses. Is it possible to "forward" one of them to a machine to get rid of nat? I was thinking of "forwarding" one public ip to my machine and let the rest of the network share one ip using nat.

Currently I use dnsmasq and debian.

Thanks.
You may have to set up your box as a router.
Setting iptables is also needed to forward ip packets.
 
Old 04-13-2010, 07:54 AM   #5
catkin
LQ 5k Club
 
Registered: Dec 2008
Location: Tamil Nadu, India
Distribution: Debian
Posts: 8,578
Blog Entries: 31

Rep: Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208Reputation: 1208
Quote:
Originally Posted by nowonmai View Post
It depends on what your router is capable of.
TBH, I would doubt it, if it's a standard consumer router.
Agreed but some SOHO routers do provide a DMZ facility ... would be god to know the OP's router's make, model and firmware.
 
Old 04-13-2010, 09:40 AM   #6
Yakideo
Member
 
Registered: Jan 2010
Posts: 39

Original Poster
Rep: Reputation: 16
First of all thanks for the answers.

My router is a x86 box running iptables and debian.

The thing is that the ip addresses I receive from my isp aren't static. Dunno if there is a way to let iptables get a ip address from a dhcp and then forward it.

Click image for larger version

Name:	Netcloud_r1.png
Views:	18
Size:	59.4 KB
ID:	3329

Last edited by Yakideo; 04-13-2010 at 10:01 AM.
 
Old 04-13-2010, 10:00 AM   #7
cola
Senior Member
 
Registered: Sep 2007
Posts: 1,045

Rep: Reputation: 65
Quote:
Originally Posted by Yakideo View Post
First of all thanks for the answers.

My router is a x86 box running iptables and debian.

The thing is that the ip addresses I receive from my isp aren't static. Dunno if there is a way to let iptables get a ip address from a dhcp and then forward it.
May be, ip masquerade.
 
Old 04-13-2010, 10:14 AM   #8
Yakideo
Member
 
Registered: Jan 2010
Posts: 39

Original Poster
Rep: Reputation: 16
Quote:
Originally Posted by cola View Post
May be, ip masquerade.
That would be NATing with I already have. I would like to forward another public ip to a single computer.

I guess the question is how can I get two ip addresses on one interface?
Also see the attached picture in the previous post. It's kind of hard to explain or maybe I'm just making it hard, dunno
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple IP addresses Wim Sturkenboom Slackware 5 09-27-2006 02:31 PM
Multiple IP Addresses mikemrh9 Linux - Networking 6 05-26-2005 05:15 AM
Multiple IP addresses james_cwy Linux - Newbie 6 06-13-2004 11:34 PM
Multiple 'public' ip addresses mcleodnine Linux - Networking 3 05-09-2003 02:04 AM
Multiple IP Addresses meshcurrent Linux - Networking 1 10-12-2002 05:11 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:14 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration