Eco 专用服务器(App ID 739590)可通过 SteamCMD 在 Windows 或 Linux 上免费安装,游戏使用 3000 端口,网页界面使用 3001 端口。所查来源未详述内存需求,建议保守预留 8 GB,耗时约 15–30 分钟。
分步安装
准备一台带 SSD 的 64 位 Windows 或 Linux 机器。
安装 SteamCMD。
使用 app_update 739590 -beta default validate(anonymous 登录)安装服务器。
运行一次 EcoServer.exe(Windows)或 ./EcoServer(Linux)后停止。
服务器停止时编辑 Eco_Data/Server/Configs/Network.eco(名称、密码、地址)。
在防火墙、服务商和路由器上开放 3000(UDP 与 TCP)及 3001(TCP)。
重启并测试:在浏览器打开 IP:3001 查看网页界面,然后进游戏连接。
创建 systemd 服务(Linux)或计划任务(Windows)。
安排更新与 Eco_Data/Server/Storage 备份。
要求与世界大小
下载无需 Steam 账号(anonymous)。有托管商称新版服务器(V11+)需要在 play.eco 生成服务器令牌,但所查官方文档未证实,请查阅 wiki.play.eco。世界大小在 WorldGenerator.eco 中设置(可被 4 整除,更改即新世界)。某托管商建议的尺寸:
- 72×72: 5 to 15 players
- 100×100: 15 to 30 players
- 140×140: 30 to 50 players
- 200×200: 50 to 100 players
本地安装(Windows)
将 SteamCMD 解压到 C:\steamcmd,安装服务器并运行 EcoServer.exe。游戏内连接 127.0.0.1,网页界面为 http://127.0.0.1:3001。
C:\steamcmd\steamcmd.exe +force_install_dir C:\eco +login anonymous +app_update 739590 -beta default validate +quit
cd C:\eco
.\EcoServer.exeLinux VPS 安装(Ubuntu/Debian)
SteamCMD 命令来自官方 wiki(“Server on Linux”)。请使用专用的非 root 用户;Ubuntu 需先启用 multiverse 与 i386 架构再安装 steamcmd。可能的系统依赖此处未详述,请参阅 wiki。
sudo adduser --disabled-password --gecos "" eco
sudo add-apt-repository multiverse && sudo dpkg --add-architecture i386 && sudo apt update
sudo apt install -y steamcmd
sudo -iu eco
/usr/games/steamcmd +force_install_dir ~/Eco +login anonymous +app_update 739590 -beta default validate +quit
cd ~/Eco && chmod +x EcoServer && ./EcoServer需开放的端口
默认端口(Network.eco):GameServerPort 3000、WebServerPort 3001;官方 wiki 的防火墙示例中开放 3000 的 TCP 与 UDP 以及 3001 的 TCP。据 wiki,网页端口 3001 适用于较新版本,请核对你的 Network.eco。家用路由器做端口转发(NAT);OVH、Hetzner、Scaleway 还需在服务商防火墙/安全组放行,并从其他网络测试。若检测到的 IP 有误,请设置 RemoteAddress 与 WebServerUrl。
- 3000/UDP and 3000/TCP — game (GameServerPort)
- 3001/TCP — web interface (WebServerPort)
Linux 防火墙(ufw)
启用 ufw 前先允许 SSH。
sudo ufw allow OpenSSH
sudo ufw allow 3000/udp
sudo ufw allow 3000/tcp
sudo ufw allow 3001/tcp
sudo ufw enableWindows 防火墙
管理员 PowerShell:
netsh advfirewall firewall add rule name="Eco game UDP" dir=in action=allow protocol=UDP localport=3000
netsh advfirewall firewall add rule name="Eco TCP" dir=in action=allow protocol=TCP localport=3000-3001systemd 服务(自动启动)
创建 /etc/systemd/system/eco.service,然后执行 sudo systemctl enable --now eco。Windows 上创建“开机时”运行 EcoServer.exe 的计划任务。请始终正常停止服务:Eco 会在关闭时写入文件。
[Unit]
Description=Eco Server
After=network-online.target
Wants=network-online.target
[Service]
User=eco
WorkingDirectory=/home/eco/Eco
ExecStart=/home/eco/Eco/EcoServer
Restart=on-failure
RestartSec=15
TimeoutStopSec=120
[Install]
WantedBy=multi-user.target更新与备份
世界存放在 Eco_Data/Server/Storage/(Game.eco、Game.db、Backup/)。停止服务,复制 Storage 与 Configs,重新运行 SteamCMD 命令后重启。
sudo systemctl stop eco
tar czf ~/eco-backup-$(date +%F).tar.gz -C /home/eco/Eco Eco_Data/Server/Storage Eco_Data/Server/Configs
sudo -u eco /usr/games/steamcmd +force_install_dir /home/eco/Eco +login anonymous +app_update 739590 -beta default validate +quit
sudo systemctl start eco
# crontab -e (root) : 0 5 * * * systemctl restart eco发布服务器
PublicServer=true(默认)会让服务器出现在游戏内列表;为 false 时仍可通过 IP:3000 直连。请填写 Description、DetailedDescription 和 ServerCategory 以便被找到,并将服务器添加到 game-rank.com/jeux/eco。
故障排查
- 无法连接:开放 3000(UDP 与 TCP)和 3001(TCP),并检查 NAT 转发。
- 外部无法访问网页界面:设置 WebServerUrl(http + 端口)并开放 3001/TCP。
- 配置修改丢失:Eco 在关闭时重写文件,请始终在服务器停止时编辑。
- 不在列表中:检查 PublicServer=true 以及 RemoteAddress/IPAddress 是否正确(IPAddress 保持 Any)。
- 更改世界大小无效:WorldGenerator.eco 仅对新世界生效(备份后删除 Storage)。
常见问题
- Eco 服务器的 App ID 是多少?
- 739590:steamcmd +force_install_dir ~/Eco +login anonymous +app_update 739590 -beta default validate +quit(官方 wiki 中的命令)。
- Eco 使用哪些端口?
- 默认 3000(游戏,UDP;wiki 同时开放 TCP)和 3001(网页,TCP),可在 Network.eco 中通过 GameServerPort 与 WebServerPort 修改。
- 配置文件在哪里?
- 位于 Eco_Data/Server/Configs/:Network.eco、Difficulty.eco、WorldGenerator.eco、Disasters.eco、Users.eco(白名单/管理员);世界存放在 Eco_Data/Server/Storage/。
- 如何更新服务器?
- 停止服务器,备份 Storage 与 Configs,重新运行 SteamCMD 安装命令后重启。
