LebGeeks

A community for technology geeks in Lebanon.

You are not logged in.

#1 July 1 2015

AVOlio
Member

Connect two PCs with Lan (using 2 routers).

So the idea is to play games against each other.
We have two routers, one next to each PC.

First PC (mine), connected to a Thomson TG585 v8 router.
The connections on the Thomson router are:
-First PC
-Connection to the second PC
-And the DSL internet in cable.

Second PC, connected to a Tenda 11N wireless router.
The connections on the Tenda router are:
-Second PC
-Connection coming from first PC
-Internet cable in. (this router is connected to an internet other than the DSL of the first one)

So i just need to connect these two computers together, to play lan games.
How will i do that?

Offline

#2 July 2 2015

ironman
Member

Re: Connect two PCs with Lan (using 2 routers).

If both routers are connected together using a cable,

You must

Turn off DHCP on Router 2 (for example)
Change it's LAN IP to be within the range of Router 1's DHCP Pool

At this level both PC's will be within the same DHCP range, and will be seeing each others.

Now in order to go through connection 1 (DSL) you specify your gateway to be Router's 1 IP
Same thing, to go through connection 2, you change your gateway to be Router2's LAN IP.

Last edited by ironman (July 2 2015)

Offline

#3 July 2 2015

rolf
Member

Re: Connect two PCs with Lan (using 2 routers).

you can connect the two computers directly with a twisted pair lan cable, I think. But i think even a normal cable will work.

Offline

#4 July 2 2015

AVOlio
Member

Re: Connect two PCs with Lan (using 2 routers).

Thanks, i managed to make it work somehow.
Disabled DHCP on the tenda router, and changed the Lan IP close to the thomson router.

But now, the Wifi internet of the thomson seems like too slow,and sometimes disconnecting?
why is that?

Offline

#5 July 3 2015

ironman
Member

Re: Connect two PCs with Lan (using 2 routers).

Seems to be from the provider, what you did will never affect your internet connection.

Offline

#6 July 3 2015

AVOlio
Member

Re: Connect two PCs with Lan (using 2 routers).

I seriously doubt it.
I am with Ogero, and as you know, ogero is 99% of the time stable speed and stable ping.
I cant even ping google.com now while the ethernet connection between the two routers is on, request timed out.
And when i unplug the cable from my router,my pc ceases to have internet connection at all.
What i think is happening is that they are also sharing internet connection,which i dont want!

Offline

#7 July 3 2015

ironman
Member

Re: Connect two PCs with Lan (using 2 routers).

