求助,关于linux下ppp,gprs拨号上网的问题,急啊!
本帖最后由 luojijian 于 2011-03-26 16:33 编辑
错误现象:---------------------------
- [root@huang ppp]# pppd call gprs
- timeout set to 5 seconds
- abort on (\nBUSY\r)
- abort on (\nERROR\r)
- abort on (\nNO ANSWER\r)
- abort on (\nNO CARRIER\r)
- abort on (\nNO DIALTONE\r)
- abort on (\nRINGING\r\n\r\nRINGING\r)
- send (AT^M)
- timeout set to 60 seconds
- Press CTRL-C to break the connection process.
- expect (OK)
- AT
- AT^M^M
- OKOK
- -- got it
- send (AT+CGREG=1^M)
- expect (OK)
- ^M
- AT+CGREG=1
- AT+CGREG=1^M^M
- OKOK
- -- got it
- send (AT+CGATT=1^M)
- expect (OK)
- ^M
- AT+CGATT=1
- AT+CGATT=1^M^M
- OKOK
- -- got it
- send (AT+CGDCONT=1,"IP","CMNET"^M)
- expect (OK)
- ^M
- AT+CGDCONT=1,"IP","CMNET"
- AT+CGDCONT=1,"IP","CMNET"^M^M
- OKOK
- -- got it
- send (AT+CGQMIN=1,0,0,0,0,31^M)
- expect (OK)
- ^M
- AT+CGQMIN=1,0,0,0,0,31
- AT+CGQMIN=1,0,0,0,0,31^M^M
- OKOK
- -- got it
- send (AT+CGACT=1,1^M)
- expect (OK)
- ^M
- AT+CGACT=1,1
- AT+CGACT=1,1^M^M
- OKOK
- -- got it
- send (ATDT*99***1#^M)
- timeout set to 60 seconds
- Waiting for connect...
- expect (CONNECT)
- ^M
- ATDT*99***1#
- ATDT*99***1#^M^M
- CONNECTCONNECT
- -- got it
- send (^M)
- Connect Success!
- Serial connection established.
- using channel 1
- Using interface ppp0
- Connect: ppp0 <--> /dev/ttyS0
- Warning - secret file /etc/ppp/pap-secrets has world and/or group access
- sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0xb889b908> <pcomp> <accomp>]
- rcvd [LCP ConfRej id=0x1 <magic 0xb889b908>]
- sent [LCP ConfReq id=0x2 <asyncmap 0x0> <pcomp> <accomp>]
- rcvd [LCP ConfAck id=0x2 <asyncmap 0x0> <pcomp> <accomp>]
- rcvd [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MD5> <pcomp> <accomp>]
- sent [LCP ConfAck id=0x1 <asyncmap 0x0> <auth chap MD5> <pcomp> <accomp>]
- rcvd [CHAP Challenge id=0x1 <77cbeca3d320f610f547a8159c4f9e5b17b8ac0c4e8ace>, name = ""]
- Warning - secret file /etc/ppp/chap-secrets has world and/or group access
- sent [CHAP Response id=0x1 <87e255063a1a08e33190d6bbde50d6ab>, name = "foo"]
- rcvd [CHAP Success id=0x1 ""]
- CHAP authentication succeeded
- CHAP authentication succeeded
- sent [CCP ConfReq id=0x1 <deflate 15> <deflate(old#) 15>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- rcvd [LCP ProtRej id=0x1 80 fd 01 01 00 0c 1a 04 78 00 18 04 78 00]
- Protocol-Reject for 'Compression Control Protocol' (0x80fd) received
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- sent [IPCP ConfReq id=0x1 <compress VJ 0f 01> <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
- IPCP: timeout sending Config-Requests
- sent [LCP TermReq id=0x3 "No network protocols running"]
- rcvd [LCP TermAck id=0x3 "No network protocols running"]
- Connection terminated.
- [root@huang ppp]#
复制代码++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
下面是我的脚本:------------------------
- /etc/ppp/peers/gprs
- ----
- /dev/ttyS0
- 115200
- nocrtscts ##流控
- nodetach ##在前台运行,如果要在后台运行则去掉该项
- noauth
- usepeerdns ##使用DNS,否则还得自己去改/etc/resolv.conf文件
- noipdefault
- ipcp-accept-local
- ipcp-accept-remote
- defaultroute
- user foo ##必须有,因为不像windows下可以不需要用户名
- connect '/usr/sbin/chat -s -v -f /etc/ppp/chat-gprs-connect'
- debug ##输出调试, /var/log/messages中
复制代码++++++++++++++
- /etc/ppp/chat-gprs-connect
- -----
- TIMEOUT 5
- ECHO ON
- ABORT '\nBUSY\r'
- ABORT '\nERROR\r'
- ABORT '\nNO ANSWER\r'
- ABORT '\nNO CARRIER\r'
- ABORT '\nNO DIALTONE\r'
- ABORT '\nRINGING\r\n\r\nRINGING\r'
- '' AT
- TIMEOUT 60
- SAY "Press CTRL-C to break the connection process.\n"
- OK AT+CGREG=1
- OK AT+CGATT=1
- OK 'AT+CGDCONT=1,"IP","CMNET"'
- OK AT+CGQMIN=1,0,0,0,0,31
- OK AT+CGACT=1,1
- OK ATDT*99***1#
- TIMEOUT 60
- SAY "Waiting for connect...\n"
- CONNECT ''
- SAY "Connect Success!\n"
复制代码++++++++++++++++++++
/etc/ppp/chap-secrets和/etc/ppp/pap-secrets都是如下内容:
-----
foo * 123456 *
++++++++++++++++++++++++
/etc/ppp/resolv.conf
------
nameserver 211.136.20.203
nameserver 211.136.17.107
+++++++++++++++++++++++++
恳请高手帮帮忙,如何解决,谢谢了!!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
本人菜鸟一个,对这个真的不懂,谁帮帮忙
了解的朋友帮忙看看啊.......
悲剧啊,偌大的一个论坛无人问津