linux pppd gprs 拨号 Serial line is looped back 错误.

pottichu 2007-12-26 10:01:11
日志信息如下:

pppd[14816]: pppd 2.4.1 started by root, uid 0
chat[14817]: timeout set to 3 seconds\
chat[14817]: abort on (\nBUSY\r)
chat[14817]: abort on (\nNO ANSWER\r)
chat[14817]: abort on (\nRINGING\r\n\r\nRINGING\r)
chat[14817]: send (rAT^M)c
chat[14817]: expect (OK)
chat[14817]: expect (OK)
chat[14817]: rAT^M^M
chat[14817]: OK
chat[14817]: -- got it
chat[14817]: send (ATH0^M)
chat[14817]: timeout set to 30 seconds
pppd[14816]: Serial connection established.
pppd[14816]: Using interface ppp0
pppd[14816]: Connect: ppp0 <--> /dev/ttyS0
pppd[14816]: Warning - secret file /etc/ppp/pap-secrets has world and/or group access
pppd[14816]: Serial line is looped back.
pppd[14816]: Connection terminated.
pppd[14816]: Exit.



ppp-on 文件


ELEPHONE=*99***1# # The telephone number for the connection
ACCOUNT= # The account name for logon (as in 'George Burns')
PASSWORD= # The password for this account (and 'Gracie Allen')
LOCAL_IP=0.0.0.0 # Local IP address if known. Dynamic = 0.0.0.0
REMOTE_IP=0.0.0.0 # Remote IP address if desired. Normally 0.0.0.0
NETMASK=255.255.255.0 # The proper netmask if needed
export TELEPHONE ACCOUNT PASSWORD
DIALER_SCRIPT=/etc/ppp/ppp-on-dialer
exec /usr/sbin/pppd debug lock modem /dev/ttyS0 115200 \
asyncmap 20A0000 escape FF kdebug 0 $LOCAL_IP:$REMOTE_IP \
noipdefault netmask $NETMASK defaultroute connect $DIALER_SCRIPT



ppp-on-dialer

exec 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 ATDT$TELEPHONE \
CONNECT '' \
ogin:--ogin: $ACCOUNT \
assword: $PASSWORD




因为我用 minicom 连上去

AT+CGREG? //检测是否登陆上GPRS 网络

返回
+CGREG: 0, 1
OK

说明登陆 成功登陆


Serial connection established 说明 拨号已经 OK了, 可 Serial line is looped back ....
哎. 查了一天了,还是没结果. help!help!
...全文
1310 16 打赏 收藏 转发到动态 举报
写回复
用AI写文章
16 条回复
切换为时间正序
请发表友善的回复…
发表回复
gtinder 2010-04-08
  • 打赏
  • 举报
回复
请各位大虾帮忙分析下!谢谢
gtinder 2010-04-08
  • 打赏
  • 举报
