I'm trying to setup my RHEL 4 laptop to dial-up using my cellphone (Nokia 7610). The phone shows up as a standard serial modem on
/dev/ttyACM0 when I plug it in via USB.
When I try to dial-in with pppd I think it connects, because it gives me an IP Address and DNS:
Code:
local IP address 10.178.162.86
remote IP address 10.6.6.6
primary DNS address 66.94.9.120
secondary DNS address 66.94.25.120
I can ping IP addresses, but I can't ping domain names. For example, I cannot ping yahoo.com, but I can ping its real IP address (216.109.112.135). When I do a
./route I get the following:
Code:
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
10.6.6.6 * 255.255.255.255 UH 0 0 0 ppp0
default 10.6.6.6 0.0.0.0 UG 0 0 0 ppp0
Notice that it has 10.6.6.6 as the gateway. Shouldn't it be 66.94.9.120 - the primary DNS listed by pppd? I *can* ping the primary DNS IP (66.94.9.120).
Is there linux networking command I need to run to correct the DNS?
I really appreciate the help - I've been wrestling with this for weeks =(
More Details:
I know this can work because it works great under windows. In windows I go through the regular dialup settings except I leave the user/password blank, dial *99#, and put the following in as an init string (in advanced modem properties):
at+cgdcont=1,"IP","internet2.voicestream.com"
I know very little about pppd. I got the scripts I'm using from here:
linuxdevcenter.com/pub/a/linux/2004/02/05/linux_cellular.html
To try to connect, I run
/usr/sbin/pppd call tmobile
My pppd script located at
/etc/ppp/peers/tmobile is as follows:
Code:
/dev/ttyACM0
115200
defaultroute # use the cellular network for the default route
usepeerdns # use the DNS servers from the remote network
nodetach # keep pppd in the foreground
crtscts # hardware flow control
lock # lock the serial port
noauth # don't expect the modem to authenticate itself
local # don't use Carrier Detect or Data Terminal Ready
debug
connect "/usr/sbin/chat -v -f /etc/chatscripts/tmobile-connect"
My chat script located at
/etc/chatscripts/tmobile-connect is as follows:
Code:
TIMEOUT 10
ABORT 'BUSY'
ABORT 'NO ANSWER'
ABORT 'ERROR'
SAY 'Starting GPRS connect script\n'
# Get the modem's attention and reset it.
"" 'ATZ'
# E0=No echo, V1=English result codes
OK 'ATE0V1'
# Set Access Point Name (APN)
SAY 'Setting APN\n'
OK 'AT+CGDCONT=1,"IP","internet2.voicestream.com"'
# Dial the number
ABORT 'NO CARRIER'
SAY 'Dialing...\n'
OK 'ATD*99#'
CONNECT ''
Finally, the output is as follows:
Code:
[root@bobpete sbin]# ./pppd call tmobile
Starting GPRS connect script
Setting APN
Dialing...
Serial connection established.
using channel 6
Using interface ppp0
Connect: ppp0 <--> /dev/ttyACM0
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x89e96abe> <pcomp> <accomp>]
rcvd [LCP ConfRej id=0x1 <magic 0x89e96abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x2 <asyncmap 0x0>]
rcvd [LCP ConfAck id=0x2 <asyncmap 0x0>]
rcvd [LCP ConfReq id=0x0 <auth pap> <mru 1500> <asyncmap 0xa0000>]
No auth is possible
sent [LCP ConfRej id=0x0 <auth pap>]
rcvd [LCP ConfReq id=0x1 <mru 1500> <asyncmap 0xa0000>]
sent [LCP ConfAck id=0x1 <mru 1500> <asyncmap 0xa0000>]
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 [IPCP ConfReq id=0x0 <addr 10.6.6.6>]
sent [IPCP ConfAck id=0x0 <addr 10.6.6.6>]
rcvd [LCP ProtRej id=0x0 80 fd 01 01 00 0c 1a 04 78 00 18 04 78 00]
rcvd [IPCP ConfRej id=0x1 <compress VJ 0f 01>]
sent [IPCP ConfReq id=0x2 <addr 0.0.0.0> <ms-dns1 0.0.0.0> <ms-dns3 0.0.0.0>]
rcvd [IPCP ConfNak id=0x2 <addr 10.172.130.252> <ms-dns1 66.94.9.120> <ms-dns3 66.94.25.120>]
sent [IPCP ConfReq id=0x3 <addr 10.172.130.252> <ms-dns1 66.94.9.120> <ms-dns3 66.94.25.120>]
rcvd [IPCP ConfAck id=0x3 <addr 10.172.130.252> <ms-dns1 66.94.9.120> <ms-dns3 66.94.25.120>]
not replacing existing default route to eth0 [192.168.0.1]
local IP address 10.172.130.252
remote IP address 10.6.6.6
primary DNS address 66.94.9.120
secondary DNS address 66.94.25.120