Chris Nelson
2006-04-21 18:31:44 UTC
I'm trying to get PPP working between two Linux systems. I got a
direct, serial, null-modem connection working without too much trouble
but a modem connection is making me crazy.
My server -- the one that'll answer the phone -- is running pppd 2.4.2
and mgetty: interim release 1.1.33-Apr10. The client is running pppd
2.4.2b3.
On the server, I have an inittab entry like:
D1:234:respawn:/usr/sbin/mgetty ttyAM1
And mgetty.config includes
port ttyAM1
init-chat "" ATZ OK AT OK
answer-chat "" ATA CONNECT \c \r
login.config includes
/AutoPPP/ - a_ppp /etc/ppp/ppplogin
and ppplogin looks like:
#!/bin/sh
stty -echo
/usr/sbin/pppd
(Though I've tried it with the more conventional:
#!/bin/sh
stty -echo
/usr/sbin/pppd silent auth -chap +pap login
and it didn't make any difference.)
On the client side, I've got /etc/ppp/ppp.cli0 which says:
/usr/sbin/pppd file /etc/ppp/options.cli0
/etc/ppp/options.cli0 says:
connect '/usr/sbin/chat -v -t 60 -f /etc/ppp/chat.cli0'
noipdefault
/dev/ttyS0
38400
name PPPClient
defaultroute
/etc/options says:
lock
crtscts
asyncmap 0
modem
and chat.cli0 says:
ABORT BUSY
ABORT "NO CARRIER"
"" "at&f s0=0 &c1 &d2 s38=255 dt101"
CONNECT ""
When I log into the client and invoke `/etc/ppp/ppp.cli0', the modem is
dialed, the remote answers, and /var/log/messages on the server shows
LCP sends and receives:
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.debug pppd[579]: using channel 18
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.info pppd[579]: Using interface
ppp0
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.info pppd[579]: Connect: ppp0 ->
/dev/ttyAM1
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.warn pppd[579]: Warning - secret
file /etc/ppp/pap-secrets has world and/or group access
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.warn pppd[579]: sent [LCP ConfReq
id=0x1 syncmap 0x0> uth pap> agic 0x616185a7> comp> ccomp>]
Jan 1 22:05:23 ET-5MS-MDM-1 daemon.warn pppd[579]: rcvd [LCP ConfReq
id=0x1 syncmap 0x0> agic 0xd6a4137> comp> ccomp>]
Jan 1 22:05:23 ET-5MS-MDM-1 daemon.warn pppd[579]: sent [LCP ConfAck
id=0x1 syncmap 0x0> agic 0xd6a4137> comp> ccomp>]
Jan 1 22:05:24 ET-5MS-MDM-1 daemon.warn pppd[579]: sent [LCP ConfReq
id=0x1 syncmap 0x0> uth pap> agic 0x616185a7> comp> ccomp>]
Jan 1 22:05:26 ET-5MS-MDM-1 daemon.warn pppd[579]: rcvd [LCP ConfReq
id=0x1 syncmap 0x0> agic 0xd6a4137> comp> ccomp>]
Jan 1 22:05:26 ET-5MS-MDM-1 daemon.warn pppd[579]: sent [LCP ConfAck
id=0x1 syncmap 0x0> agic 0xd6a4137> comp> ccomp>]
...
but the ppp connection never comes up. I finally get:
Jan 1 22:05:51 ET-5MS-MDM-1 daemon.warn pppd[579]: LCP: timeout
sending Config-Requests
Jan 1 22:05:51 ET-5MS-MDM-1 daemon.notice pppd[579]: Connection
terminated.
Jan 1 22:05:51 ET-5MS-MDM-1 daemon.info pppd[579]: Exit.
So, if the modem connection is there and the pppd's are sending LCP at
each other, why doesn't the negotiation succeed?
direct, serial, null-modem connection working without too much trouble
but a modem connection is making me crazy.
My server -- the one that'll answer the phone -- is running pppd 2.4.2
and mgetty: interim release 1.1.33-Apr10. The client is running pppd
2.4.2b3.
On the server, I have an inittab entry like:
D1:234:respawn:/usr/sbin/mgetty ttyAM1
And mgetty.config includes
port ttyAM1
init-chat "" ATZ OK AT OK
answer-chat "" ATA CONNECT \c \r
login.config includes
/AutoPPP/ - a_ppp /etc/ppp/ppplogin
and ppplogin looks like:
#!/bin/sh
stty -echo
/usr/sbin/pppd
(Though I've tried it with the more conventional:
#!/bin/sh
stty -echo
/usr/sbin/pppd silent auth -chap +pap login
and it didn't make any difference.)
On the client side, I've got /etc/ppp/ppp.cli0 which says:
/usr/sbin/pppd file /etc/ppp/options.cli0
/etc/ppp/options.cli0 says:
connect '/usr/sbin/chat -v -t 60 -f /etc/ppp/chat.cli0'
noipdefault
/dev/ttyS0
38400
name PPPClient
defaultroute
/etc/options says:
lock
crtscts
asyncmap 0
modem
and chat.cli0 says:
ABORT BUSY
ABORT "NO CARRIER"
"" "at&f s0=0 &c1 &d2 s38=255 dt101"
CONNECT ""
When I log into the client and invoke `/etc/ppp/ppp.cli0', the modem is
dialed, the remote answers, and /var/log/messages on the server shows
LCP sends and receives:
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.debug pppd[579]: using channel 18
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.info pppd[579]: Using interface
ppp0
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.info pppd[579]: Connect: ppp0 ->
/dev/ttyAM1
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.warn pppd[579]: Warning - secret
file /etc/ppp/pap-secrets has world and/or group access
Jan 1 22:05:21 ET-5MS-MDM-1 daemon.warn pppd[579]: sent [LCP ConfReq
id=0x1 syncmap 0x0> uth pap> agic 0x616185a7> comp> ccomp>]
Jan 1 22:05:23 ET-5MS-MDM-1 daemon.warn pppd[579]: rcvd [LCP ConfReq
id=0x1 syncmap 0x0> agic 0xd6a4137> comp> ccomp>]
Jan 1 22:05:23 ET-5MS-MDM-1 daemon.warn pppd[579]: sent [LCP ConfAck
id=0x1 syncmap 0x0> agic 0xd6a4137> comp> ccomp>]
Jan 1 22:05:24 ET-5MS-MDM-1 daemon.warn pppd[579]: sent [LCP ConfReq
id=0x1 syncmap 0x0> uth pap> agic 0x616185a7> comp> ccomp>]
Jan 1 22:05:26 ET-5MS-MDM-1 daemon.warn pppd[579]: rcvd [LCP ConfReq
id=0x1 syncmap 0x0> agic 0xd6a4137> comp> ccomp>]
Jan 1 22:05:26 ET-5MS-MDM-1 daemon.warn pppd[579]: sent [LCP ConfAck
id=0x1 syncmap 0x0> agic 0xd6a4137> comp> ccomp>]
...
but the ppp connection never comes up. I finally get:
Jan 1 22:05:51 ET-5MS-MDM-1 daemon.warn pppd[579]: LCP: timeout
sending Config-Requests
Jan 1 22:05:51 ET-5MS-MDM-1 daemon.notice pppd[579]: Connection
terminated.
Jan 1 22:05:51 ET-5MS-MDM-1 daemon.info pppd[579]: Exit.
So, if the modem connection is there and the pppd's are sending LCP at
each other, why doesn't the negotiation succeed?