回复
小弟我也遇到了类同的问题:
请看log下的数据:
Apr 8 15:09:55 localhost pppd[12313]: pppd 2.4.1 started by root, uid 0
Apr 8 15:09:56 localhost chat[12314]: timeout set to 3 seconds
Apr 8 15:09:56 localhost chat[12314]: abort on (\nBUSY\r)
Apr 8 15:09:56 localhost chat[12314]: abort on (\nNO ANSWER\r)
Apr 8 15:09:56 localhost chat[12314]: abort on (\nRINGING\r\n\r\nRINGING\r)
Apr 8 15:09:56 localhost chat[12314]: send (rAT^M)
Apr 8 15:09:57 localhost chat[12314]: expect (OK)
Apr 8 15:09:57 localhost chat[12314]: rAT^M^M
Apr 8 15:09:57 localhost chat[12314]: OK
Apr 8 15:09:57 localhost chat[12314]: -- got it
Apr 8 15:09:57 localhost chat[12314]: send (ATH0^M)
Apr 8 15:09:57 localhost chat[12314]: timeout set to 30 seconds
Apr 8 15:09:57 localhost chat[12314]: expect (OK)
Apr 8 15:09:57 localhost chat[12314]: ^M
Apr 8 15:09:57 localhost chat[12314]: ATH0^M^M
Apr 8 15:09:57 localhost chat[12314]: OK
Apr 8 15:09:57 localhost chat[12314]: -- got it
Apr 8 15:09:57 localhost chat[12314]: send (AT+IPR=115200^M)
Apr 8 15:09:57 localhost chat[12314]: expect (OK)
Apr 8 15:09:57 localhost chat[12314]: ^M
Apr 8 15:09:57 localhost chat[12314]: AT+IPR=115200^M^M
Apr 8 15:09:57 localhost chat[12314]: OK
Apr 8 15:09:57 localhost chat[12314]: -- got it
Apr 8 15:09:57 localhost chat[12314]: send (AT+CGDCONT=1,IP,CMNET^M)
Apr 8 15:09:57 localhost pppd[12313]: Serial connection established.
Apr 8 15:09:57 localhost /etc/hotplug/net.agent: assuming ppp0 is already up
Apr 8 15:09:57 localhost pppd[12313]: Using interface ppp0
Apr 8 15:09:57 localhost pppd[12313]: Connect: ppp0 <--> /dev/ttyS0
Apr 8 15:10:02 localhost pppd[12313]: Serial line is looped back.
Apr 8 15:10:02 localhost pppd[12313]: Connection terminated.
Apr 8 15:10:02 localhost /etc/hotplug/net.agent: NET unregister event not supported
Apr 8 15:10:03 localhost pppd[12313]: Exit.
qlx1983 2009-02-10
  • 打赏
  • 举报
回复
在linux下的pc机用GNOME-PPP拨号,是可以拨上的,我移植到开发板的后,就不行了。。。
楼主不知道是什么情况,,,可以说详细一点,大家一下学习一下哈
qlx1983 2009-02-10
  • 打赏
  • 举报
回复
我最近也在做相关的工作,不知道楼主有没有搞定啊??
我的情况比你更糟糕,ppp-on运行后一点反应都没有啊,,,
geniusmen 2008-10-06
  • 打赏
  • 举报
回复
你好呀,我现在也是在用SIM卡拨号上网,也是出现你这个问题,LOG信息和你的也一样,然后在WINDOS下也能拨号上网,在LINUX下就不可以,你的问题解决了吗? 请求你的帮助呀!请给我发邮件,小弟很感激喔……………xieyun912@163.com 看见请一定回复!!谢谢
pottichu 2007-12-27
  • 打赏
  • 举报
回复
OK 'AT+CGCLASS= "B " '
OK 'AT+CGDCONT=1, "IP ", "CMNET " '

是不是应该是设置一下
pottichu 2007-12-27
  • 打赏
  • 举报
回复
谢谢大家帮顶.
pottichu 2007-12-27
  • 打赏
  • 举报
回复
下面是一个正确的日志信息,网上找的,我的依然不行 :
http://book.chinaz.com/faq/howto/088.htm

