> The man page says:
>        When the demand option is used, the interface IP addresses
>        have already been set at the point when IPCP comes up.  If
>        pppd has not been able to  negotiate  the  same  addresses
>        that  it used to configure the interface (for example when
>        the peer is an ISP that uses dynamic  IP  address  assign-
>        ment),  pppd  has  to change the interface IP addresses to
>        the negotiated addresses.  This may disrupt existing  con-
>        nections,  and  the use of demand dialling with peers that
>        do dynamic IP address assignment is not recommended.
>
> What is meant by `This may disrupt existing connections'? If a TCP
> connection assumes an IP, changing the interface will most
> certainly break the connection????

As I understand it (or not as the case may be) pppd by default was designed
up to maintain a single set of addresses.  The problem comes when you've
already got traffic on your system pointing to the existing addresses.
[that first packet that triggered the demand dial for example]  It's
pointing to an address that doesn't exist anymore and therefore is broken
(without kernel address change support - see below).  New packets arriving
after the address change work as expected.

Telling pppd to accept address changes does work for me.  Using versions
2.3.3 and above I've never seen a problem.  But it makes sense that the
warning is still in place.

> Is there any way around this so that I can effectively use
> dynamic IP with demand dialing?

add these lines to /etc/ppp/options (or where ever you are specifying your
pppd options)
  # override existing address with those negotiated by IPCP
  ipcp-accept-remote
  ipcp-accept-local
[ they are explained in man pppd ]

and these lines to one of your init scripts
  # enable kernel support for dynamic address changes
  echo "1" > /proc/sys/net/ipv4/ip_dynaddr
[ explained in linux/Documentation/networking/ip_dynaddr.txt if you have the
kernel sources installed. ]

> What code would need to be written to get this to work? I
> would like to write support for this - what is needed?

It generally works as is.

Hope this helps,

Lourdes


-
To unsubscribe from this list: send the line "unsubscribe linux-ppp" in
the body of a message to [EMAIL PROTECTED]

Reply via email to