GUIDE: Dota 2 Dedicated Server on Linux (from Scratch)
Note: it is now possible to run a Dota 2 dedicated server on Linux without WINE. This article is kept purely for archival purposes, though it should still work.
It is entirely possible to, using the Windows Alien Swarm SRCDS and WINE, run a Dedicated Server for Dota 2 on a Linux machine. Obtaining the required software is, however, a little tricky, so here is a guide.
- Install WINE 1.2.3 by following the instructions for your distribution on this page. (The latest version, 1.7, does not work. Other versions may work, but 1.2.3 definitely works)
On Ubuntu, open a terminal and run:- sudo apt-get add-repository ppa:ubuntu-wine/ppa
- sudo apt-get install wine1.2
- Download hldsupdatetool.bin from the Valve server and save it into a folder.
- Open a terminal and run:
- cd /path/to/hldsupdatetool
- chmod +x ./hldsupdatetool.bin
- ./hldsupdatetool.bin
- ./steam -command update -game alienswarm -dir .
- Grab a coffee. This could take a while.
- Obtain a Windows copy of Dota 2, by downloading Dota 2 on a Windows machine, and copying the C:\Program Files\Steam\SteamApps\common\dota 2 beta folder to the Linux machine, such that dota.exe resides at /path/to/dota/dota.exe.
- Copy srcds.exe from /path/to/hldsupdatetool/srcds.exe to /path/to/dota/srcds.exe.
- Follow the instructions in the Installing Metamod:Source section below.
- Open a terminal and run:
- cd /path/to/dota
- wine srcds -console -game dota -insecure +maxplayers 10 +map dota
- Ta-da! If everything went correctly, a console window should open up (and stay opened up) and you should be able to connect to the server from Dota as per a normal dedicated server!
- Use Steam to set the launch options of Dota 2 to -console.
- Run Dota 2. Once loaded, a console window should be visible. Enter in connect localhost, substituting ‘localhost’ for the IP address of the dedicated server.
Installing Metamod:Source
(Mirrored from the Sourcemod.js GitHub wiki, via this forum post)
Note: these instructions work for Windows as well as Linux (but only on a Windows copy of Dota!).
- Navigate to the download page for Metamod:Source, and download the Windows version of Metamod (at the time of writing, mmsource-1.10.0-windows.zip). Extract (merging if necessary) the contents of the archive into the /path/to/dota/dota/ directory, such that the /path/to/dota/dota/addons/ folder is created.
- Download the latest version of Dota 2 Fixups. Extract (merging if necessary) the contents of the archive into the /path/to/dota/dota/ directory, such that the /path/to/dota/dota/addons/d2fixups/ folder is created.
- Modify the /path/to/dota/dota/gameinfo.txt file, and before the Game |gameinfo_path| line, add a GameBin |gameinfo_path|addons\metamod\bin line.
Labels: defense of the ancients, dota, gaming, guide, linux, steam, wine