Oct 21 16:09:58 hwin chat[19868]: abort on (NO CARRIER)
Oct 21 16:09:59 hwin chat[19868]: abort on (BUSY)
Oct 21 16:09:59 hwin chat[19868]: send (ATZ^M)
Oct 21 16:09:59 hwin chat[19868]: expect (OK)
Oct 21 16:10:00 hwin chat[19868]: ATZ^M^M
Oct 21 16:10:00 hwin chat[19868]: OK -- got it
Oct 21 16:10:00 hwin chat[19868]: send (ATDT722298^M)
Oct 21 16:10:00 hwin chat[19868]: expect (CONNECT)
Oct 21 16:10:00 hwin chat[19868]: ^M
Oct 21 16:10:22 hwin chat[19868]: ATDT722298^M^M
Oct 21 16:10:22 hwin chat[19868]: CONNECT -- got it
Oct 21 16:10:22 hwin chat[19868]: send (^M)
Oct 21 16:10:22 hwin chat[19868]: expect (ogin:)
Oct 21 16:10:23 hwin chat[19868]: kepler login: -- got it
Oct 21 16:10:23 hwin chat[19868]: send (hartr^M)
Oct 21 16:10:23 hwin chat[19868]: expect (ssword:)
Oct 21 16:10:23 hwin chat[19868]: hartr^M
Oct 21 16:10:23 hwin chat[19868]: Password: -- got it
Oct 21 16:10:23 hwin chat[19868]: send (??????^M)
Oct 21 16:10:23 hwin chat[19868]: expect (hartr)
Oct 21 16:10:24 hwin chat[19868]: [hartr -- got it
Oct 21 16:10:24 hwin chat[19868]: send (ppp^M)
Oct 21 16:10:27 hwin pppd[19872]: pppd 2.1.2 started by root, uid 0
Oct 21 16:10:27 hwin pppd[19873]: Using interface ppp0
Oct 21 16:10:27 hwin pppd[19873]: Connect: ppp0 <--> /dev/cua1
Oct 21 16:10:27 hwin pppd[19873]: fsm_sdata(LCP): Sent code 1, id 1.
Oct 21 16:10:27 hwin pppd[19873]: LCP: sending Configure-Request, id 1
Oct 21 16:10:27 hwin pppd[19873]: fsm_rconfreq(LCP): Rcvd id 1.
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd MRU
Oct 21 16:10:27 hwin pppd[19873]: (1500)
Oct 21 16:10:27 hwin pppd[19873]: (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd ASYNCMAP
Oct 21 16:10:27 hwin pppd[19873]: (0)
Oct 21 16:10:27 hwin pppd[19873]: (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd MAGICNUMBER
Oct 21 16:10:27 hwin pppd[19873]: (a098b898)
Oct 21 16:10:27 hwin pppd[19873]: (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd PCOMPRESSION
Oct 21 16:10:27 hwin pppd[19873]: (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: rcvd ACCOMPRESSION
Oct 21 16:10:27 hwin pppd[19873]: (ACK)
Oct 21 16:10:27 hwin pppd[19873]: lcp_reqci: returning CONFACK.
Oct 21 16:10:27 hwin pppd[19873]: fsm_sdata(LCP): Sent code 2, id 1.
Oct 21 16:10:27 hwin pppd[19873]: fsm_rconfack(LCP): Rcvd id 1.
Oct 21 16:10:27 hwin pppd[19873]: fsm_sdata(IPCP): Sent code 1, id 1.
Oct 21 16:10:27 hwin pppd[19873]: IPCP: sending Configure-Request, id 1
Oct 21 16:10:27 hwin pppd[19873]: fsm_rconfreq(IPCP): Rcvd id 1.
Oct 21 16:10:27 hwin pppd[19873]: ipcp: received ADDR
Oct 21 16:10:27 hwin pppd[19873]: (10.144.153.51)
Oct 21 16:10:27 hwin pppd[19873]: (ACK)
Oct 21 16:10:27 hwin pppd[19873]: ipcp: received COMPRESSTYPE
Oct 21 16:10:27 hwin pppd[19873]: (45)
Oct 21 16:10:27 hwin pppd[19873]: (ACK)
Oct 21 16:10:27 hwin pppd[19873]: ipcp: returning Configure-ACK
Oct 21 16:10:28 hwin pppd[19873]: fsm_sdata(IPCP): Sent code 2, id 1.
Oct 21 16:10:30 hwin pppd[19873]: fsm_sdata(IPCP): Sent code 1, id 1.
Oct 21 16:10:30 hwin pppd[19873]: IPCP: sending Configure-Request, id 1
Oct 21 16:10:30 hwin pppd[19873]: fsm_rconfreq(IPCP): Rcvd id 255.
Oct 21 16:10:31 hwin pppd[19873]: ipcp: received ADDR
Oct 21 16:10:31 hwin pppd[19873]: (10.144.153.51)
Oct 21 16:10:31 hwin pppd[19873]: (ACK)
Oct 21 16:10:31 hwin pppd[19873]: ipcp: received COMPRESSTYPE
Oct 21 16:10:31 hwin pppd[19873]: (45)
Oct 21 16:10:31 hwin pppd[19873]: (ACK)
Oct 21 16:10:31 hwin pppd[19873]: ipcp: returning Configure-ACK
Oct 21 16:10:31 hwin pppd[19873]: fsm_sdata(IPCP): Sent code 2, id 255.
Oct 21 16:10:31 hwin pppd[19873]: fsm_rconfack(IPCP): Rcvd id 1.
Oct 21 16:10:31 hwin pppd[19873]: ipcp: up
Oct 21 16:10:31 hwin pppd[19873]: local IP address 10.144.153.104
Oct 21 16:10:31 hwin pppd[19873]: remote IP address 10.144.153.51
yydrewdrew 2007-12-27
  • 打赏
  • 举报
回复
不懂 up
pottichu 2007-12-27
  • 打赏
  • 举报
回复
exec 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 ATDT$TELEPHONE \
CONNECT ''
# ogin:--ogin: $ACCOUNT \
# assword: $PASSWORD


我把
# ogin:--ogin: $ACCOUNT \
# assword: $PASSWORD
去掉了, 是不是因此 导致 LCP 没用通过验证而被 远端peer 关闭.

但当我加上
ogin:--ogin: $ACCOUNT \
assword: $PASSWORD
的时候, 收不到 ogin , 无法进行验证, 没办法继续.
打印信息如下:

Dec 26 20:59:13 pppd[14470]: pppd 2.4.1 started by root, uid 0
Dec 26 20:59:14 chat[14471]: timeout set to 3 seconds
Dec 26 20:59:14 chat[14471]: abort on (\nBUSY\r)
Dec 26 20:59:14 chat[14471]: abort on (\nNO ANSWER\r)
Dec 26 20:59:14 chat[14471]: abort on (\nRINGING\r\n\r\nRINGING\r)
Dec 26 20:59:14 chat[14471]: send (rAT^M)
Dec 26 20:59:14 chat[14471]: expect (OK)
Dec 26 20:59:14 chat[14471]: rAT^M^M
Dec 26 20:59:14 chat[14471]: OK
Dec 26 20:59:14 chat[14471]: -- got it
Dec 26 20:59:14 chat[14471]: send (ATH0^M)
Dec 26 20:59:15 chat[14471]: timeout set to 30 seconds
Dec 26 20:59:15 chat[14471]: expect (OK)
Dec 26 20:59:15 chat[14471]: ^M
Dec 26 20:59:15 chat[14471]: ATH0^M^M
Dec 26 20:59:15 chat[14471]: OK
Dec 26 20:59:15 chat[14471]: -- got it
Dec 26 20:59:15 chat[14471]: send (ATDT*99***1#^M)
Dec 26 20:59:15 chat[14471]: expect (CONNECT)
Dec 26 20:59:15 chat[14471]: ^M
Dec 26 20:59:15 chat[14471]: ATDT*99***1#^M^M
Dec 26 20:59:15 chat[14471]: CONNECT
Dec 26 20:59:15 chat[14471]: -- got it
Dec 26 20:59:15 chat[14471]: send (^M)
Dec 26 20:59:15 chat[14471]: expect (ogin:)
Dec 26 20:59:15 chat[14471]: ^M
Dec 26 20:59:45 chat[14471]: alarm
Dec 26 20:59:45 chat[14471]: send (^M)
Dec 26 20:59:45 chat[14471]: expect (ogin:)
Dec 26 21:00:15 chat[14471]: alarm
Dec 26 21:00:15 chat[14471]: Failed
Dec 26 21:00:15 pppd[14470]: Connect script failed


收不到 ogin:
这是怎么回事?
pottichu 2007-12-27
  • 打赏
  • 举报
回复
up.
pottichu 2007-12-27
  • 打赏
  • 举报
回复
谢谢大家顶贴.
sim 卡不支持 smnet 模式****
pottichu 2007-12-26
  • 打赏
  • 举报
回复
Dec 26 23:10:25 pppd[15029]: pppd 2.4.1 started by root, uid 0
Dec 26 23:10:26 chat[15030]: timeout set to 3 seconds
Dec 26 23:10:26 chat[15030]: abort on (\nBUSY\r)
Dec 26 23:10:26 chat[15030]: abort on (\nNO ANSWER\r)
Dec 26 23:10:26 chat[15030]: abort on (\nRINGING\r\n\r\nRINGING\r)
Dec 26 23:10:26 chat[15030]: send (rAT^M)
Dec 26 23:10:27 chat[15030]: expect (OK)
Dec 26 23:10:27 chat[15030]: rAT^M^M
Dec 26 23:10:27 chat[15030]: OK
Dec 26 23:10:27 chat[15030]: -- got it
Dec 26 23:10:27 chat[15030]: send (ATH0^M)
Dec 26 23:10:27 chat[15030]: timeout set to 30 seconds
Dec 26 23:10:27 chat[15030]: expect (OK)
Dec 26 23:10:27 chat[15030]: ^M
Dec 26 23:10:27 chat[15030]: ATH0^M^M
Dec 26 23:10:27 chat[15030]: OK
Dec 26 23:10:27 chat[15030]: -- got it
Dec 26 23:10:27 chat[15030]: send (ATDT*99***1#^M)
Dec 26 23:10:27 chat[15030]: expect (CONNECT)
Dec 26 23:10:27 chat[15030]: ^M
Dec 26 23:10:27 chat[15030]: ATDT*99***1#^M^M
Dec 26 23:10:27 chat[15030]: CONNECT
Dec 26 23:10:27 chat[15030]: -- got it
Dec 26 23:10:27 chat[15030]: send (^M)
Dec 26 23:10:27 pppd[15029]: Serial connection established.
Dec 26 23:10:27 pppd[15029]: Using interface ppp0
Dec 26 23:10:27 pppd[15029]: Connect: ppp0 <--> /dev/ttyS0
Dec 26 23:10:28 pppd[15029]: Warning - secret file /etc/ppp/pap-secrets has world and/or group access
Dec 26 23:10:28 modprobe: modprobe: Can't locate module ppp-compress-21
Dec 26 23:10:28 modprobe: modprobe: Can't locate module ppp-compress-21
Dec 26 23:10:28 pppd[15029]: LCP terminated by peer (peer refused to authenticate)
Dec 26 23:10:31 pppd[15029]: Connection terminated.
Dec 26 23:10:32 pppd[15029]: Exit.


TNND, modprobe: modprobe: Can't locate module ppp-compress-21.


yxwsbobo 2007-12-26
  • 打赏
  • 举报
回复
帮定
pottichu 2007-12-26
  • 打赏
  • 举报
回复
windows 下能拨通.
help help.
yuyunliuhen 2007-12-26
  • 打赏
  • 举报
回复
看得一头雾水 ,不懂, 帮顶!^_^

64,637

社区成员

发帖
与我相关
我的任务
社区描述
C++ 语言相关问题讨论,技术干货分享,前沿动态等
c++ 技术论坛(原bbs)
社区管理员
  • C++ 语言社区
  • encoderlee
  • paschen
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
  1. 请不要发布与C++技术无关的贴子
  2. 请不要发布与技术无关的招聘、广告的帖子
  3. 请尽可能的描述清楚你的问题,如果涉及到代码请尽可能的格式化一下

试试用AI创作助手写篇文章吧