Re: Old TCP connections after IP address change

From: Grant Coady (grant_lkml_at_dodo.com.au)
Date: 06/10/05


Date: Sat, 11 Jun 2005 02:12:47 +1000

On Fri, 10 Jun 2005 08:54:15 -0500, Clifford Kite <kite@see.signature.id> wrote:
>
> > You guys still missing the point, properly configured linux running
> > modem in _bridge_ mode (PPPoE) will see the IP change and drop all
> > current TCP connections... If you being wimpy and plugging into
> > ADSL modem in 'windows' mode, you deserve what you get :o)
>
> How about expanding this so we can understand what you really mean.
> As the OP pointed out in his follow-up there is Bridged/DHCP and PPPoE
> ADSL, and you seem to lumped them together. Most ISPs are now using
> PPPoE because it's to their advantage to do so; it offers little,
> if any, benefit to the consumer. And I have no idea what "windows
> mode" means - but then I don't do Windows.

Windows mode: Plug PC into adsl modem and hope for the best
PPPoE: as an end-user, I have little control over ISP, they use it.
Your Bridged/DHCP seems a contradiction, if you running dhcp client
to connect to modem, you running 'windows mode', see?
If you switch the modem into bridge mode, and run PPPoE in linux
box you in full control of connection: 'non-windows mode'.

> Maybe you could point us toward what part(s) can be configured to
> help with this?

iptables: NAT: MASQUERADE vs SNAT, example:

#######################################
# NAT table
# ``````````
# Perform SNAT or MASQUERADE for localnet to world connections

# Difference between SNAT and MASQUERADE?
# SNAT is more efficient for static public IP address and established
# connections will survive a reconnect. MASQUERADE is for dynamic IP
# and established connections are dropped when ADSL goes down as a new
# and probably different IP address is expected on next connection.

function install_nat_table ()
{
        # exit if we running local mode -- no connection to world
        test "$FIREWALL_MODE" == "local" && return

        report " nat: "
        if test -n "$IP_WORLD"; then
                # Source Network Address Translation for static public IP
                iptables -t nat -A POSTROUTING -o $X_WORLD \
                                                -j SNAT --to-source $IP_WORLD
                FIREWALL_MODE="world-SNAT"
        else
                # Masquerade for dynamic public Internet Protocol address
                iptables -t nat -A POSTROUTING -o $X_WORLD -j MASQUERADE
                FIREWALL_MODE="world-MASQUERADE"
        fi
}

--Grant.



Relevant Pages

  • Re: about iptables
    ... Your firewall doesn't need to know about the DNS servers. ... # Difference between SNAT and MASQUERADE? ... # connections will survive a reconnect. ...
    (comp.os.linux.networking)
  • Re: Branch Office MVBASE network access
    ... Each factory has a 256k ADSL line into BT IP Clear and then back to head ... Each of the factories just has a Cisco 1700 and an 8 or 16 port hub! ... serving serial connections to some equally ... These routers connect over 56k WAN links to our MVBASE server. ...
    (comp.databases.pick)
  • Re: Booting PC disconnects ADSL Modem
    ... connections and that all wires are known properly constructed (a ... Now what happens to the ADSL ... The diagnostics have one even better feature - the last ... confirm the suspect computer's safety ground ...
    (microsoft.public.windowsxp.general)
  • Re: Winroute and multiple internet connections
    ... > I'm trying to set up and use two internet connections ... I use Winroute Pro to share a cable and ADSL connection with my LAN. ... When setting up 2 Internet connections, remember to force one of them to be ...
    (comp.security.firewalls)
  • Re: Would you expect this device to support ADSL directly?
    ... > Reading the description at the bottom, would you expect it to support ADSL ... A customer review which complains that it 'doesn't support ADSL' says "It only ... has RJ-45 for Ethernet connections so it's fine for NTL cable.". ... manufacturer web sites. ...
    (uk.comp.homebuilt)