OpenWrt Forum Archive

Topic: Routing problem with PPP connection (3G modem)

The content of this topic has been archived on 26 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hello everybody,

I have Kamikaze 7.09 installed on Asus WL500GP router. I want to use 3G USB modem (Huaweii e220) to connect to the internet. I followed howtos and its _almost_ OK:
I can connect to ISP. I can ping hosts outside from router. DNS works fine.
But I cannot ping internet hosts from PC connected to my router.
It's like the router did not use ppp0 as default gateway. But it looks OK, here is the output of route command:

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
10.64.64.64     *               255.255.255.255 UH    0      0        0 ppp0
192.168.1.0     *               255.255.255.0   U     0      0        0 br-lan
default         10.64.64.64     0.0.0.0         UG    0      0        0 ppp0


Thanks for any hints,

Maciej

- Do you run dnsmasq on the router?

- Are your clients DNS and default gateway point to the routers LAN IP?

Yes, here is ps output:

root@OpenWrt:~# ps
  PID  Uid     VmSize Stat Command
    1 root        400 S   init
    2 root            SW  [keventd]
    3 root            RWN [ksoftirqd_CPU0]
    4 root            SW  [kswapd]
    5 root            SW  [bdflush]
    6 root            SW  [kupdated]
    9 root            SW  [mtdblockd]
   54 root            SWN [jffs2_gcd_mtd4]
   67 root        412 S   logger -s -p 6 -t
   71 root        404 S   init
   85 root        400 S   syslogd -C16
   93 root        376 S   klogd
  217 root        448 S   udhcpc -t 0 -i eth0.1 -b -p /var/run/eth0.1.pid -R
  222 root            SW  [khubd]
  395 root        376 S   crond -c /etc/crontabs
  401 root        416 S   /usr/sbin/dropbear -p 22
  409 root        428 S   httpd -p 80 -h /www -r OpenWrt
  412 root        380 S   telnetd -l /bin/login
  432 nobody      456 S   /usr/sbin/dnsmasq --dhcp-range=lan,192.168.1.100,192.168.1.250,255.255.255.0,12h -I eth0.1
  469 root        508 S   /bin/ash --login
  561 root        616 S   /usr/sbin/dropbear -p 22
  562 root        588 S   -ash
  667 root        616 R   /usr/sbin/dropbear -p 22
  668 root        552 S   -ash
  710 root        580 S   pppd call huawei-e220
  724 root        416 R   ps
root@OpenWrt:~#


On client PC (Windows), I have ethernet interface configured to use DHCP and I get IP and DNS server name from router.
Router is default gateway.

When I try to ping DNS address from PC, I can see that I get DNS name resolved, but ping does not reach it.

Maciej

Check that the firewall is using the right interface for the wan interface.

OK - I did it: iptables + masquerade did the job.
Thanx for hints

The discussion might have continued from here.