Networking Forums

Networking Forums > Computer Networking > Linux Networking > Exchange Source IP in incoming IP Packages

Reply
Thread Tools Display Modes

Exchange Source IP in incoming IP Packages

 
 
Nils Gorges
Guest
Posts: n/a

 
      08-01-2004, 10:28 AM
Hello,

i have a problem with Linux, DNS and a NAT-Router.


The Linux machins has a private ip, the NAT-router is configured as the
DNS server. The NAT router itself uses DDNS and forwards all enquries to
the providers DNS server.

The problem is, the NAT router will not translate the ip addresses in
the answer packages of the providers DNS server. So for the Linux
machine it looks like the DNS answer is coming from another machine as
the enquiry was sent to. The enquiry was sent to the NAT router, the
answer is coming from the providers DNS. Because of that DNS doesn't work.

Is there a way to exchange the source IP address of the DNS answering
packagages to the nat-routers IP, maybe by iptables?

Thanks for any help

Nils

 
Reply With Quote
 
 
 
 
Alex Harsch
Guest
Posts: n/a

 
      08-01-2004, 10:51 AM
Nils Gorges wrote:

> Hello,
>
> i have a problem with Linux, DNS and a NAT-Router.
>
>
> The Linux machins has a private ip, the NAT-router is configured as the
> DNS server. The NAT router itself uses DDNS and forwards all enquries to
> the providers DNS server.
>
> The problem is, the NAT router will not translate the ip addresses in
> the answer packages of the providers DNS server. So for the Linux
> machine it looks like the DNS answer is coming from another machine as
> the enquiry was sent to. The enquiry was sent to the NAT router, the
> answer is coming from the providers DNS. Because of that DNS doesn't work.
>
> Is there a way to exchange the source IP address of the DNS answering
> packagages to the nat-routers IP, maybe by iptables?
>
> Thanks for any help
>
> Nils

Hi Nils,

iptables -t nat -A POSTROUTING -i Ext_Interface -s DNS-Server-IP -j SNAT
--to-source Router-IP
on the router should be fine.

Regards, Alex
 
Reply With Quote
 
Nils Gorges
Guest
Posts: n/a

 
      08-01-2004, 10:56 AM


Alex Harsch wrote:
> Nils Gorges wrote:
>
>
>>Hello,
>>
>>i have a problem with Linux, DNS and a NAT-Router.
>>
>>
>>The Linux machins has a private ip, the NAT-router is configured as the
>>DNS server. The NAT router itself uses DDNS and forwards all enquries to
>>the providers DNS server.
>>
>>The problem is, the NAT router will not translate the ip addresses in
>>the answer packages of the providers DNS server. So for the Linux
>>machine it looks like the DNS answer is coming from another machine as
>>the enquiry was sent to. The enquiry was sent to the NAT router, the
>>answer is coming from the providers DNS. Because of that DNS doesn't work.
>>
>>Is there a way to exchange the source IP address of the DNS answering
>>packagages to the nat-routers IP, maybe by iptables?
>>
>>Thanks for any help
>>
>>Nils

>
> Hi Nils,
>
> iptables -t nat -A POSTROUTING -i Ext_Interface -s DNS-Server-IP -j SNAT
> --to-source Router-IP
> on the router should be fine.
>
> Regards, Alex


Hi Alex,

thank you very much for the fast reply.

The next problem is, the providers DNS is assigned by Dynamic DNS, so i
don't know the DNS IP for sure. So i need to translate the ip addresses
of all package that are comping from port 53 to the nat-routers ip
address. Is that also possible?

Thank you again

Nils

 
Reply With Quote
 
Moe Trin
Guest
Posts: n/a

 
      08-01-2004, 09:04 PM
In article <ceii9b$f2v$06$(E-Mail Removed)>, Nils Gorges wrote:
>The next problem is, the providers DNS is assigned by Dynamic DNS, so i
>don't know the DNS IP for sure.


You may want to look at the IP addresses of these servers. DNS servers
_can_ change their addresses, but it's a good bit of a hassle - notifying
the domain registrar, then allowing for propagation delays for the change
to take effect all over the world.

Remember that the normal reason for using a (so-called) Dynamic DNS
is so that the individual hosts don't have to be individually set up.
I mean _everyone_ knows how hard it is the fire up a text editor when
you are originally configuring the system, and _actually edit_ one
stupid file. Ohh, that is SO HARD TO DO!!! ;-)

Actually, it does have a place it the world, if the host is moving
from one network to another on a regular basis.

Old guy
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
RRAS: dial on demand doesn't hang up (only incoming packages) Axel Windows Networking 0 01-16-2007 09:54 AM
Wireless Packages googlenospam@hotmail.co.uk Broadband 0 10-13-2006 12:49 PM
Fragmented IP packages Johann Höchtl Linux Networking 1 07-17-2006 07:55 AM
Open source MS Exchange-equivalent for Linux/Evolution... Cyphos Linux Networking 1 11-23-2005 09:03 AM
AOL packages Rupert Broadband 2 03-01-2005 08:48 PM



1 2 3 4 5 6 7 8 9 10 11