Page 1 of 1

How do I set up a router with Puppy?

Posted: Fri 11 Nov 2005, 06:47
by MU
Hi,

I want to do this:

i have a ADSL-flatrate.
I have an old Pentium 200.
I want to set it up with Puppy and Apache, so that it is always online and can serve you with Dotpups.

I also have a Notebook.
I need it to work and to surf the Web.
So i want to connect it with the ethernet-network-card to the Puppy-Webserver (you call it Gateway then?) to access the Web.

Question:
What do I have to set up for that?
I can set up Apache with httpd.conf, but my knowledge of Networks is not good.
I think I need a program on the Webserver-machine, thats leads the notebook through to the Web?

Thanks, Mark

Re: Puppy-Gateway?

Posted: Fri 11 Nov 2005, 07:22
by Lobster
I am assuming you jave an ADSL modem connected to one computer and to the internet? It sounds like the easiest solution is a router.

An ethernet router takes two or more inputs and has one input to your modem.

You can think of it splitting and queing the system. Are you using cable or wifi? Wifi is the same without the cable.

Maybe someone has a router they can provide? That would be the simplest solution. Be interested in others suggestions.

Posted: Fri 11 Nov 2005, 07:25
by MU
I have cable.
I think routers are not very expensive, 30-40 Euro.

That sounds like a good solution.

But as I would use the P200 for nothing else, it could serve as a router too, no?
It just needs a second Ethernet-Card, one for the ADSL-modem, one for the Notebook.
Those cards just cost 5-15 Euro.

Mark

Posted: Fri 11 Nov 2005, 07:40
by Lobster
yep 30-40 Euro new.

Yes I understand what you are trying to do as I had a similar idea. With a dedicated router there will be no speed loss but if the computer is routing and serving I have a feeling this will be less effective (can someone explain this?). There is nothing to go wrong with routers (except the connections so even second hand they tend to be OK).

Posted: Fri 11 Nov 2005, 07:44
by MU
No, there should be no loss in speed.
Ethernetcards have 10 Mbit or 100 Mbit.

My ADSL just has 2 Mbit.
In big companies, Gateways route hundrets of clients to the web.

Mark

Previous posts

Posted: Fri 11 Nov 2005, 09:09
by raffy
This is great.

Rarsa has posted detailed instructions in this forum about setting up the network like that, and dvw86 has setup a server like that sometime ago - he may have some ideas.

Edit: Maybe i saw that in another forum :oops: Will check on it and PM you.

Rarsa's post is here, but may be different from what you need - http://www.murga.org/~puppy/viewtopic.php?t=2163

Posted: Fri 11 Nov 2005, 09:12
by MU
Thanks raffy, I will try to find it tonight, when I repaired my computer (the fan is dying).

Greets, Mark

Posted: Fri 11 Nov 2005, 09:58
by Guest
Two NICS, use ' ifconfig ' to set their addresses and netmask and ' route' to set the tables.

Posted: Fri 11 Nov 2005, 15:09
by rarsa
Raffy,

My post is for a completelly different problem.

MU,

Here is a good link http://www.homenethelp.com/web/faq/shar ... router.asp

Posted: Fri 11 Nov 2005, 16:06
by dvw86
I've done that exact thing with OS X as the web server and gateway. Setting up OS X to do that is much different than Puppy though. While it worked fine, I still ended up just getting a router. The router was (A) easier to set up for port forwarding when it came to applications like Bit-Torrent (B) costs less to have on all the time and (C) takes up less space on the desk. My server also started getting a lot of traffic and even though I have a 3 meg connection, it slowed down to almost dial up speeds.

Posted: Fri 11 Nov 2005, 16:19
by aahhaaa
I was reading up on routers recently, different kinds of networking. One of their more complex functions is traffic direction, and config'ing seems important. If you have people d/ling different files at the same time, there are priority demands on your HD, RAM, & CPU bus, you'd want to be sure to give your primary computer a high priority.

Posted: Fri 11 Nov 2005, 19:35
by dvw86
aahhaaa wrote:I was reading up on routers recently, different kinds of networking. One of their more complex functions is traffic direction, and config'ing seems important. If you have people d/ling different files at the same time, there are priority demands on your HD, RAM, & CPU bus, you'd want to be sure to give your primary computer a high priority.
That is correct. Some of the nicer routers will let you limit how much bandwidth each service or port can use. As I found out, this is something to consider when serving up large files for a popular Linux OS :)

