How UPnP caused 'sync' issues in our multiplayer games.

Been working on getting multiplayer games working with a friend.  I have worked in IT networking and firewalls for years now.  I've had no problem getting my stuff to work.  However, with one friend, our games always get out of sync.  I believe I have found the cause and wanted to share what I found in case anyone else is having the same issue.

Here is a picture of the network connection and all of the devices betwween the two PC's.

Device A
PC running Windows XP Pro, Windows firewall allowing ports, UPnP disabled.

Device B
SOHO router (Linksys, Netgear, Dlink, Belkin, etc) performing NAT and Firewall.  Game ports allowed and forwarded to PC A.

Device C
Cable modem.  No NAT, no firewall

Device D
DSL router.  Only router, no NAT, no firewall

Device E
Dedicated firewall performing NAT and firewall.  Ports forwarded to PC F and access allowed for game.

Device F
PC running Windows XP Pro, Windows firewall turned off, UPnP disabled.

 

This is the setup we were using and we would always experience game out of sync.  After working with my firend and looking closer, there *was* UPnP enabled on device B at my his house.  After disabling this, we are now able to complete an entire game with no sync issues.

Side note - Monk's document for getting Sins to work is very good.  Kudos for him giving back to the community.  I am attempting to also give back, even if it is only on 1 issue.

4,146 views 3 replies
Reply #1 Top

Okay, that picture did not post very clearly.  I will see if I can get one that is more readable.

Reply #2 Top

that's interesting, but how do you think UPnP could have caused it, and do you think it maybe the specific to that router's firmware, or a problem with the protocol itself?

Reply #3 Top

I know the router in question is a little older and probably on the cheaper side of things.  All I know is that setting is the only thing that was changed from out of sync and a complete game.  Since it is only 1 confirmed complete game, more testing (playing) is probably required.

We played many games before but it always ended in out of sync game.  That was done with Hamachi, Direct Connect and on Ironclad Online.  All ended out of sync.

But to answer your question about why I believe it is UPnP, even in Monk's document, he confirms that if you manually setup the port forwarding, then you need to disable UPnP everywhere. I was just showing that having it on in just one place also causes issues. 

Which only makes sense.  If UPnP is involved, it is handling ports.  If UPnP is rewriting ports, the game will not work.  We already know that the game is very specific about what ports it requires.  That was the whole point for the static port forwarding on the firewall(s).