Bro, each router has a different internet connection, and now since you only have 1 DHCP server, you are using only one of the connections (don't know which one), in order to specify which connection to use, you should set your default Gateway (on the PC) and set it to Router 1 (if you want the connection connected at Router 1) and Router 2 (if you want the connection arriving to Router 2)

I assume your default gateway is set the connection from the cable provider (not Ogero) this is why you are facing instability.

Offline

#8 July 3 2015

AVOlio
Member

Re: Connect two PCs with Lan (using 2 routers).

Yes Yes, i got it, thanks man.
The first time i did not do that, i just turned off DHCP on the second router, and changed its Lan ip within the first ones range.
But i didnt set the gateways to each IPs
So went to the properties of the Connection and changed the IP manually in IPv4 settings, on each computer.

Question though, now that the PCs are set by ethernet to use router 1 and router 2 Internet connection seperately, what about Wifi?
If for example Laptops/smartphones etc... are connected to wifi on any of the router (1 or 2) will it use the internet of just 1 or 2?
Or do i have to also set up some settings manually?

Edit: Another question,
Why is the File transfer speed between the two PC's kind of slow, like from 8-11MB/s. And sometimes lower.
Shouldn't it be like 100MB/s?

Last edited by AVOlio (July 3 2015)

Offline

#9 July 3 2015

ironman
Member

Re: Connect two PCs with Lan (using 2 routers).

Concerning Smartphones, the thing is that you had 2 Routers right ?

Let's say Router 1 is Ogero
Router 2 is from the Local Provider

If Router 1 has DHCP ON that means that the default connection (if you don't change gateways) will be Ogero
and Vice Versa, if Router 2 has DHCP on and Router 1 has it OFF, that means that the default connection if you don't change anything will be Router2's connection.

This is the thing.

Concerning transfer speeds, it is 10 MBps because it seems that the cable you connected between those 2 routers is a 100 Mbps cable (Cat5) OR your ports or one of your 2 ports is a 100Mbps port

Offline

#10 July 3 2015

AVOlio
Member

Re: Connect two PCs with Lan (using 2 routers).

Thanks.
So it means, that every time a new smartphone connects either to my Ogero Wifi or Local internet Wifi, i have to set up the default gateway to each owns gateway in order to acquire each owns connection?
(To make it easier for me, i set up the default gateway of Router1 (Ogero indeed) to 1.1 and the gateway of router2 (local internet) to 1.2).

What about the IP addresses, it doesn't matter what IP address each device acquires, right?

Offline

#11 July 3 2015

xAzarian
Member

Re: Connect two PCs with Lan (using 2 routers).

Just wondering , why not use hamachi to create a virtual network and play on lan. Ive been using it for like a year to play age of empires 3 with some friends. It even works even when you're not on the same wifi.

Offline

#12 July 4 2015

ironman
Member

Re: Connect two PCs with Lan (using 2 routers).

Here we go,

If Ogero's DHCP server is on, the default gateway given to clients would be Ogero's Router (192.168.1.1)
If the local provider's DHCP Server is On, the default gateway given to clients would be 192.168.1.2

IF you want the default connection to be Ogero, activate the DHCP server on Ogero's  router and turn it off on the second
and vice versa.

Offline

#13 July 4 2015

AVOlio
Member

Re: Connect two PCs with Lan (using 2 routers).

Man that's it, i don't want that.
I want each device when connected to any router, to use that same router's connection."
So say if they are connected to Router1, i want them to be connected to Ogero Internet.
If they are connected to Router2, i want them to be connected to the cable internet.

By the way, even when i changed Router1's default gateway to 1.1, when i connect wifi devices to that router, the devices still captured the old gateway of that router which is 1.254 .
So i changed it back to 1.254 because one Nokia lumia phone, i couldn't modify the network connections on it and change it to 1.1 .

Offline

#14 July 5 2015

rolf
Member

Re: Connect two PCs with Lan (using 2 routers).

AVOlio wrote:

Why is the File transfer speed between the two PC's kind of slow, like from 8-11MB/s. And sometimes lower.
Shouldn't it be like 100MB/s?


100 MegaBits per second will give you transfer speed of about 8-10 MegaBytes per second.
1 byte = 8 bits and overhead for TCP/IP and probably other stuff is maybe 20% give or take.
So 100/8 = 12.5, remove 20% and that's what you get. That's not bad performance.

Offline

#15 July 6 2015

ironman
Member

Re: Connect two PCs with Lan (using 2 routers).

AVOlio wrote:

Man that's it, i don't want that.
I want each device when connected to any router, to use that same router's connection."
So say if they are connected to Router1, i want them to be connected to Ogero Internet.
If they are connected to Router2, i want them to be connected to the cable internet.

By the way, even when i changed Router1's default gateway to 1.1, when i connect wifi devices to that router, the devices still captured the old gateway of that router which is 1.254 .
So i changed it back to 1.254 because one Nokia lumia phone, i couldn't modify the network connections on it and change it to 1.1 .

You can't do that if you want to connect both routers together via a cable.

Offline

#16 July 8 2015

TheStunMan
Member

Re: Connect two PCs with Lan (using 2 routers).

Can you do a little sketch over paint to get a brighter idea how all devices are connected together ?

Offline

#17 July 8 2015

AVOlio
Member

Re: Connect two PCs with Lan (using 2 routers).

Here's a sketch.
th_Screenshot_2015-07-08-13-33-03_zpsrvpmbzwf.png

Offline

#18 July 8 2015

TheJackal
Member

Re: Connect two PCs with Lan (using 2 routers).

Things got nasty in here ...i know i'm late ,but let me give a tips of how to do it via wifi   ok .... let's roll on ....

1 - You have two routers , Determine if your equipment is compatible that's very important for the performance  "you don't put ice on fire .... says me :)"

2- Determine  which router is primary (off course the new one with the amazing features ) and which is the secondary

3- place both routers near computer & log in the first router , Plug the primary router into the modem and then connect your computer to it . Your primary router will be configured as you normally would for a wireless network. Make note of the router's IP address, DHCP range, and subnet mask that one is done .

4- Now log in to secondary router & Open the configuration page on it & go to Wireless then Enable Bridge Mode. Select "Bridge Mode" or "Repeater Mode" from the "Network Mode", "Wireless Mode" or "Connection Type"

5- Specify the secondary router's IP address. Enter in an IP address within the primary router's range. For example, if the primary router's IP address is 192.168.1.1, enter 192.168.1.50 or something else inside the DHCP range of the primary router.

6- Enter a unique SSID for both routers Kitchen , Living Room (i know that's kind of stupid).

7- Ensure that the security is the same type (WEP, WPA, WPA2) and the same password.

8- you're done  :)


all regards my friend

Last edited by TheJackal (July 8 2015)

Offline

#19 July 8 2015

TheStunMan
Member

Re: Connect two PCs with Lan (using 2 routers).

You need to assign a vlan to the connected ports between the routers. Google more about vlans (assuming your routers support vlan configurations)

Offline

#20 July 9 2015

Aly
Member

Re: Connect two PCs with Lan (using 2 routers).

Are those routers R1 and R2 generic DSL routers like Thompson, edimax, dlink ? if yes your setup wont work.
If R1 and R2 are Cisco routers for instance it will work you only have to connect them and assign a small subnet between the routers and modify the routing table to allow traffic flow from one network to the other.

If you want a cheap solution, you can buy an 8 port switch and do the following:
t8b3u1.png

Last edited by Aly (July 9 2015)

Offline

#21 July 9 2015

mhamadhdb
Member

Re: Connect two PCs with Lan (using 2 routers).

If those are not thomson or tplink or whatever you can put a filter on the ethernet interface that is connected to the other router to drop dhcp protocol or if you want more secure and just for gaming and not to share internet if they put static ip you should make a rule that accept all packets from src address (the other computer) and drop any other traffic

Offline

#22 February 26 2016

dduetto
Member

Re: Connect two PCs with Lan (using 2 routers).

1st Scenario

Connect both PC to Thomson TG585 Router via Wireless or Cable

2nd Scenario

Connect both PC to Tenda 11N Router via Wireless or Cable

Offline

Board footer