Subject: Re: Demand dialing using pppd
To: Ian P. Thomas <ipthomas@mac.com>
From: Manuel Bouyer <bouyer@antioche.eu.org>
List: netbsd-users
Date: 03/16/2002 18:40:08
On Sat, Mar 16, 2002 at 12:00:59PM -0500, Ian P. Thomas wrote:
> 	I am attempting to set up demand dialing so my OS X box can connect 
> to the web without me having to ssh into the NetBSD gateway and bring up 
> the connection by hand.  Here is what my /etc/ppp/options file looks 
> like so far,
> 
> # /etc/ppp/options
> # Device used to communicate over. (Serial Port 1)
> /dev/tty00
> # Ensure exclusive access to /dev/tty00.
> lock
> # Use hardware flow control.
> crtscts
> # Set the maximum baud rate.
> 115200
> # Use modem control lines.
> modem
> # Add a default route to the system routing tables, using the peer as 
> the gateway.
> defaultroute
> # Peer supplys the IP address during IPCP negotiation.
> noipdefault
> # Read more options from the file /etc/ppp/peers/ubunix
> call ubunix
> # Require the peer to authenticate before allowing packets to be sent or 
> received.
> auth
> # Needed for demand dialing
> #demand
> #ipcp-accept-local
> #ipcp-accept-remote
> #:10.0.0.1
> 
> 	Right now the bottom four options are commented out because of the 
> following:
> 
> 1. I bring up Omniweb  in OS X and this causes the modem to be 
> initialized.
> 
> 2. The modem dials and handshakes.  Immediately after the handshake, the 
> modem hangs up.  I've gathered this much from the debug info in 
> /var/log/messages.
> 
> Mar 15 21:21:14 solo pppd[5501]: Starting link
> Mar 15 21:21:15 solo chat[5510]: report (CONNECT)
> Mar 15 21:21:15 solo chat[5510]: abort on (BUSY)
> Mar 15 21:21:15 solo chat[5510]: abort on (NO CARRIER)
> Mar 15 21:21:15 solo chat[5510]: abort on (NO DIALTONE)
> Mar 15 21:21:15 solo chat[5510]: send (ATZ^M)
> Mar 15 21:21:15 solo chat[5510]: expect (OK)
> Mar 15 21:21:17 solo chat[5510]: ATZ^M^M
> Mar 15 21:21:17 solo chat[5510]: OK
> Mar 15 21:21:17 solo chat[5510]:  -- got it
> Mar 15 21:21:17 solo chat[5510]: send (ATDT*70,,5155603^M)
> Mar 15 21:21:17 solo chat[5510]: expect (CONNECT)
> Mar 15 21:21:17 solo chat[5510]: ^M
> Mar 15 21:21:56 solo chat[5510]: ATDT*70,,5155603^M^M
> Mar 15 21:21:56 solo chat[5510]: CONNECT
> Mar 15 21:21:56 solo chat[5510]:  -- got it
> Mar 15 21:21:56 solo pppd[5501]: Serial connection established.
> Mar 15 21:21:56 solo pppd[5501]: Connect: ppp0 <--> /dev/tty00
> Mar 15 21:21:56 solo pppd[5501]: Modem hangup
> Mar 15 21:21:56 solo pppd[5501]: Connection terminated.
> 
> 	I have ipfilter and ipnat working flawlessly as far as I can tell.  
> I'm not sure what is making the modem hang up immediately after 
> connecting.  I can bring up a link manually without any problems.  Any 
> suggestions would be welcomed.

I suspect this is because pppd tries to negociate with the peer to use the
same IP as it currently has (10.0.0.1) and the peer doesn't like this.

-- 
Manuel Bouyer <bouyer@antioche.eu.org>
--