OpenWrt Forum Archive

Topic: how to share Internet connection to my TP LINK?

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

Hello,

I have a TP LINK MR 3420, and a laptop.

My laptop is 192.168.1.2 and my TP LINK IP is 192.168.1.1

My laptop has internet access from a modem, and I want to share it to my TP LINK, so TP LINK can install packages online.

I got confused with the manual, here's what I've done

I already set my TP LINK /etc/config/network

config 'interface' 'lan'
    option 'ifname' 'eth0'
       option 'type' 'bridge'
    option 'proto' 'static'
    option 'ipaddr' '192.168.1.1'
    option 'netmask' '255.255.255.0'
    option 'gateway' '192.168.1.2'

the gateway is my laptop's IP, but It still cant even ping google.com from my TP LINK
what else should I do to make my TP LINK get my internet connection from my laptop?
please help

bump !..

I have same question.. Need this to update repo when there is no internet connection and installing 3G modem package.

thanks

Hi have you found the ways on how to make to connect to your computer internet?

The problem is to access OpenWrt through the WAN port.

So, first, after all that, you must edit /etc/config/firewall and change the WAN zone rule INPUT from REJECT to ACCEPT:

config zone
        option name             wan
        option network          'wan'
        option input            ACCEPT
        option output           ACCEPT
        option forward          REJECT
        option masq             1
        option mtu_fix          1

Now do:
/etc/init.d/firewall restart

Connect the router's WAN port to the computer's LAN port.
In windows, go into your modem's connection settings, set it to share the internet with the LAN interface.
You may search for Windows ICS (Internet Connection Sharing).

After that you can access your router through the wan port , with the computer.
But you will have to figure out what IP address Windows gave to openwrt...
That is found fast by looking at the IP of the LAN interface. Then you know the range.
Now you could try the next IP, or use an IP scanner and set a search for hosts from xxx.xxx.xxx.1 to xxx.xxx.xxx.254.
The three first IP numbers (xxx.xxx.xxx.NNN) are the same as your LAN IP.

(Last edited by dabyd64 on 13 Nov 2012, 21:17)

Or set a static ip and gw (your pc) also on wan interface...

The discussion might have continued from here.