klivlend
asked on
After connection establishing I get hangup. Help !
Hi,
Here is PPP-chat connection protocol. After connection
establishing I get terminating and hangup. What is the problem ?
Oct 20 09:29:48 klivlend chat[341]: ATDT5354007^M^M
Oct 20 09:29:48 klivlend chat[341]: CONNECT -- got it
Oct 20 09:29:48 klivlend chat[341]: send (^M)
Oct 20 09:29:48 klivlend pppd[340]: Serial connection established.
Oct 20 09:29:49 klivlend pppd[340]: Using interface ppp0
Oct 20 09:29:49 klivlend pppd[340]: Connect: ppp0 <--> /dev/ttyS1
Oct 20 09:29:49 klivlend pppd[340]: sent [LCP ConfReq id=0x1 <mru 1500>
<asyncmap 0x20a0000> <magic 0xea07984> <pcomp> <accomp>]
Oct 20 09:29:49 klivlend pppd[340]: rcvd [LCP ConfReq id=0x1 <mru 576>
<asyncmap 0x0> <auth pap> <magic 0x1c759fc6> <pcomp> <accomp>]
Oct 20 09:29:49 klivlend pppd[340]: sent [LCP ConfRej id=0x1 <auth pap>]
Oct 20 09:29:49 klivlend pppd[340]: rcvd [LCP ConfReq id=0x2 <mru 576>
<asyncmap 0x0> <magic 0x1c759fc6> <pcomp> <accomp>]
Oct 20 09:29:49 klivlend pppd[340]: sent [LCP ConfAck id=0x2 <mru 576>
<asyncmap 0x0> <magic 0x1c759fc6> <pcomp> <accomp>]
Oct 20 09:29:52 klivlend pppd[340]: sent [LCP ConfReq id=0x1 <mru 1500>
<asyncmap 0x20a0000> <magic 0xea07984> <pcomp> <accomp>]
Oct 20 09:29:52 klivlend pppd[340]: rcvd [LCP ConfAck id=0x1 <mru 1500>
<asyncmap 0x20a0000> <magic 0xea07984> <pcomp> <accomp>]
Oct 20 09:29:52 klivlend pppd[340]: sent [IPCP ConfReq id=0x1 <addr 0.0.0.0>
<compress VJ 0f 01>]
Oct 20 09:29:52 klivlend pppd[340]: rcvd [LCP TermReq id=0x3]
Oct 20 09:29:52 klivlend pppd[340]: LCP terminated at peer's request
Oct 20 09:29:52 klivlend pppd[340]: sent [LCP TermAck id=0x3]
Oct 20 09:29:53 klivlend pppd[340]: Hangup (SIGHUP)
Oct 20 09:29:53 klivlend pppd[340]: Modem hangup
Oct 20 09:29:53 klivlend pppd[340]: Connection terminated.
Oct 20 09:29:53 klivlend pppd[340]: Exit.
Bye, klivlend.
Here is PPP-chat connection protocol. After connection
establishing I get terminating and hangup. What is the problem ?
Oct 20 09:29:48 klivlend chat[341]: ATDT5354007^M^M
Oct 20 09:29:48 klivlend chat[341]: CONNECT -- got it
Oct 20 09:29:48 klivlend chat[341]: send (^M)
Oct 20 09:29:48 klivlend pppd[340]: Serial connection established.
Oct 20 09:29:49 klivlend pppd[340]: Using interface ppp0
Oct 20 09:29:49 klivlend pppd[340]: Connect: ppp0 <--> /dev/ttyS1
Oct 20 09:29:49 klivlend pppd[340]: sent [LCP ConfReq id=0x1 <mru 1500>
<asyncmap 0x20a0000> <magic 0xea07984> <pcomp> <accomp>]
Oct 20 09:29:49 klivlend pppd[340]: rcvd [LCP ConfReq id=0x1 <mru 576>
<asyncmap 0x0> <auth pap> <magic 0x1c759fc6> <pcomp> <accomp>]
Oct 20 09:29:49 klivlend pppd[340]: sent [LCP ConfRej id=0x1 <auth pap>]
Oct 20 09:29:49 klivlend pppd[340]: rcvd [LCP ConfReq id=0x2 <mru 576>
<asyncmap 0x0> <magic 0x1c759fc6> <pcomp> <accomp>]
Oct 20 09:29:49 klivlend pppd[340]: sent [LCP ConfAck id=0x2 <mru 576>
<asyncmap 0x0> <magic 0x1c759fc6> <pcomp> <accomp>]
Oct 20 09:29:52 klivlend pppd[340]: sent [LCP ConfReq id=0x1 <mru 1500>
<asyncmap 0x20a0000> <magic 0xea07984> <pcomp> <accomp>]
Oct 20 09:29:52 klivlend pppd[340]: rcvd [LCP ConfAck id=0x1 <mru 1500>
<asyncmap 0x20a0000> <magic 0xea07984> <pcomp> <accomp>]
Oct 20 09:29:52 klivlend pppd[340]: sent [IPCP ConfReq id=0x1 <addr 0.0.0.0>
<compress VJ 0f 01>]
Oct 20 09:29:52 klivlend pppd[340]: rcvd [LCP TermReq id=0x3]
Oct 20 09:29:52 klivlend pppd[340]: LCP terminated at peer's request
Oct 20 09:29:52 klivlend pppd[340]: sent [LCP TermAck id=0x3]
Oct 20 09:29:53 klivlend pppd[340]: Hangup (SIGHUP)
Oct 20 09:29:53 klivlend pppd[340]: Modem hangup
Oct 20 09:29:53 klivlend pppd[340]: Connection terminated.
Oct 20 09:29:53 klivlend pppd[340]: Exit.
Bye, klivlend.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
My chat script:
#!/bin/sh
#
# This is part 2 of the ppp-on script.
# It will perform the connection
# protocol for the desired connection.
#
#
#exec /usr/sbin/chat -v \
exec /usr/sbin/chat -v \
TIMEOUT 3 \
ABORT '\nBUSY\r' \
ABORT '\nNO ANSWER\r' \
ABORT '\nRINGING\r\n\r\nRINGING\ r' \
'' \rAT \
'OK-+++\c-OK' ATH0 \
TIMEOUT 30 \
OK ATDT5354007 \
CONNECT '' \
# uthentication '' \
# ogin:-BREAK-ogin: xxxxs \
# word yyyyy \
name: my_username \
assword: my_passwd
#!/bin/sh
#
# This is part 2 of the ppp-on script.
# It will perform the connection
# protocol for the desired connection.
#
#
#exec /usr/sbin/chat -v \
exec /usr/sbin/chat -v \
TIMEOUT 3 \
ABORT '\nBUSY\r' \
ABORT '\nNO ANSWER\r' \
ABORT '\nRINGING\r\n\r\nRINGING\
'' \rAT \
'OK-+++\c-OK' ATH0 \
TIMEOUT 30 \
OK ATDT5354007 \
CONNECT '' \
# uthentication '' \
# ogin:-BREAK-ogin: xxxxs \
# word yyyyy \
name: my_username \
assword: my_passwd
The chat script is not sending the following sequence:
name: my_username \
assword: my_passwd
Are you sure that the login prompt is name or username and not Login or login?
Jason
name: my_username \
assword: my_passwd
Are you sure that the login prompt is name or username and not Login or login?
Jason
ASKER
Hi Jason,
First, it's a sequence, that I get in minicom:
Username:
Password:
Second, login: sequence doesn't establish connection at all.
Bye, klivlend.
First, it's a sequence, that I get in minicom:
Username:
Password:
Second, login: sequence doesn't establish connection at all.
Bye, klivlend.
I think the problem is in this line :
CONNECT '' \
try using CONNECT \
instead.
Let me know how you go...
Jason
PS - If you go throught the script log you see that CONNECT is received from the remote end - then you send a carriage return then nothing. Another way to do this would be to create a script called dial and in it put the following:
pppd defaultroute /dev/cua1 connect 'chat "" ATDT(provider no) name: username word: password'
Make it executable and try that by typing dial
However if you want to use ppp-on let me look into it further for you.....
CONNECT '' \
try using CONNECT \
instead.
Let me know how you go...
Jason
PS - If you go throught the script log you see that CONNECT is received from the remote end - then you send a carriage return then nothing. Another way to do this would be to create a script called dial and in it put the following:
pppd defaultroute /dev/cua1 connect 'chat "" ATDT(provider no) name: username word: password'
Make it executable and try that by typing dial
However if you want to use ppp-on let me look into it further for you.....
ASKER
Hi unicorntech,
I solved my ppp-chat connection problem.
It became clear that it isn't allowed
to include commeneted lines like
# uthentication \
# ogin: xxx \
# word: yyyyy \
This is bug for my chat. I wonder that this
problem isn't known. May by it's depend on
chat version?
Thanks,klivlend.
I solved my ppp-chat connection problem.
It became clear that it isn't allowed
to include commeneted lines like
# uthentication \
# ogin: xxx \
# word: yyyyy \
This is bug for my chat. I wonder that this
problem isn't known. May by it's depend on
chat version?
Thanks,klivlend.
ASKER
It looks also to me as authentication problem.
I am reading this message from my office.
I will give my chat script over two hours.
Thanks, klivlend.