Use Puppy as router - with Netgear router + GPRS modem

Using applications, configuring, problems
Post Reply
Message
Author
mikkythomeon
Posts: 5
Joined: Sun 05 May 2013, 07:48

Use Puppy as router - with Netgear router + GPRS modem

#1 Post by mikkythomeon »

Hi

I have been battling for some time. What I have is this:

- Netgear router, being used as a wireless access point.

- 3G USB modem (where I come from, bandwidth is not cheap - this is provided with my job). I can connect normally using gpgrs perfectly.

I have the following idea: Connect to the internet via the gprs modem on interface ppp0. From my main PC attached to the wireless modem, I would like to use interface eth0 to connect to the Netgear router. The Netgear router is configured to use DHCP, so all clients connecting to the router get assigned an IP address.

The PC connected to the modem is assigned an IP address of 192.168.0.1. The Netgear router / wireless AP is assigned as IP of 192.168.0.3. So all the clients get assigned addresses in the range 192.168.0.4 and upwards.

How do I link ppp0 and eth0 so that I can achieve this? Currently, when I connect to the internal network, then I cannot access internet, and vice versa.

I would appreciate some pointers to get this right.

Thanks!

firak
Posts: 175
Joined: Mon 14 Apr 2008, 14:07

#2 Post by firak »

Sorry I have no kolege how to config this, but...
Was able to connect one or moare pc, to a Android phone.
There is a function in Android phones to create an axesss point whit the phone itself, that it can work as a router + wireless modem .
I shink that if you do not menege in your way, you can still use the sim card on an adroid device, and have the result that you whish.

mikkythomeon
Posts: 5
Joined: Sun 05 May 2013, 07:48

#3 Post by mikkythomeon »

Thanks Firak. I imagine that this should be quite achievable by just providing a route. It seems like pFirewall may be able to do this, or somehow it should be editing the routing tables. The 3G modem generally stays at home...its extra bucks to get a phone to do the job or a 3G router, which is what I am trying to avoid.

Any help would be great...!

mikkythomeon
Posts: 5
Joined: Sun 05 May 2013, 07:48

#4 Post by mikkythomeon »

Well I have just tried removing the router from the equation and found that the problem happens even on my PC only.

I cant seem to have both ppp0 and eth0 running without one affecting the other! When ppp0 is up, I can surf the net. When eth0 is up, I can access the network, but cant surf the net.

User avatar
rerwin
Posts: 2017
Joined: Wed 24 Aug 2005, 22:50
Location: Maine, USA

#5 Post by rerwin »

The shareinternet package would seem to be appropriate for your situation. I have not used it, but it is apparently used successfully by some.
http://www.murga-linux.com/puppy/viewto ... 415#264415

mikkythomeon
Posts: 5
Joined: Sun 05 May 2013, 07:48

#6 Post by mikkythomeon »

Well I read on the Netgear site, apparently the router cannot be used as a proper wireless hotspot, in other words, I had no choice but to disable DHCP on the router and then I had to assign static IPs.

I then run a script at startup:

Code: Select all

/usr/bin/pgprs-connect
iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
echo l > /proc/sys/net/ipv4/ip_forward
dnsmasq
Everything works, except that I have to issue the dnsmasq command to enable to dns service. It seems that the script does not allow time for everything to complete before the dnsmasq command is called.

Any advice on this?

Thanks
[/code]

User avatar
rerwin
Posts: 2017
Joined: Wed 24 Aug 2005, 22:50
Location: Maine, USA

#7 Post by rerwin »

mikkythomeon,
Why not use a 'sleep' command before dnsmasq?
sleep 1 or sleep 0.1 or another value (in seconds)

mikkythomeon
Posts: 5
Joined: Sun 05 May 2013, 07:48

#8 Post by mikkythomeon »

Thanks...will try that now...

Post Reply