通过在名为 stats_io_servers 的 MySQL 表中每分钟保存一次状态,来监控 Minecraft 服务器的状态。在 BungeeCord 环境中,每个服务器可以使用不同的名称进行标识,从而快速查看整个网络的状态。数据随后可通过你选择的前端界面进行展示(未包含在此插件中)。
存储的数据类似于服务器查询结果,包括以下内容:
- 在线玩家数量
- 允许的最大玩家数量
- 在线玩家列表
- 已安装的插件列表
此外还包含以下信息:
- 当前 TPS(每秒刻数)
- 上次服务器启动时间
- 上次检查时间
此设计旨在让服务器管理员一目了然地查看其网络状态。如果“上次检查时间”不再更新,这可以作为一个有用的线索,提醒某人某台服务器可能已离线或崩溃!
将此类信息保存到数据库中,使你能够使用多个客户端检查结果,而无需因频繁查询而使服务器本身负担过重。
安装
- 下载插件并将其放入你的
plugins/ 目录。
- 启动并停止服务器以生成配置文件。
- 编辑
config.yml,填入你的 MySQL 数据库信息和一个唯一的服务器 ID(字符串)。
- 启动服务器。一分钟后,MySQL 表将开始接收数据。
配置
database.host: 数据库主机地址
database.port: 数据库端口
database.base: 数据库名称
database.username: 数据库用户名
database.password: 数据库密码
server-id: 该服务器的唯一 ID
命令
无
权限
无
为什么这个插件可靠?
我将所有插件都用于我自己的服务器上,我希望我的插件稳定、可靠且维护成本低。版本升级时出现中断的情况是不期望发生的,但如果真的发生,我会尽快修复。
支持我的工作
如果你喜欢我的工作,我欢迎赞助!自 2011 年以来我一直在运营 Minecraft 服务器,为服务器所有者开发了多种插件和工具,现在正逐步发布其中许多作品。你的支持将极大地鼓励我投入更多时间和精力于此,并及时修复随着时间的推移可能发现的问题!

Monitor the status of a Minecraft server by saving it every minute in a MySQL table named stats_io_servers. In a Bungee environment, each server can be identified with a different name to get a quick view of the status of your network. The data can then be displayed in a frontend of your choice (not included).
The data stored is similar to that of a server query, which includes the following:
- Number of players online
- Max amount of players allowed
- List of online players
- List of plugins installed
To this are added:
- Current TPS (Ticks Per Second)
- Time of last server start
- Time of the last check
This is designed to let server admins see the status of their network at a glance. If the last check time isn't updating anymore, it can be a useful clue to warn someone that either a server is offline, or it crashed!
Saving this information to a database lets you use multiple clients to check on the results without bogging down the servers themselves with constant queries.
Installation
- Download the plugin and place it in your plugins/ directory.
- Start and stop the server to generate the configuration file.
- Edit config.yml with your MySQL database information and a unique server ID (string).
- Start your server. After a minute, the MySQL table will start getting results.
Configuration
database.host: Database host
database.port: Database port
database.base: Database name
database.username: Database username
database.password: Database password
server-id: A unique ID for this server
Commands
None
Permissions
None
Why is this plugin reliable?
I use all of my plugins on my own servers, and I like my plugins to be stable, reliable and low maintenance. Breaks on version upgrades are not expected, but should they happen, they will be quickly fixed.
Support my work
If you enjoy my work, I welcome sponsors! I've been running Minecraft servers since 2011, developed several plugins and tools for server owners, and I'm now working my way through releasing many of them. Your support would go a long way toward encouraging me to put more time and effort into this, plus fix any issues that might be discovered over time!

评论 0
登录后参与评分
还没有评论,来抢沙发吧