Friend cannot connect to my TF2 server

Friend cannot connect to my TF2 server - Cheerful Asian male friends in casual wear with dark hair smiling while sitting on stone stairs on street in city

Yesterday, one of my friends started playing TF2 for the first time, so I thought it would be a good idea if we played a game against bots together before we play the mayhem that is multiplayer. So, I decided to set up a server and told her to connect to it. Here is the exact process that I did:

  • Port-forwarded ports 27000 through 27040
  • Clicked the "Create server" button
  • Set up a capture point server on the map Gorge with a hostname and password "new"
  • When loaded into the server, I typed "ip <my_external_ip>:27015" into the console
  • I also entered the command sv_lan 0
  • I then told her to enter password new and connect <my_external_ip>:27015

Every time we tried, one of two things happened:

  1. Her client sent an error message saying "Connection failed after 4 retries"
  2. Her client sent an error message saying "The server is not responding"

She can connect to normal servers fine, and so can I. What am I doing wrong and why can't she connect?



Best Answer

You might want to leave the port part off of the ip command. The hostip command may also work, but I've noticed it's set to a random value on my dedicated server.

TF2 uses UDP ports primarily. Specifically, the server listens on the following ports by default:

  • UDP 27015 - Listens to connections from clients here. Changed with -port on the server command-line Also doubles as the port the server uses to talk to the master server.
  • UDP 27005 - This is the port clients actually connect to once the initial connection is finished. Changed with -clientport on the server command-line. Not sure if it has a Create Server equivalent.
  • UDP 27020 - Used for SourceTV. The server will always bind this port unless you use the command-line switch -nohltv, even if SourcTV is off (which it is by default). Can be set using +tv_port on the command-line. Not sure if it has a Create Server equivalent.
  • TCP 27015 - Used for the Remote Console (rcon) support for administrative tasks (i.e. remotely kicking/banning players). Not needed in your current setup.
  • UDP 26901 - Used to communicate with the Steam backend. If you don't have this port open, your server will have issues with items and achievements... and possibly authentication stuff in general. It's settable using -steamport from the command-line, but it always adds 1 to it for unknown reasons (26900 is the default).

The Easy Way

Having said all this, it might not be a bad idea to just find a server that's already running bots. From the in-game server browser, you'll have to turn off the simple mode checkbox to see this. The Bots column will have a little gear symbol in it for servers that are running bots. The player count will be the number of players not counting bots.

Important note: The Steam server browser will include bots in the player count. This is the primary difference between the Steam and TF2 server browsers.

It also couldn't hurt to join a Valve server using the QuickPlay system. While not always the case, Valve servers tend to have newer players on them and you might face off against people who are around the same experience level you are.

Another good resource for new TF2 players is probably Reddit's /r/newtotf2 subreddit... it's a fork of Reddit's /r/tf2 specifically aimed at players new to the game. Sometimes people on there give free items to new players. Having said that, TF2's stock items include some of the most well balanced items in the game (Minigun, Scattergun, StickyBomb Launcher, and Rocket Launcher to name a few)... don't just assume unlocked items are better.




Pictures about "Friend cannot connect to my TF2 server"

Friend cannot connect to my TF2 server - Low angle of various connectors and USB cables placed on shelf with storage engineer inscription
Friend cannot connect to my TF2 server - Couple hugging and using smartphone near sea on sunset
Friend cannot connect to my TF2 server - Cheerful young diverse female friends laughing while watching funny video on smartphone during coffee break in cozy cafe



How do you let your friends join your tf2 server?

Check if internet is working, restart tf2, restart your comp, restart your router, check integrity of game files of tf2, reinstall tf2. In that order. Before you reinstall tf2, check if Mvm, comp, and community servers are working. Before you reinstall tf2, check if Mvm, comp, and community servers are working.

Can you use a VPN on tf2?

Any reasons why its doing it? He probably changed his friends' setting to "Offline". Basically click "View Friends List", then click the little arrow to the right of your name and click "Offline". Odds are that's what happened.



TF2 - How To Join A Server With Your Friends (Updated)




Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.

Images: Allan Mas, Brett Sayles, ROMAN ODINTSOV, Ketut Subiyanto