A Hong Kong VPS game server gives players across mainland China, Taiwan, Hong Kong, and Southeast Asia some of the lowest ping numbers available from any single hosting location in the world. With CN2 GIA routing, players in Guangzhou connect at under 15 ms — a level of responsiveness that shared or cloud-managed game hosting services simply cannot match from non-local infrastructure.
This guide covers setting up three of the most popular self-hosted game servers on a Hong Kong VPS: Minecraft Java Edition, Counter-Strike 2 (CS2), and Palworld. The server hardening and network optimisation steps apply universally regardless of which game you are hosting.
Choosing the Right VPS Spec for Game Hosting
Game servers are unusual among server workloads in that they are often single-threaded and clock-speed sensitive rather than benefiting from many CPU cores. A 4 vCPU VPS at 3.5 GHz will outperform an 8 vCPU VPS at 2.2 GHz for most game server applications.
| Game | Min. vCPU | Min. RAM | Storage | Players Supported |
|---|---|---|---|---|
| Minecraft Java (vanilla) | 2 vCPU | 2 GB | 20 GB NVMe | Up to 20 |
| Minecraft Java (modded) | 4 vCPU | 6–8 GB | 40 GB NVMe | Up to 30 |
| Counter-Strike 2 | 4 vCPU | 4 GB | 30 GB NVMe | 10–16 players |
| Palworld | 4 vCPU | 8–16 GB | 40 GB NVMe | Up to 32 |
| Terraria / Valheim | 2 vCPU | 2–4 GB | 20 GB NVMe | Up to 20 |
All game server deployments benefit from NVMe SSD storage — fast chunk loading in Minecraft, rapid map loading in CS2, and world state persistence in survival games all create random I/O patterns where NVMe’s low latency makes a visible difference to in-game experience.
Browse Server.HK’s Hong Kong VPS plans for KVM virtualisation with NVMe SSD and CN2 GIA routing — the right foundation for Asia-Pacific game server hosting.
Initial Server Setup (All Games)
These steps apply regardless of which game server you are running. Connect to your VPS:
ssh root@YOUR_VPS_IPUpdate the system:
apt update && apt upgrade -yCreate a dedicated non-root user for running game server processes:
adduser gameserver
usermod -aG sudo gameserver
su - gameserverInstall essential utilities:
sudo apt install -y wget curl screen ufw htopscreen is critical for game servers — it allows the server process to keep running after you disconnect your SSH session. We will use it throughout this guide.
Firewall Configuration (All Games)
Configure UFW before opening any game-specific ports:
sudo ufw allow OpenSSH
sudo ufw enableOpen game-specific ports as needed (detailed in each section below). Always restrict SSH to your own IP if possible:
sudo ufw allow from YOUR_HOME_IP to any port 22
sudo ufw delete allow OpenSSHPart 1: Minecraft Java Edition Server
Install Java
Minecraft Java Edition requires Java 21 for versions 1.20.5 and above:
sudo apt install -y openjdk-21-jre-headless
java -versionConfirm the output shows openjdk version "21" or later.
Download and configure the server
mkdir -p /home/gameserver/minecraft
cd /home/gameserver/minecraftDownload the latest Minecraft server JAR from Mojang (replace the URL with the current version from minecraft.net/download/server):
wget https://piston-data.mojang.com/v1/objects/[CURRENT_JAR_URL]/server.jarRun it once to generate configuration files and accept the EULA:
java -Xmx1024M -Xms1024M -jar server.jar nogui
echo "eula=true" > eula.txtOptimise server.properties for Asia-Pacific players
nano server.propertiesKey settings to configure:
# Network
server-port=25565
online-mode=true
# Performance
view-distance=8
simulation-distance=6
network-compression-threshold=256
# Player limits
max-players=20
max-tick-time=60000
# World
level-type=minecraft:normal
spawn-protection=16For modded servers or Paper/Spigot (recommended over vanilla for performance), replace view-distance=8 with view-distance=6 and enable use-native-transport=true for Netty optimisations.
Create a startup script with optimised JVM flags
nano /home/gameserver/minecraft/start.sh#!/bin/bash
java -Xmx4G -Xms2G \
-XX:+UseG1GC \
-XX:+ParallelRefProcEnabled \
-XX:MaxGCPauseMillis=200 \
-XX:+UnlockExperimentalVMOptions \
-XX:+DisableExplicitGC \
-XX:+AlwaysPreTouch \
-XX:G1NewSizePercent=30 \
-XX:G1MaxNewSizePercent=40 \
-XX:G1HeapRegionSize=8M \
-XX:G1ReservePercent=20 \
-XX:G1HeapWastePercent=5 \
-XX:G1MixedGCCountTarget=4 \
-XX:InitiatingHeapOccupancyPercent=15 \
-XX:G1MixedGCLiveThresholdPercent=90 \
-XX:G1RSetUpdatingPauseTimePercent=5 \
-XX:SurvivorRatio=32 \
-XX:+PerfDisableSharedMem \
-XX:MaxTenuringThreshold=1 \
-jar server.jar noguiThese JVM flags (known as the Aikar flags) are the standard optimisation set for Minecraft Java servers — they tune the G1 garbage collector to minimise lag spikes during chunk loading and entity processing.
chmod +x start.shOpen the Minecraft firewall port
sudo ufw allow 25565/tcp
sudo ufw allow 25565/udpStart the server in a screen session
screen -S minecraft
cd /home/gameserver/minecraft
./start.shDetach from the screen session with Ctrl+A then D. The server continues running. Reattach at any time with:
screen -r minecraftExpected latency from Asia
Players connecting to your Hong Kong VPS Minecraft server via CN2 GIA routing should expect:
- South China (Guangdong): 5–15 ms
- Shanghai / East China: 20–35 ms
- Taiwan: 20–30 ms
- Southeast Asia: 30–70 ms
Part 2: Counter-Strike 2 (CS2) Dedicated Server
Install SteamCMD
CS2 requires SteamCMD to download and update server files:
sudo apt install -y lib32gcc-s1
mkdir -p /home/gameserver/steamcmd
cd /home/gameserver/steamcmd
wget https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz
tar -xzf steamcmd_linux.tar.gzDownload CS2 server files
mkdir -p /home/gameserver/cs2
./steamcmd.sh +force_install_dir /home/gameserver/cs2 \
+login anonymous \
+app_update 730 validate \
+quitThis downloads approximately 30 GB of game files. Depending on your VPS bandwidth, this takes 10–30 minutes. The anonymous login works for CS2 server files — no Steam account required.
Configure the server
mkdir -p /home/gameserver/cs2/game/csgo/cfg
nano /home/gameserver/cs2/game/csgo/cfg/server.cfg// Server identity
hostname "Your Server Name - HK"
sv_password ""
// Networking - optimised for Asia-Pacific
sv_minrate 128000
sv_maxrate 786432
sv_minupdaterate 64
sv_maxupdaterate 128
sv_mincmdrate 64
sv_maxcmdrate 128
sv_lan 0
// Game settings
mp_autoteambalance 1
mp_limitteams 1
mp_friendlyfire 0
sv_cheats 0
// Round settings
mp_maxrounds 30
mp_round_restart_delay 5
mp_freezetime 15
mp_buytime 20
// Tickrate (128 tick for competitive)
sv_minupdaterate 128
sv_maxupdaterate 128Create the CS2 startup script
nano /home/gameserver/cs2/start_cs2.sh#!/bin/bash
cd /home/gameserver/cs2
./game/bin/linuxsteamrt64/cs2 \
-dedicated \
-console \
-usercon \
+game_type 0 \
+game_mode 1 \
+mapgroup mg_active \
+map de_dust2 \
+sv_setsteamaccount YOUR_GSLT_TOKEN \
-port 27015 \
-tickrate 128Replace YOUR_GSLT_TOKEN with a Game Server Login Token from steamcommunity.com/dev/managegameservers — required for public CS2 servers.
chmod +x /home/gameserver/cs2/start_cs2.shOpen CS2 firewall ports
sudo ufw allow 27015/tcp
sudo ufw allow 27015/udp
sudo ufw allow 27020/udp
sudo ufw allow 27005/udpStart the CS2 server
screen -S cs2
/home/gameserver/cs2/start_cs2.shDetach with Ctrl+A D. Players can connect using your VPS IP address and port 27015 in the CS2 console: connect YOUR_VPS_IP:27015
128-tick performance note
Running a 128-tick CS2 server requires consistent CPU performance. On a Hong Kong VPS with dedicated KVM virtualisation (as provided by Server.HK), 128-tick servers for 10-player matches run stably on 4 vCPU instances. Monitor CPU usage during peak play hours with htop to verify headroom.
Part 3: Palworld Dedicated Server
Palworld is one of the most RAM-intensive self-hosted game servers currently popular — allocate at least 8 GB RAM and preferably 16 GB for a stable 32-player server.
Install dependencies
sudo apt install -y lib32gcc-s1 steamcmdDownload Palworld server
mkdir -p /home/gameserver/palworld
steamcmd +force_install_dir /home/gameserver/palworld \
+login anonymous \
+app_update 2394010 validate \
+quitConfigure PalWorldSettings.ini
mkdir -p /home/gameserver/palworld/Pal/Saved/Config/LinuxServer
nano /home/gameserver/palworld/Pal/Saved/Config/LinuxServer/PalWorldSettings.ini[/Script/Pal.PalGameWorldSettings]
OptionSettings=(Difficulty=None,DayTimeSpeedRate=1.000000,NightTimeSpeedRate=1.000000,ExpRate=1.000000,PalCaptureRate=1.000000,PalSpawnNumRate=1.000000,PalDamageRateAttack=1.000000,PalDamageRateDefense=1.000000,PlayerDamageRateAttack=1.000000,PlayerDamageRateDefense=1.000000,PlayerStomachDecreaceRate=1.000000,PlayerStaminaDecreaceRate=1.000000,PlayerAutoHPRegeneRate=1.000000,PlayerAutoHpRegeneRateInSleep=1.000000,PalStomachDecreaceRate=1.000000,PalStaminaDecreaceRate=1.000000,PalAutoHPRegeneRate=1.000000,PalAutoHpRegeneRateInSleep=1.000000,BuildObjectDamageRate=1.000000,BuildObjectDeteriorationDamageRate=1.000000,CollectionDropRate=1.000000,CollectionObjectHpRate=1.000000,CollectionObjectRespawnSpeedRate=1.000000,EnemyDropItemRate=1.000000,DeathPenalty=All,bEnablePlayerToPlayerDamage=False,bEnableFriendlyFire=False,bEnableInvaderEnemy=True,bActiveUNKO=False,bEnableAimAssistPad=True,bEnableAimAssistKeyboard=False,DropItemMaxNum=3000,DropItemMaxNum_UNKO=100,BaseCampMaxNum=128,BaseCampWorkerMaxNum=15,DropItemAliveMaxHours=1.000000,bAutoResetGuildNoOnlinePlayers=False,AutoResetGuildTimeNoOnlinePlayers=72.000000,GuildPlayerMaxNum=20,PalEggDefaultHatchingTime=72.000000,WorkSpeedRate=1.000000,bIsMultiplay=True,bIsPvP=False,bCanPickupOtherGuildDeathPenaltyDrop=False,bEnableNonLoginPenalty=True,bEnableFastTravel=True,bIsStartLocationSelectByMap=True,bExistPlayerAfterLogout=False,bEnableDefenseOtherGuildPlayer=False,CoopPlayerMaxNum=4,ServerPlayerMaxNum=32,ServerName="Hong Kong Palworld Server",ServerDescription="Low latency Asia server",AdminPassword="YOUR_ADMIN_PASSWORD",ServerPassword="",PublicPort=8211,PublicIP="YOUR_VPS_IP",RCONEnabled=True,RCONPort=25575,Region="",bUseAuth=True,BanListURL="https://api.palworldgame.com/api/banlist.txt")Replace YOUR_ADMIN_PASSWORD with a strong password and YOUR_VPS_IP with your actual server IP.
Create startup script
nano /home/gameserver/palworld/start_palworld.sh#!/bin/bash
cd /home/gameserver/palworld
./PalServer.sh \
-port=8211 \
-players=32 \
EpicApp=PalServerchmod +x /home/gameserver/palworld/start_palworld.shOpen Palworld firewall ports
sudo ufw allow 8211/udp
sudo ufw allow 25575/tcpStart the server
screen -S palworld
/home/gameserver/palworld/start_palworld.shThe initial world generation takes 2–5 minutes on first launch. Players connect via the in-game server browser or directly using YOUR_VPS_IP:8211.
Network Optimisation for All Game Servers
Reduce network latency with kernel tuning
Add the following to /etc/sysctl.conf to optimise UDP performance — critical for game servers:
sudo nano /etc/sysctl.conf# Increase UDP buffer sizes for game server traffic
net.core.rmem_max=26214400
net.core.wmem_max=26214400
net.core.rmem_default=1048576
net.core.wmem_default=1048576
net.core.netdev_max_backlog=5000
# Reduce TCP latency
net.ipv4.tcp_fastopen=3
net.ipv4.tcp_slow_start_after_idle=0sudo sysctl -pEnable DDoS protection
Game servers are frequent DDoS targets, particularly competitive CS2 servers and popular Minecraft servers. Verify that your VPS provider’s network-level DDoS mitigation is active — Server.HK includes DDoS protection on its Hong Kong VPS infrastructure.
Add basic rate limiting at the UFW level for non-game ports:
sudo ufw limit sshMonitor server performance
Install and run htop during active play sessions to identify CPU and memory bottlenecks:
htopFor Minecraft specifically, use the /tps command in-game (requires Paper/Spigot) to monitor server tick rate — 20 TPS is optimal, and values below 18 TPS indicate the server is under load.
Keeping Game Servers Running After Reboot
Screen sessions do not survive server reboots. For production game servers, create a systemd service for automatic restart:
sudo nano /etc/systemd/system/minecraft.service[Unit]
Description=Minecraft Java Server
After=network.target
[Service]
User=gameserver
WorkingDirectory=/home/gameserver/minecraft
ExecStart=/home/gameserver/minecraft/start.sh
ExecStop=/bin/kill -SIGINT $MAINPID
Restart=on-failure
RestartSec=10
[Install]
WantedBy=multi-user.targetsudo systemctl daemon-reload
sudo systemctl enable minecraft
sudo systemctl start minecraftRepeat with equivalent service files for CS2 and Palworld, replacing the service name, working directory, and ExecStart path accordingly.
Conclusion
A Hong Kong VPS game server delivers something no managed hosting service can match for East Asian players: genuine CN2 GIA low-latency connectivity to mainland China combined with full control over server configuration, mods, and game settings.
Whether you are running a private Minecraft community, a competitive CS2 server, or a Palworld world for friends across Asia, the combination of NVMe SSD storage, KVM virtualisation, and CN2 GIA routing makes Hong Kong the premier game server hosting location for the Asia-Pacific region in 2026.
Ready to launch your game server? Server.HK’s Hong Kong VPS plans start from competitive entry pricing with CN2 GIA routing, NVMe SSD, and full root access — everything you need to get your server online today.
Frequently Asked Questions
What is the best Hong Kong VPS spec for a Minecraft server with 20 players?
For a vanilla or lightly modded Minecraft Java server with up to 20 players, a 4 vCPU / 4 GB RAM VPS with NVMe SSD storage is the practical sweet spot. Heavily modded servers (50+ mods) should start at 6–8 GB RAM to avoid frequent garbage collection pauses.
Can I run CS2 at 128 tick on a Hong Kong VPS?
Yes, provided your VPS uses KVM virtualisation with dedicated CPU resources. 128-tick CS2 for 10 players runs stably on 4 vCPU KVM instances. Avoid OpenVZ VPS plans for game servers — shared kernel architecture causes inconsistent CPU scheduling that produces noticeable tick rate variance.
How do I protect my game server from DDoS attacks?
Use a provider with built-in network-level DDoS mitigation (included with Server.HK plans), configure UFW to rate-limit non-game ports, keep your server IP private by using a domain name instead of advertising the raw IP, and consider IP rotation or a proxy service for high-profile servers that are frequent targets.
Can I run Minecraft and CS2 on the same Hong Kong VPS?
Yes, as long as your VPS has sufficient RAM and CPU for both simultaneously. A 8 GB RAM / 4 vCPU instance can run a small Minecraft server alongside a CS2 server with moderate player counts. Monitor resource usage with htop and upgrade your plan if sustained CPU usage exceeds 80%.
Do I need a Steam account to run a CS2 dedicated server?
You do not need a Steam account to download CS2 server files (anonymous SteamCMD login works). However, you do need a free Game Server Login Token (GSLT) from the Steam developer portal to run a publicly listed CS2 server. Without a GSLT, the server still works for direct-connect play.