Posted: Fri 11 Nov 2005, 21:06
by MU
I bought a second nic today, and will try to use the P200 as router and Webserver in the next days.
Thanks for all tips so far :)

Mark

Simple Internet connection sharing

Posted: Fri 11 Nov 2005, 21:19
by raffy
Found it! I guess this is for simple Internet connection sharing, meaning, use an existing connection, but use two network cards in one PC:
I use the Internet from eth0 and i try to share connection (NAT) to eth1.
I set eth1 with ip 192.168.0.1 mask 255.255.255.0 .
eth0 is with net ip (real) , mask 255.255.255.0 gateway + DNS

I set other computers which are connected to eth1 with ip's 192.168.0.2/255,
mask 255.255.255.0 and gateway 192.168.0.1
I can ping all ip's but they can't ping me .

and then set :

iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

No Internet on computers connected to eth1 (no ping to ip which are in the network with the net)

then set:

iptables - t nat -A POSTROUTING -o eth0 -j SNAT -to-source "netip"

add:

iptables -A PREROUTING -i eth0 -j DNAT --to-destination 192.168.0.1

enable forwarding too with

echo 1 > /proc/sys/net/ipv4/ip_forward
I have been keeping this set of instructions (culled from different forums) for a day like this, but have not tried it yet :oops: (especially that last line - must be different for Puppy)

Posted: Fri 11 Nov 2005, 21:38
by MU
Thanks Raffy, I also will search my german board with these keywords.
There were many threads with IPtables in the past years.

There also should be a HowTo in the web.
I will try to document, how I realize it on puppy then :)

Mark

Beginners Help

Posted: Tue 20 Dec 2005, 02:38
by ecomoney
I use the Internet from eth0 and i try to share connection (NAT) to eth1.
I set eth1 with ip 192.168.0.1 mask 255.255.255.0 .
eth0 is with net ip (real) , mask 255.255.255.0 gateway + DNS

I set other computers which are connected to eth1 with ip's 192.168.0.2/255,
mask 255.255.255.0 and gateway 192.168.0.1
I can ping all ip's but they can't ping me .

and then set :

iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

No Internet on computers connected to eth1 (no ping to ip which are in the network with the net)

then set:

iptables - t nat -A POSTROUTING -o eth0 -j SNAT -to-source "netip"

add:

iptables -A PREROUTING -i eth0 -j DNAT --to-destination 192.168.0.1

enable forwarding too with

echo 1 > /proc/sys/net/ipv4/ip_forward
Hi Raffy, thanks for that

May we have a "beginners help" blow by blow run down of how to do that plzzzz!!!!

Posted: Tue 20 Dec 2005, 19:07
by Auda
Unless you specificaly want to use puppy have a look at Freesco
http://forums.freesco.org/support/
Freesco a single floppy router and firewall. Its instalable on a hard drive or cd and will run Apache, ftp, mail, etc.
Auda

Posted: Wed 21 Dec 2005, 06:28
by sunburnt
Mark; in Win. at least it's called a proxy, Linux maybe not.
Try using the Freesco Router (Free Cisco Router), it only needs a floppy to boot & work, will run off a HD also, small fast, simple to setup & use, has http, ftp, routing, & a pile of packages for it, NFS, Samba, etc.
It's what I'll be using for the LanPuppy server if Puppy can't be fixed for dhcp & Samba servers.

http://freesco.org/

Smoothwall

Posted: Wed 21 Dec 2005, 11:36
by ecomoney
Were using smoothwall at the momen (www.smoothwall.org), That turns the pc into a dedicated firewall and rounter. Its excellent, but the pc we are using for this could also easily run puppy and solve a lot of domestic problems ;-)

Posted: Wed 21 Dec 2005, 15:25
by edoc
sunburnt wrote:Mark; in Win. at least it's called a proxy, Linux maybe not.
Try using the Freesco Router (Free Cisco Router), it only needs a floppy to boot & work, will run off a HD also, small fast, simple to setup & use, has http, ftp, routing, & a pile of packages for it, NFS, Samba, etc.
It's what I'll be using for the LanPuppy server if Puppy can't be fixed for dhcp & Samba servers.

http://freesco.org/
Can you add me to a LanPuppy list so I may be in the loop as it is developed? I just PM's another Forum member asking of there was anything like that in the works!

I am not smart enough to help meaningfully in development but seem to have the gift of breaking things -- useful in alpha and beta testing I suppose!

Thanks! doc