Left 4 Dead 2 reads left4dead2/cfg/server.cfg every time it loads a map. The starting campaign and mode are launch values.
1. Edit server.cfg
- Stop the server in the Game Panel.
- Open the Files tab and browse to
left4dead2/cfg. - Open
server.cfg, or create it if it does not exist.
| Command | What it does |
|---|---|
hostname | The name in the server browser. |
sv_password | Password to join. Empty means open. |
rcon_password | Password for remote admin commands. |
sv_lan | Must be 0 for an internet server. |
sv_gametypes | The modes the server accepts, for example coop,versus,survival. |
sv_search_key | A private matchmaking key so your lobby lands here. |
sv_allow_lobby_connect_from_steam | Set to 1 so lobbies can reach the server. |
sv_alltalk | Lets both teams hear each other. |
sv_maxplayers | Player slots beyond the default four in co-op. |
Values with spaces go in quotation marks.
2. The starting campaign
- The map the server boots into is a launch value, set on the Startup page of your server. That page is not linked in the sidebar, so add
/startupto the end of your server's panel address. - Map names are the campaign chapter, for example
c1m1_hotelfor Dead Center. - To change campaign now, run
changelevel c2m1_highwayin the Console tab in the panel.
3. Player slots above four
sv_maxplayers raises the slot count, but the game is designed around four survivors and extra players in co-op need a plugin to be given a character. Versus already uses eight. Raise the number only if you have the plugin to match, or players will connect and sit as spectators.
4. Apply the changes
- Save the file.
- Start the server, or run
exec server.cfgin the console to reload without a restart. - Run
statusto confirm the hostname and map.
5. If a setting is ignored
- Check the spelling. The console silently skips unknown commands.
- The mode resets some values on each map load. Put those in the mode's own config file.
- Run
exec server.cfgby hand to see the errors printed.
Open a ticket from Support in the Client Area if a setting will not hold.





