PvPGN Installation Guide
Minimal Requirements
CPU
1 core
PvPGN is not multithreaded, but additional cores may be useful to handle database or web server)
RAM
256MB (required value for the compilation); a running server without users use ~3MB
OS
Windows / Linux (theoretically on any POSIX compatible system)
PvPGN was designed for x86 systems. It will work on x64 but it will not utilize all features of 64 bit processor.
Installation on Windows
a) Download the latest automated build from the web site.
b) Use Magic Builder to build PvPGN from sources accordingly to your SQL database version.
A difference from PvPGN.exe and PvPGNConsole.exe is the first is better for debugging, because you see in real time
what is happening, and the second is for production, because it does not consume additional resources for graphical interface.
PvPGNConsole.exe -s install PvPGNConsole.exe -s uninstall
Installation on Linux (Debian)
1) Install required dependencies
sudo apt-get -y install build-essential clang libc++-dev git cmake zlib1g-dev liblua5.1-0-dev libmysql++-dev2) Download the latest source code and unpack archive
wget https://github.com/pvpgn/pvpgn-server/archive/master.tar.gz tar xf master.tar.gz3) Switch to the directory with source and create a new directory "build"
cd pvpgn-server-master mkdir build cd build4) Configure and compile
cmake -D WITH_MYSQL=true -D WITH_LUA=true ../ make && make install5) Run
/usr/local/sbin/bnetdConfigs are in /usr/local/etc/pvpgn/
Logs, files, scripts are in /usr/local/var/pvpgn/
Configuration
By default PvPGN is ready to work with default configuration and it allows to connect with all game clients.
Below are general options in bnetd.conf that you should pay attention for to run a server in production.
- storage_path (SQL mode is preferred with any supported database)
- loglevels = "fatal,error,warn,info" (for detailed info you may need to add "debug,trace")
- allowed_clients = "w3xp" (allow only specified game cliens)
- allow_bad_version = false (do not allow bad or unknown version)
- allow_unknown_version = false
- new_accounts = false (do not allow registration inside a game, accounts should be created from a web interface)
- disc_is_loss = true
- ladder_games = "melee,oneonone" (these games will be count as ladder, also disc_in_loss will be count only for them)
- passfail_count = 5 (protect from bruteforce)
- location, description, url, contact_name, contact_email (specify your server details for trackers)
- servername (uncomment and change)
- max_connections = 1000 (how much users your server can withstand)
- max_concurrent_logins = 1 (only one login per account)
- max_conns_per_IP = 5 (sometimes users play with shared IP from public places, so may be it can be increased)
- ircaddrs and telnetaddrs (should be commented unless you host WWOL, but telnet should be disabled anyway
or allowed only for several authorized bot accounts) - XML_output_ladder = true (var/ladders/*.xml)
- XML_output_ladder = true (var/status/server.xml)
PvPGN
- i18n - directory with localized texts, there is "enUS" locale in root of the directory
- bnetd.conf - the main config
- ad.json - banners
- address_translation.conf - rules for network translation, can be only useful if there are players from different subnets and you want that all can play on your server
- bnalias.conf - aliases for chat commands
- bnban.conf - if you wanna deny connection to a server by IP or range IPs
- bnissue.txt - welcome text for chat/telnet connection (telnet is not secure, so it's recommended to set allowed_clients to something except "all" in bnetd.conf)
- bnetd_default_user.plain - default user template for PLAIN mode
- sql_DB_layout.conf - database structure for SQL mode, creates on first server start
- channel.conf - configuration for permanent channels
- command_groups.conf - define groups for users who can use chat commands
- icons.conf - custom user icons in chat, custom output for /stats
- versioncheck.conf - predefined game clients version info, works only if skip_versioncheck = false and allow_bad_version = false (in bnetd.conf)
- autoupdate.conf - the rules that determine how to autoupdate a game client, works together with versioncheck.conf
- supportfile.conf - list of available files that clients can download, that located in "files" directory
- topics.conf - predefined topics for special channels
Warcraft 3
- anongame_infos.conf - Anonymous Matchmaking settings (button with sword), URLs to profile/tournament/clan buttons
- tournament.conf - tournaments configuration
- bnmaps.conf - predefined map list for different gametypes
- bnxpcalc.conf - this file is used to compute the XP points gained/lost by Warcraft III
- bnxplevel.conf - this file is used mainly for computing the level of players and teams on W3 Anonymous Matchmaking
Specific options in bnetd.conf
- w3routeaddr
- war3_ladder_update_secs
Starcraft, Warcraft 2
Specific options in bnetd.conf
- disc_is_loss
- ladder_games
- ladder_prefix
Diablo 2
- d2cs.conf
- d2dbs.conf
- realm.conf
Specific options in bnetd.conf
- d2cs_version
- allow_d2cs_setname
- report_diablo_games
Westwood Online
- bnmaps.conf - predefined map list
Specific options in bnetd.conf
- woltimezone
- wollongitude
- wollatitude
- wol_autoupdate_serverhost
- wol_autoupdate_username
- wol_autoupdate_password
Lua Scripting
Lua is enabled if PvPGN was compiled with cmake flag WITH_LUA=true.All the *.lua scripts from /var/lua/ and subdirectories are loaded at once when server starts.
Note: Lua is experimental and unfinished. It works and you can successfully use it, but it may cause performance issues with lots of connections (hundreds or may be thousands, it depends on used scripts).
More info can be found on forums, for example here.