PDA

View Full Version : Firewalls and opening ports



Brooski
12-13-2003, 01:24 PM
When opening ports on a firewall, is there any way to tell if some service is already using that port for something, and if so, can two services use the same port? When trying to set up a Dominions 2 server, I seem to be able to open a port and have some people connect to a game, while others cannot. I assume this is a problem on their end, but I was wondering if it means that a service of theirs is already using that port? Is there a list of TCP/UDP ports that are rarely used and could be safely opened for m/p gaming? And what is the difference between TCP and UDP, anyway?

Idar Thorvaldsen
12-13-2003, 01:39 PM
When opening ports on a firewall, is there any way to tell if some service is already using that port for something, and if so, can two services use the same port? When trying to set up a Dominions 2 server, I seem to be able to open a port and have some people connect to a game, while others cannot. I assume this is a problem on their end, but I was wondering if it means that a service of theirs is already using that port? Is there a list of TCP/UDP ports that are rarely used and could be safely opened for m/p gaming? And what is the difference between TCP and UDP, anyway?

What port you use shouldn't be relevant for what port they are using; they can use whatever port they want on their machines.
Here (www.thedigerati.us/info/tcp_ipports.htm)is a list of commonly used ports. Basically, anything over 1024 shouldn't be in use unless you're running some other net-using application on your machine.

TCP is reliable, UDP isn't, but it can be a bit faster.

What firewall are you using?

Rywill
12-13-2003, 01:41 PM
I have a Linksys router, which I believe comes with a firewall, and I can't connect to Bruce's game. We've tried three different ports, no luck. I tried forwarding those ports to the static LAN IP that I've assigned to my computer, and also disabled something called "Block WAN request" or something similar, but no dice. I'm not running any antivirus stuff or anything like that (I mean, I have AVG, but it just scans and updates once a month, not everything that goes in or out). Anyone who can assist, I'd really appreciate it.

Brooski
12-13-2003, 01:50 PM
I have a D-Link router; no software firewall. The weird thing is that some people can get into the game but some cannot, and some players can connect to one port but not another. For example, I have two ports open: some people can get into both, some people can get into one but not the other, and some people cannot get into any of them.


What port you use shouldn't be relevant for what port they are using; they can use whatever port they want on their machines.
Damn, that seemed like such a good theory. Any ideas?

Jason McCullough
12-13-2003, 02:48 PM
If anyone at all can connect to you nothing needs changing on your end, Bruce.

Rywill, is the XP firewall on? Failing that, just disable them completely and then selectively turn ports back on.

XPav
12-13-2003, 03:16 PM
At a command prompt, do a

netstat -a -o

You can get a list of all open TCP and UDP ports, their source & destination, and owning process number. Its a hell of a lof of information though. I would recommend closing every app possible.

Rywill
12-13-2003, 03:39 PM
Rywill, is the XP firewall on? Failing that, just disable them completely and then selectively turn ports back on.
I'm not using the XP firewall. I don't understand the second sentence of your suggestion. Disable what completely? My ports? How would I do that?

Jason McCullough
12-13-2003, 04:07 PM
Oh, I meant open up every port on the router.

Rywill
12-13-2003, 04:10 PM
Sorry to be a complete and utter newbie, but it just occurred to me that I may be proceeding under a misconception. When you say to "open" a port, you mean to forward it to the static LAN IP that's assigned to my computer, right?

Jason McCullough
12-13-2003, 04:36 PM
Oh, I thought you meant you just had a router that blocked ports. If you're doing NAT - you have some sort of goofy 192* IP address on your computer - then yeah, you'll probably need to forward whatever ports dominions 2 connects on back to your computer.

Vic Davis
12-13-2003, 04:39 PM
It's funny but I can logon to the first game and pick a nation. If I pick one then it asks for a password. I'm not in that game so I don't have one. But if I go to the port that the #2 game is at then all I get is a "Waiting for Game Info" box. Anybody got any ideas. I did a clean install and tried again but no luck.

Vic

Rywill
12-13-2003, 04:40 PM
I do have that goofy 192 address, so I guess I am doing NAT. It sounds like the problem may be that although I know the port on Bruce's computer, I don't know the port on my computer (I take it they're not necessarily the same).

Peter Frazier
12-13-2003, 04:46 PM
I just have an ADSL modem, no software firewall operating and I can't connect to him. I also took off the XP firewall.

Idar Thorvaldsen
12-13-2003, 05:00 PM
Oh, I thought you meant you just had a router that blocked ports. If you're doing NAT - you have some sort of goofy 192* IP address on your computer - then yeah, you'll probably need to forward whatever ports dominions 2 connects on back to your computer.

Shouldn't have to do that when doing NAT. No router I've ever seen needs explicit port forwarding for outgoing connections, just for incoming. The Linksys router I'm using now doesn't have to, at any rate.


It's funny but I can logon to the first game and pick a nation. If I pick one then it asks for a password. I'm not in that game so I don't have one. But if I go to the port that the #2 game is at then all I get is a "Waiting for Game Info" box. Anybody got any ideas. I did a clean install and tried again but no luck.

Vic

I think that means you're connected to the server, though; at least from what I can gather from experimenting with the demo. I get a "connecting to server" message when trying to connect to a random port on another machine (ie. not reaching a server). You're probably past the router, so you're reaching the server at least once.


I do have that goofy 192 address, so I guess I am doing NAT. It sounds like the problem may be that although I know the port on Bruce's computer, I don't know the port on my computer (I take it they're not necessarily the same).

You shouldn't have to, though, since you're connecting to him.

What exactly is happening to everyone when they try to connect; that is, what message(s) are you getting?

Vic Davis
12-13-2003, 05:24 PM
I'm getting a "Waiting for Game Info" message but it never goes any further than that. I can connect but I just can't seem to get into the game on this particular port.

Jason McCullough
12-13-2003, 07:23 PM
Ah, ok. Rywill, your NAT setup is probably either blocking the outgoing connection to port 1249834, or whatever it is Dominions 2 uses. It's also possible that for some crazy reason Bruce's machine, the server, tries to open another connection back to your machine, and that's what's hosing it.

You'd think there'd be a dominions 2 support page *somewhere*, but I can't find it.

Stuff like this is one of the reasons NAT is a sin before God and Man.

Johan O
12-14-2003, 04:17 AM
Some of the shrapnel beta people had trouble connecting to a TCP/IP game we set up. It turned out that their problem was that they tried to use numpad, attempts to use the numpad when entering port or IP do not show in the box but still affects it. Try to press backspace for a while to ensure that the numpad input have been removed and then enter the port and IP using only the left hand numbers. Perhaps this is not Vic and Rywills problem but it's worth a shot anyway.