Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

require_online_players在paper1.20.6失效 #26

Closed
tsxc-github opened this issue May 11, 2024 · 16 comments
Closed

require_online_players在paper1.20.6失效 #26

tsxc-github opened this issue May 11, 2024 · 16 comments
Labels
cannot reproduce The described issue is failed to be reproduced

Comments

@tsxc-github
Copy link

没有测试其他版本。

在一名玩家加入游戏后游玩并退出后,prime backup无法检测到玩家退出(插件在服务器启动前 就被加载,安装MinecraftDataAPI v1.5.0也无济于事)

似乎也没检测到基岩版玩家

以下为部分日志(安装MinecraftDataAPI):

MCDR] [13:44:16] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], performing the last backup
[MCDR] [13:44:16] [PB@31e6-crontab_0/INFO] [prime_backup]: [PB] 定时备份触发
[MCDR] [13:44:16] [PB@31e6-worker-heavy/INFO] [prime_backup]: [PB] 创建备份中...请稍等
[Server] [13:44:17 INFO]: Automatic saving is now disabled
[Server] [13:44:17 INFO]: Saving the game (this may take a moment!)
[Server] [13:44:17 INFO]: ThreadedAnvilChunkStorage (world): All chunks are saved
[Server] [13:44:17 INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[Server] [13:44:17 INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[Server] [13:44:17 INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[Server] [13:44:17 INFO]: Saved the game
[MCDR] [13:44:17] [PB@31e6-worker-heavy/INFO] [prime_backup]: Creating backup for ['world'] at path 'server', timestamp 1715406257059515139, creator 'prime_backup:scheduled_backup', comment '__pb_translated__:scheduled_backup', tags {}
[MCDR] [13:44:17] [PB@31e6-worker-heavy/INFO] [prime_backup]: Create backup #612 done, +16 blobs (size 55.85MiB / 65.25MiB)
[MCDR] [13:44:17] [PB@31e6-worker-heavy/INFO] [prime_backup]: Time costs: save wait 0.1s, create backup 0.45s
[MCDR] [13:44:17] [PB@31e6-worker-heavy/INFO] [prime_backup]: [PB] 备份完成, ID #612, 耗时0.55s, 体积131.76MiB (+65.25MiB)
[MCDR] [13:44:17] [PB@31e6-crontab_0/INFO] [prime_backup]: [PB] 定时备份完成, 下次执行: 2024-05-11 14:04:21
[Server] [13:44:17 INFO]: Automatic saving is now enabled
[MCDR] [14:04:21] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [14:24:21] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [14:44:22] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [15:04:26] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [15:24:35] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [15:44:45] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [16:04:49] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [16:24:53] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [16:44:56] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [17:05:01] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [17:25:06] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [17:45:09] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [18:05:14] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[MCDR] [18:25:18] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[Server] [18:31:08 INFO]: [Geyser-Spigot] 玩家以 windowsXPpro666 的用户名建立了连接
[Server] [18:31:08 INFO]: [Geyser-Spigot] windowsXPpro666 (登录为: windowsXPpro666) 已连接到 Java 服务器
[Server] [18:31:09 INFO]: [floodgate] Floodgate 玩家 .windowsXPpro666 加入了 (UUID: 00000000-0000-0000-0009-01f8e7d346bf)
[Server] [18:31:09 INFO]: .windowsXPpro666 joined the game #注意这里#
[Server] [18:31:09 INFO]: .windowsXPpro666[/218.89.42.252:0] logged in with entity id 29 at ([world]-25.5, 73.0, -151.5)
[Server] [18:32:52 INFO]: [Geyser-Spigot] windowsXPpro666 因为 基岩版客户端已断开连接 与 Java 版服务器 断开了连接
[Server] [18:32:52 INFO]: [floodgate] Floodgate 玩家 .windowsXPpro666 已断开连接
[Server] [18:32:52 INFO]: .windowsXPpro666 lost connection: Disconnected
[Server] [18:32:52 INFO]: .windowsXPpro666 left the game #注意这里#
[Server] [18:39:33 INFO]: UUID of player C__157 is cef8bcb4-02b8-31ee-b2f9-5d48f7505e05
[Server] [18:39:34 INFO]: C__157 joined the game #注意这里#
[Server] [18:39:34 INFO]: C__157[/218.89.42.252:11971] logged in with entity id 1412 at ([world]-25.602967201289275, 72.0, -139.61141725994273)
[Server] [18:39:51 INFO]: C__157 issued server command: /tomap https://img2.imgtp.com/2024/05/11/CHeCflVA.JPG
[Server] [18:40:11 INFO]: C__157 lost connection: Disconnected
[Server] [18:40:11 INFO]: C__157 left the game #注意这里#
[Server] [18:41:26 INFO]: UUID of player C__157 is cef8bcb4-02b8-31ee-b2f9-5d48f7505e05
[Server] [18:41:27 INFO]: C__157 joined the game #注意这里#
[Server] [18:41:27 INFO]: C__157[/218.89.42.252:12594] logged in with entity id 2038 at ([world]-27.908169823655815, 73.0, -156.54071703545398)
[Server] [18:41:33 INFO]: C__157 issued server command: /tomap https://img2.imgtp.com/2024/05/11/1dABHEZQ.JPG
[Server] [18:42:07 INFO]: C__157 issued server command: /tomap https://img2.imgtp.com/2024/05/11/Co3qjC1S.JPG
[Server] [18:43:45 INFO]: C__157 issued server command: /tomap https://img2.imgtp.com/2024/05/11/xe0pkVGs.JPG
[Server] [18:44:12 INFO]: C__157 issued server command: /tomap https://img2.imgtp.com/2024/05/11/lrmZr1dq.JPG
[Server] [18:44:26 INFO]: C__157 issued server command: /tomap https://img2.imgtp.com/2024/05/11/Ne3nnxfa.JPG
[MCDR] [18:45:23] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=['C__157'] ignored=[], performing normally
[MCDR] [18:45:23] [PB@31e6-crontab_0/INFO] [prime_backup]: [PB] 定时备份触发
[MCDR] [18:45:23] [PB@31e6-worker-heavy/INFO] [prime_backup]: [PB] 创建备份中...请稍等
[Server] [18:45:23 INFO]: Automatic saving is now disabled
[Server] [18:45:23 INFO]: Saving the game (this may take a moment!)
[Server] [18:45:29 INFO]: ThreadedAnvilChunkStorage (world): All chunks are saved
[Server] [18:45:29 INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[Server] [18:45:29 INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[Server] [18:45:29 INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[Server] [18:45:29 INFO]: Saved the game
[Server] [18:45:29 WARN]: Can't keep up! Is the server overloaded? Running 5619ms or 112 ticks behind
[MCDR] [18:45:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: Creating backup for ['world'] at path 'server', timestamp 1715424329315976359, creator 'prime_backup:scheduled_backup', comment '__pb_translated__:scheduled_backup', tags {}
[MCDR] [18:45:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: Create backup #613 done, +36 blobs (size 86.27MiB / 100.97MiB)
[MCDR] [18:45:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: Time costs: save wait 5.7s, create backup 0.63s
[MCDR] [18:45:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: [PB] 备份完成, ID #613, 耗时6.33s, 体积131.77MiB (+100.97MiB)
[MCDR] [18:45:29] [PB@31e6-crontab_0/INFO] [prime_backup]: [PB] 定时备份完成, 下次执行: 2024-05-11 19:05:29
[Server] [18:45:29 INFO]: Automatic saving is now enabled
[MCDR] [19:05:29] [PB@31e6-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=['C__157'] ignored=[], performing normally
[MCDR] [19:05:29] [PB@31e6-crontab_0/INFO] [prime_backup]: [PB] 定时备份触发
[MCDR] [19:05:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: [PB] 创建备份中...请稍等
[Server] [19:05:29 INFO]: Automatic saving is now disabled
[Server] [19:05:29 INFO]: Saving the game (this may take a moment!)
[Server] [19:05:29 INFO]: ThreadedAnvilChunkStorage (world): All chunks are saved
[Server] [19:05:29 INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[Server] [19:05:29 INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[Server] [19:05:29 INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[Server] [19:05:29 INFO]: Saved the game
[MCDR] [19:05:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: Creating backup for ['world'] at path 'server', timestamp 1715425529259723889, creator 'prime_backup:scheduled_backup', comment '__pb_translated__:scheduled_backup', tags {}
[MCDR] [19:05:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: Create backup #614 done, +34 blobs (size 86.25MiB / 101.02MiB)
[MCDR] [19:05:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: Time costs: save wait 0.22s, create backup 0.65s
[MCDR] [19:05:29] [PB@31e6-worker-heavy/INFO] [prime_backup]: [PB] 备份完成, ID #614, 耗时0.87s, 体积131.79MiB (+101.02MiB)
[MCDR] [19:05:29] [PB@31e6-crontab_0/INFO] [prime_backup]: [PB] 定时备份完成, 下次执行: 2024-05-11 19:25:33
[Server] [19:05:29 INFO]: Automatic saving is now enabled

prime backup使用的是最新版v1.7.4

感觉与系统无关?懒得找具体的系统环境信息了,用的是Ubuntu

@Fallen-Breath
Copy link
Contributor

Fallen-Breath commented May 11, 2024

根据提供的日志,PB 表现符合预期

18:41:27 时,名为 C__157 的玩家加入服务器后,没有再次离开服务器(观察日志,没有下一条形如 C__157 left the game 的输出),因此 PB 认为玩家 C__157 依然在服务器里,会继续执行定时备份。这从 PB 定时备份触发时,以 Scheduled backup player check 开头的日志输出中也可看出

若你的服务器使用了 mod / 插件,提供了与原版表现不同的玩家加入 / 离开逻辑,则 PB 将无法处理这种情况。这不是 PB 的问题,而是 MCDR 的服务端解析处理器不支持这种 mod / 插件的自定义玩家加入 / 离开逻辑的问题。但由于这是非原版 paper 的表现,因此 MCDR 也不会对此进行支持

@Fallen-Breath Fallen-Breath added the invalid In fact, nothing goes wrong label May 11, 2024
@tsxc-github
Copy link
Author

抱歉,是我日志截取有误,稍等一会我会整理一下并测试。

情况是确定存在的,不然我这周就不会多出来600个备份了

还有对于非原版表现不同的情况有什么解决方案吗,比较需要使用geyser。

@tsxc-github
Copy link
Author

这是一次测试的完整日志:

MCDReforged 2.12.3 is starting up
MCDReforged is open source, u can find it here: https://github.com/Fallen-Breath/MCDReforged
[MCDR] [08:51:50] [MainThread/INFO]: 语言已设置为 zh_cn
[MCDR] [08:51:50] [MainThread/INFO]: 编码 / 解码方式已设置为 utf8 / utf8
[MCDR] [08:51:50] [MainThread/INFO]: 插件文件夹列表:
[MCDR] [08:51:50] [MainThread/INFO]: - plugins
[MCDR] [08:51:50] [MainThread/INFO]: 解析处理器已设置为 bukkit_handler
[MCDR] [08:51:50] [MainThread/INFO]: MCDReforged正于Python 3.11.6环境中运行
[MCDR] [08:51:50] [TaskExecutor/INFO]: 刷新所有插件中
[MCDR] [08:51:50] [TaskExecutor/INFO]: 插件 prime_backup@1.7.4 已加载
[MCDR] [08:51:50] [TaskExecutor/INFO]: 插件 minecraft_data_api@1.5.0 已加载
[MCDR] [08:51:51] [TaskExecutor/INFO] [prime_backup]: 配置文件已加载
[MCDR] [08:51:51] [PB@09c8-worker-heavy/INFO] [prime_backup]: Worker heavy started
[MCDR] [08:51:51] [PB@09c8-worker-light/INFO] [prime_backup]: Worker light started
[MCDR] [08:51:51] [PB@09c8-crontab-scheduler/INFO] [prime_backup]: Scheduler started
[MCDR] [08:51:51] [TaskExecutor/INFO] [prime_backup]: Added job "CreateDbBackupJob.run" to job store "default"
[MCDR] [08:51:51] [TaskExecutor/INFO] [prime_backup]: Added job "PruneBackupJob.run" to job store "default"
[MCDR] [08:51:51] [TaskExecutor/INFO] [prime_backup]: Added job "ScheduledBackupJob.run" to job store "default"
[MCDR] [08:51:51] [TaskExecutor/INFO] [prime_backup]: Added job "VacuumSqliteJob.run" to job store "default"
[MCDR] [08:51:51] [TaskExecutor/INFO]: 共加载: 2 个插件; 已加载插件数: 4
[MCDR] [08:51:51] [MainThread/INFO]: 正在启动服务端,启动参数为 "java -DPaper.IgnoreJavaVersion=true -Xms1G -Xmx8G -Dfile.encoding=UTF-8 -jar paper-1.20.6-62.jar nogui"
[MCDR] [08:51:51] [MainThread/INFO]: 服务端正在以 PID 6129 运行中
[MCDR] [08:51:51] [TaskExecutor/INFO] [prime_backup]: Server startup detected, enable the online player counter
[Server] Starting org.bukkit.craftbukkit.Main
[Server] Unsupported Java detected (22-ea), but the check was skipped. Proceed with caution! 
[Server] System Info: Java 22 (OpenJDK 64-Bit Server VM 22-ea+16-Ubuntu-1) Host: Linux 6.5.0-28-generic (amd64)
[Server] Loading libraries, please wait...
[Server] WARN StatusConsoleListener Advanced terminal features are not available in this environment
[Server] [08:51:58 INFO]: Environment: Environment[sessionHost=https://sessionserver.mojang.com, servicesHost=https://api.minecraftservices.com, name=PROD]
[Server] [08:52:00 INFO]: Loaded 1175 recipes
[Server] [08:52:00 INFO]: Loaded 1276 advancements
[Server] [08:52:00 INFO]: Starting minecraft server version 1.20.6
[Server] [08:52:00 WARN]: ****************************
[Server] [08:52:00 WARN]: YOU ARE RUNNING THIS SERVER AS AN ADMINISTRATIVE OR ROOT USER. THIS IS NOT ADVISED.
[Server] [08:52:00 WARN]: YOU ARE OPENING YOURSELF UP TO POTENTIAL RISKS WHEN DOING THIS.
[Server] [08:52:00 WARN]: FOR MORE INFORMATION, SEE https://madelinemiller.dev/blog/root-minecraft-server/
[Server] [08:52:00 WARN]: ****************************
[Server] [08:52:00 INFO]: Loading properties
[Server] [08:52:00 INFO]: This server is running Paper version git-Paper-62 (MC: 1.20.6) (Implementing API version 1.20.6-R0.1-SNAPSHOT) (Git: cdb6ba8)
[Server] [08:52:01 INFO]: Server Ping Player Sample Count: 12
[Server] [08:52:01 INFO]: Using 4 threads for Netty based IO
[Server] [08:52:02 WARN]: [!] The timings profiler has been enabled but has been scheduled for removal from Paper in the future.
[Server]     We recommend installing the spark profiler as a replacement: https://spark.lucko.me/
[Server]     For more information please visit: https://github.com/PaperMC/Paper/issues/8948
[Server] [08:52:02 INFO]: [ChunkTaskScheduler] Chunk system is using 1 I/O threads, 6 worker threads, and gen parallelism of 6 threads
[Server] [08:52:02 INFO]: Default game type: SURVIVAL
[Server] [08:52:02 INFO]: Generating keypair
[Server] [08:52:02 INFO]: Starting Minecraft server on *:25565
[Server] [08:52:02 INFO]: Using epoll channel type
[Server] [08:52:02 INFO]: Paper: Using libdeflate (Linux x86_64) compression from Velocity.
[Server] [08:52:02 INFO]: Paper: Using OpenSSL 3.0.x (Linux x86_64) cipher from Velocity.
[Server] [08:52:02 INFO]: [floodgate] Loading server plugin floodgate v2.2.3-SNAPSHOT (b100-a44e3a5)
[Server] [08:52:04 INFO]: [floodgate] 启动 Floodgate,耗时1,598ms
[Server] [08:52:04 INFO]: [Geyser-Spigot] Loading server plugin Geyser-Spigot v2.3.0-SNAPSHOT
[Server] [08:52:06 INFO]: [Geyser-Spigot] 正在加载插件...
[Server] [08:52:06 INFO]: [Geyser-Spigot] 已加载 0 个插件
[Server] [08:52:06 INFO]: [ColorfulMap] Loading server plugin ColorfulMap v1.4
[Server] [08:52:06 INFO]: Server permissions file permissions.yml is empty, ignoring it
[Server] [08:52:06 INFO]: [ColorfulMap] Enabling ColorfulMap v1.4
[Server] [08:52:06 INFO]: [ColorfulMap]  I | ColorfulMap 已加载
[Server] [08:52:06 INFO]: [ColorfulMap]  I | 版本: 1.4
[Server] [08:52:06 INFO]: [ColorfulMap]  I |    _____      _             __       _ __  __
[Server] [08:52:06 INFO]: [ColorfulMap]  I |   / ____|    | |           / _|     | |  \/  |
[Server] [08:52:06 INFO]: [ColorfulMap]  I |  | |     ___ | | ___  _ __| |_ _   _| | \  / | __ _ _ __
[Server] [08:52:06 INFO]: [ColorfulMap]  I |  | |    / _ \| |/ _ \| '__|  _| | | | | |\/| |/ _` | '_ \
[Server] [08:52:06 INFO]: [ColorfulMap]  I |  | |___| (_) | | (_) | |  | | | |_| | | |  | | (_| | |_) |
[Server] [08:52:06 INFO]: [ColorfulMap]  I |   \_____\___/|_|\___/|_|  |_|  \__,_|_|_|  |_|\__,_| .__/
[Server] [08:52:06 INFO]: [ColorfulMap]  I |                                                    | |
[Server] [08:52:06 INFO]: [ColorfulMap]  I |                                                    |_|
[Server] [08:52:06 INFO]: [ColorfulMap]  I | 
[Server] [08:52:06 WARN]: **** SERVER IS RUNNING IN OFFLINE/INSECURE MODE!
[Server] [08:52:06 WARN]: The server will make no attempt to authenticate usernames. Beware.
[Server] [08:52:06 WARN]: While this makes the game possible to play without internet access, it also opens up the ability for hackers to connect with any username they choose.
[Server] [08:52:06 WARN]: To change this, set "online-mode" to "true" in the server.properties file.
[Server] [08:52:06 INFO]: Preparing level "world"
[Server] [08:52:06 INFO]: Preparing start region for dimension minecraft:overworld
[Server] [08:52:07 INFO]: Time elapsed: 865 ms
[Server] [08:52:07 INFO]: Preparing start region for dimension minecraft:the_nether
[Server] [08:52:07 INFO]: Time elapsed: 82 ms
[Server] [08:52:07 INFO]: Preparing start region for dimension minecraft:the_end
[Server] [08:52:07 INFO]: Time elapsed: 63 ms
[Server] [08:52:07 INFO]: [floodgate] Enabling floodgate v2.2.3-SNAPSHOT (b100-a44e3a5)
[Server] [08:52:08 INFO]: [Geyser-Spigot] Enabling Geyser-Spigot v2.3.0-SNAPSHOT
[Server] [08:52:08 INFO]: [Geyser-Spigot] ******************************************
[Server] [08:52:08 INFO]: [Geyser-Spigot] 
[Server] [08:52:08 INFO]: [Geyser-Spigot] 加载 Geyser 中, 版本 2.3.0-SNAPSHOT (git-master-b39ed5d)
[Server] [08:52:08 INFO]: [Geyser-Spigot] 
[Server] [08:52:08 INFO]: [Geyser-Spigot] ******************************************
[Server] [08:52:16 INFO]: [ColorfulMap]  I | ================================
[Server] [08:52:16 INFO]: [ColorfulMap]  I | 正在检查更新...
[Server] [08:52:16 INFO]: [ColorfulMap]  I | 当前已是最新版本:1.4
[Server] [08:52:16 INFO]: [ColorfulMap]  I | ================================
[Server] [08:52:16 INFO]: [Geyser-Spigot] Geyser正在启动 0.0.0.0:19132
[Server] [08:52:16 INFO]: [Geyser-Spigot] 完成 (8.404s)! 执行/geyser help 来获取帮助信息!
[Server] [08:52:17 INFO]: Running delayed init tasks
[Server] [08:52:17 INFO]: Done (16.589s)! For help, type "help"
[Server] [08:52:17 INFO]: Timings Reset
[MCDR] [08:52:55] [PB@09c8-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], performing the last backup
[MCDR] [08:52:55] [PB@09c8-crontab_0/INFO] [prime_backup]: [PB] 定时备份触发
[MCDR] [08:52:55] [PB@09c8-worker-heavy/INFO] [prime_backup]: [PB] 创建备份中...请稍等
[Server] [08:52:55 INFO]: Automatic saving is now disabled
[Server] [08:52:55 INFO]: Saving the game (this may take a moment!)
[Server] [08:52:55 INFO]: ThreadedAnvilChunkStorage (world): All chunks are saved
[Server] [08:52:55 INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[Server] [08:52:55 INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[Server] [08:52:55 INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[Server] [08:52:55 INFO]: Saved the game
[MCDR] [08:52:55] [PB@09c8-worker-heavy/INFO] [prime_backup]: Creating backup for ['world'] at path 'server', timestamp 1715475175954289050, creator 'prime_backup:scheduled_backup', comment '__pb_translated__:scheduled_backup', tags {}
[MCDR] [08:52:56] [PB@09c8-worker-heavy/INFO] [prime_backup]: Create backup #624 done, +10 blobs (size 35.97MiB / 38.37MiB)
[MCDR] [08:52:56] [PB@09c8-worker-heavy/INFO] [prime_backup]: Time costs: save wait 0.56s, create backup 0.34s
[MCDR] [08:52:56] [PB@09c8-worker-heavy/INFO] [prime_backup]: [PB] 备份完成, ID #624, 耗时0.9s, 体积132.69MiB (+38.37MiB)
[MCDR] [08:52:56] [PB@09c8-crontab_0/INFO] [prime_backup]: [PB] 定时备份完成, 下次执行: 2024-05-12 08:53:59
[Server] [08:52:56 INFO]: Automatic saving is now enabled
[MCDR] [08:53:59] [PB@09c8-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=[] ignored=[], backup skipped
[Server] [08:54:13 INFO]: UUID of player tsxc_java is 79254f4a-f726-3744-9f76-ff4e8b9cf633
[Server] [08:54:14 INFO]: tsxc_java joined the game
[Server] [08:54:14 INFO]: tsxc_java[/192.168.0.17:49882] logged in with entity id 28 at ([world]-30.04601772802887, 73.84375002384186, -149.62756464664608)
[MCDR] [08:55:08] [PB@09c8-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=['tsxc_java'] ignored=[], performing normally
[MCDR] [08:55:08] [PB@09c8-crontab_0/INFO] [prime_backup]: [PB] 定时备份触发
[MCDR] [08:55:08] [PB@09c8-worker-heavy/INFO] [prime_backup]: [PB] 创建备份中...请稍等
[Server] [08:55:08 INFO]: Automatic saving is now disabled
[Server] [08:55:08 INFO]: Saving the game (this may take a moment!)
[Server] [08:55:16 INFO]: ThreadedAnvilChunkStorage (world): All chunks are saved
[Server] [08:55:16 INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[Server] [08:55:16 INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[Server] [08:55:16 INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[Server] [08:55:16 INFO]: Saved the game
[Server] [08:55:16 WARN]: Can't keep up! Is the server overloaded? Running 7541ms or 150 ticks behind
[MCDR] [08:55:16] [PB@09c8-worker-heavy/INFO] [prime_backup]: Creating backup for ['world'] at path 'server', timestamp 1715475316339513706, creator 'prime_backup:scheduled_backup', comment '__pb_translated__:scheduled_backup', tags {}
[MCDR] [08:55:17] [PB@09c8-worker-heavy/INFO] [prime_backup]: Create backup #625 done, +30 blobs (size 87.45MiB / 101.68MiB)
[MCDR] [08:55:17] [PB@09c8-worker-heavy/INFO] [prime_backup]: Time costs: save wait 7.6s, create backup 0.68s
[MCDR] [08:55:17] [PB@09c8-worker-heavy/INFO] [prime_backup]: [PB] 备份完成, ID #625, 耗时8.28s, 体积132.71MiB (+101.68MiB)
[MCDR] [08:55:17] [PB@09c8-crontab_0/INFO] [prime_backup]: [PB] 定时备份完成, 下次执行: 2024-05-12 08:56:15
[Server] [08:55:17 INFO]: Automatic saving is now enabled
[Server] [08:55:20 INFO]: tsxc_java lost connection: Disconnected
[Server] [08:55:20 INFO]: tsxc_java left the game
[MCDR] [08:56:15] [PB@09c8-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=['tsxc_java'] ignored=[], performing normally
[MCDR] [08:56:15] [PB@09c8-crontab_0/INFO] [prime_backup]: [PB] 定时备份触发
[MCDR] [08:56:15] [PB@09c8-worker-heavy/INFO] [prime_backup]: [PB] 创建备份中...请稍等
[Server] [08:56:15 INFO]: Automatic saving is now disabled
[Server] [08:56:15 INFO]: Saving the game (this may take a moment!)
[Server] [08:56:15 INFO]: ThreadedAnvilChunkStorage (world): All chunks are saved
[Server] [08:56:15 INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[Server] [08:56:15 INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[Server] [08:56:15 INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[Server] [08:56:15 INFO]: Saved the game
[MCDR] [08:56:15] [PB@09c8-worker-heavy/INFO] [prime_backup]: Creating backup for ['world'] at path 'server', timestamp 1715475375522790240, creator 'prime_backup:scheduled_backup', comment '__pb_translated__:scheduled_backup', tags {}
[MCDR] [08:56:15] [PB@09c8-worker-heavy/INFO] [prime_backup]: Create backup #626 done, +16 blobs (size 1.21MiB / 4.59MiB)
[MCDR] [08:56:15] [PB@09c8-worker-heavy/INFO] [prime_backup]: Time costs: save wait 0.09s, create backup 0.17s
[MCDR] [08:56:15] [PB@09c8-worker-heavy/INFO] [prime_backup]: [PB] 备份完成, ID #626, 耗时0.27s, 体积132.71MiB (+4.59MiB)
[MCDR] [08:56:15] [PB@09c8-crontab_0/INFO] [prime_backup]: [PB] 定时备份完成, 下次执行: 2024-05-12 08:57:19
[Server] [08:56:15 INFO]: Automatic saving is now enabled
[MCDR] [08:57:19] [PB@09c8-crontab_0/INFO] [prime_backup]: Scheduled backup player check: valid=['tsxc_java'] ignored=[], performing normally
[MCDR] [08:57:19] [PB@09c8-crontab_0/INFO] [prime_backup]: [PB] 定时备份触发
[MCDR] [08:57:19] [PB@09c8-worker-heavy/INFO] [prime_backup]: [PB] 创建备份中...请稍等
[Server] [08:57:19 INFO]: Automatic saving is now disabled
[Server] [08:57:19 INFO]: Saving the game (this may take a moment!)
[Server] [08:57:19 INFO]: ThreadedAnvilChunkStorage (world): All chunks are saved
[Server] [08:57:20 INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[Server] [08:57:20 INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[Server] [08:57:20 INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[Server] [08:57:20 INFO]: Saved the game
[MCDR] [08:57:20] [PB@09c8-worker-heavy/INFO] [prime_backup]: Creating backup for ['world'] at path 'server', timestamp 1715475440014334141, creator 'prime_backup:scheduled_backup', comment '__pb_translated__:scheduled_backup', tags {}
[MCDR] [08:57:20] [PB@09c8-worker-heavy/INFO] [prime_backup]: Create backup #627 done, +6 blobs (size 819.28KiB / 2.68MiB)
[MCDR] [08:57:20] [PB@09c8-worker-heavy/INFO] [prime_backup]: Time costs: save wait 0.11s, create backup 0.14s
[MCDR] [08:57:20] [PB@09c8-worker-heavy/INFO] [prime_backup]: [PB] 备份完成, ID #627, 耗时0.24s, 体积132.71MiB (+2.68MiB)
[MCDR] [08:57:20] [PB@09c8-crontab_0/INFO] [prime_backup]: [PB] 定时备份完成, 下次执行: 2024-05-12 08:58:27
[Server] [08:57:20 INFO]: Automatic saving is now enabled
> [INFO] 已执行预设的关闭命令:stop
如果无法关闭实例请前往实例设置更改关闭实例的正确命令,比如 exit,stop,end 等
> stop
[Server] [08:57:35 INFO]: Stopping the server
[Server] [08:57:35 INFO]: Stopping server
[Server] [08:57:35 INFO]: [ColorfulMap] Disabling ColorfulMap v1.4
[Server] [08:57:35 INFO]: [Geyser-Spigot] Disabling Geyser-Spigot v2.3.0-SNAPSHOT
[Server] [08:57:35 INFO]: [Geyser-Spigot] Geyser关闭中
[Server] [08:57:36 INFO]: [Geyser-Spigot] Geyser成功关闭.
[Server] [08:57:36 INFO]: [floodgate] Disabling floodgate v2.2.3-SNAPSHOT (b100-a44e3a5)
[Server] [08:57:36 INFO]: Saving players
[Server] [08:57:36 INFO]: Saving worlds
[Server] [08:57:36 INFO]: Saving chunks for level 'ServerLevel[world]'/minecraft:overworld
[Server] [08:57:36 INFO]: [ChunkHolderManager] Waiting 60s for chunk system to halt for world 'world'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Halted chunk system for world 'world'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Saving all chunkholders for world 'world'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Saved 0 block chunks, 234 entity chunks, 0 poi chunks in world 'world' in 0.05s
[Server] [08:57:36 INFO]: ThreadedAnvilChunkStorage (world): All chunks are saved
[Server] [08:57:36 INFO]: Saving chunks for level 'ServerLevel[world_nether]'/minecraft:the_nether
[Server] [08:57:36 INFO]: [ChunkHolderManager] Waiting 60s for chunk system to halt for world 'world_nether'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Halted chunk system for world 'world_nether'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Saving all chunkholders for world 'world_nether'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Saved 0 block chunks, 0 entity chunks, 0 poi chunks in world 'world_nether' in 0.00s
[Server] [08:57:36 INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[Server] [08:57:36 INFO]: Saving chunks for level 'ServerLevel[world_the_end]'/minecraft:the_end
[Server] [08:57:36 INFO]: [ChunkHolderManager] Waiting 60s for chunk system to halt for world 'world_the_end'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Halted chunk system for world 'world_the_end'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Saving all chunkholders for world 'world_the_end'
[Server] [08:57:36 INFO]: [ChunkHolderManager] Saved 0 block chunks, 10 entity chunks, 0 poi chunks in world 'world_the_end' in 0.00s
[Server] [08:57:36 INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[Server] [08:57:36 INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[Server] [08:57:36 INFO]: Flushing Chunk IO
[Server] [08:57:36 INFO]: Closing Thread Pool
[Server] WARN StatusConsoleListener Advanced terminal features are not available in this environment
[Server] [08:57:36 INFO]: Closing Server
[MCDR] [08:57:36] [MainThread/INFO]: 服务端进程返回代码: 0
[MCDR] [08:57:36] [MainThread/INFO]: 服务端已关闭
[MCDR] [08:57:36] [MainThread/INFO]: 正在关闭 MCDR
[MCDR] [08:57:36] [TaskExecutor/INFO] [prime_backup]: Shutting down everything...
[MCDR] [08:57:36] [PB@09c8-shutdown/INFO] [prime_backup]: Scheduler has been shut down
[MCDR] [08:57:36] [PB@09c8-worker-heavy/INFO] [prime_backup]: Worker heavy stopped
[MCDR] [08:57:36] [PB@09c8-worker-light/INFO] [prime_backup]: Worker light stopped
[MCDR] [08:57:36] [TaskExecutor/INFO] [prime_backup]: Shutdown completes
[MCDR] [08:57:36] [MainThread/INFO]: 正在关闭高级控制台
>
[MCDR] [08:57:37] [MainThread/INFO]: bye

然后是config:

{
    "enabled": true,
    "debug": false,
    "storage_root": "./pb_files",
    "concurrency": 1,
    "command": {
        "prefix": "!!pb",
        "permission": {
            "root": 0,
            "abort": 1,
            "back": 2,
            "confirm": 1,
            "crontab": 3,
            "database": 4,
            "delete": 2,
            "delete_range": 3,
            "diff": 4,
            "export": 4,
            "help": 0,
            "import": 4,
            "list": 1,
            "make": 1,
            "prune": 3,
            "rename": 2,
            "show": 1,
            "tag": 3
        },
        "confirm_time_wait": "1m",
        "backup_on_restore": true,
        "restore_countdown_sec": 10
    },
    "server": {
        "turn_off_auto_save": true,
        "commands": {
            "save_all_worlds": "save-all flush",
            "auto_save_off": "save-off",
            "auto_save_on": "save-on"
        },
        "saved_world_regex": [
            "Saved the game",
            "Saved the world"
        ],
        "save_world_max_wait": "5m"
    },
    "backup": {
        "source_root": "./server",
        "source_root_use_mcdr_working_directory": false,
        "targets": [
            "world"
        ],
        "ignored_files": [
            "session.lock"
        ],
        "follow_target_symlink": false,
        "hash_method": "xxh128",
        "compress_method": "zstd",
        "compress_threshold": 64
    },
    "scheduled_backup": {
        "enabled": true,
        "interval": "1m",
        "crontab": null,
        "jitter": "10s",
        "reset_timer_on_backup": true,
        "require_online_players": true,
        "require_online_players_blacklist": []
    },
    "prune": {
        "enabled": true,
        "interval": "6h",
        "crontab": null,
        "jitter": "1m",
        "timezone_override": null,
        "regular_backup": {
            "enabled": false,
            "max_amount": 0,
            "max_lifetime": "0s",
            "last": -1,
            "hour": 0,
            "day": 0,
            "week": 0,
            "month": 0,
            "year": 0
        },
        "temporary_backup": {
            "enabled": true,
            "max_amount": 10,
            "max_lifetime": "30d",
            "last": -1,
            "hour": 0,
            "day": 0,
            "week": 0,
            "month": 0,
            "year": 0
        }
    },
    "database": {
        "compact": {
            "enabled": true,
            "interval": null,
            "crontab": "0 7 * * *",
            "jitter": "1m"
        },
        "backup": {
            "enabled": true,
            "interval": null,
            "crontab": "0 6 * * 0",
            "jitter": "1m"
        }
    }
}

@tsxc-github
Copy link
Author

因为是学生,可能无法在周内提供更多信息(不过可能也不需要更多了吧),抱歉。

@Fallen-Breath
Copy link
Contributor

#26 (comment) 中的日志正确,则 PB 的表现确实有些奇怪

但所述表现无法复现。尝试复现时,玩家离开服务器后,PB 正常检测到了玩家离开

日志:https://pastebin.com/dvgmufSA ,环境:

  • MCDReforged 2.12.3
  • PrimeBackup 1.7.4
  • Python 3.11.7
  • paper-1.20.6-68

@Fallen-Breath Fallen-Breath added cannot reproduce The described issue is failed to be reproduced and removed invalid In fact, nothing goes wrong labels May 12, 2024
@tsxc-github
Copy link
Author

tsxc-github commented May 12, 2024

如果无法正常复现,我可以提供完整环境(指服务器)进行测试。

稍等一会我将服务器的LUN克隆一份,由于涉及一些私人信息,可否使用较私密通讯方式?

@Fallen-Breath
Copy link
Contributor

你可以提供一个 最小 可复现的环境,移除所有不影响复现的数据(插件、mod、存档、服务端运行时文件),然后将环境发出来

@Fallen-Breath
Copy link
Contributor

提供完整环境(指服务器)进行测试

请不要直接提供完整的服务器运行环境,我不会帮你 debug 你的具体运行环境的。请在确保 MCDR 的安装正确、插件文件无修改的前提下,提供如 #26 (comment) 所述的最小可复现环境

@tsxc-github
Copy link
Author

好的,谢谢

@tsxc-github
Copy link
Author

https://server.mzyc.xyz:5001/sharing/JKxB9z630

我保留了刚刚测试的那一部分日志,因为是在Windows下测试,所以有编码问题。但能够正常复现

@Fallen-Breath
Copy link
Contributor

Fallen-Breath commented May 12, 2024

https://server.mzyc.xyz:5001/sharing/JKxB9z630

我保留了刚刚测试的那一部分日志,因为是在Windows下测试,所以有编码问题。但能够正常复现

无法复现,PB 表现一切正常。相关日志与 #26 (comment) 一致

@Fallen-Breath
Copy link
Contributor

Fallen-Breath commented May 12, 2024

#26 (comment) 操作流程(docker):

sudo docker run -it --rm -p 25565:25565 python:3.11 bash
cd /tmp

wget https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21.0.3+9/OpenJDK21U-jdk_x64_linux_hotspot_21.0.3_9.tar.gz
tar -xzvf OpenJDK21U-jdk_x64_linux_hotspot_21.0.3_9.tar.gz
export PATH=$PATH:/tmp/jdk-21.0.3+9/bin

# 复制 server.zip 到当前路径
# ...
unzip server.zip

pip3 install -q mcdreforged hjson
pip3 install -qr https://tisunion.github.io/PrimeBackup/requirements.txt
python3 -m mcdreforged

日志:https://pastebin.com/eUBAz26F

@tsxc-github
Copy link
Author

自己测试了一下,从debug中可以发现MCDR并没有检测到玩家离开的消息,尚不知道此问题如何产生以及为何无法正常复现。

[MCDR] [20:35:13] [TaskExecutor/DEBUG]: Dispatching MCDREvent[id='mcdr.general_info', default_method_name='on_info'] with args (Info)
[MCDR] [20:35:14] [MainThread/DEBUG]: Parsed text from server stdout:
[MCDR] [20:35:14] [MainThread/DEBUG]:     Time: 20:35:14; ID: 1007
[MCDR] [20:35:14] [MainThread/DEBUG]:     Player: None; Source: 0; Logging level: INFO
[MCDR] [20:35:14] [MainThread/DEBUG]:     Content: tsxc_java joined the game
[MCDR] [20:35:14] [MainThread/DEBUG]:     Raw content: [20:35:14 INFO]: tsxc_java joined the game
[Server] [20:35:14 INFO]: tsxc_java joined the game
[MCDR] [20:35:14] [TaskExecutor/DEBUG]: Dispatching MCDREvent[id='mcdr.general_info', default_method_name='on_info'] with args (Info)
[MCDR] [20:35:14] [MainThread/DEBUG]: Parsed text from server stdout:
[MCDR] [20:35:14] [MainThread/DEBUG]:     Time: 20:35:14; ID: 1008
[MCDR] [20:35:14] [MainThread/DEBUG]:     Player: None; Source: 0; Logging level: INFO
[MCDR] [20:35:14] [MainThread/DEBUG]:     Content: tsxc_java[/127.0.0.1:54404] logged in with entity id 58 at ([world]1.5, 84.0, 10.5)
[MCDR] [20:35:14] [MainThread/DEBUG]:     Raw content: [20:35:14 INFO]: tsxc_java[/127.0.0.1:54404] logged in with entity id 58 at ([world]1.5, 84.0, 10.5)
[Server] [20:35:14 INFO]: tsxc_java[/127.0.0.1:54404] logged in with entity id 58 at ([world]1.5, 84.0, 10.5)
[MCDR] [20:35:14] [TaskExecutor/DEBUG]: Dispatching MCDREvent[id='mcdr.general_info', default_method_name='on_info'] with args (Info)
[MCDR] [20:35:14] [TaskExecutor/DEBUG]: Player joined detected
[MCDR] [20:35:14] [TaskExecutor/DEBUG]: Dispatching MCDREvent[id='mcdr.player_joined', default_method_name='on_player_joined'] with args (str, Info)
[MCDR] [20:35:22] [MainThread/DEBUG]: Parsed text from server stdout:
[MCDR] [20:35:22] [MainThread/DEBUG]:     Time: 20:35:22; ID: 1009
[MCDR] [20:35:22] [MainThread/DEBUG]:     Player: None; Source: 0; Logging level: INFO
[MCDR] [20:35:22] [MainThread/DEBUG]:     Content: tsxc_java lost connection: Disconnected
[MCDR] [20:35:22] [MainThread/DEBUG]:     Raw content: [20:35:22 INFO]: tsxc_java lost connection: Disconnected
[Server] [20:35:22 INFO]: tsxc_java lost connection: Disconnected
[MCDR] [20:35:22] [TaskExecutor/DEBUG]: Dispatching MCDREvent[id='mcdr.general_info', default_method_name='on_info'] with args (Info)
[MCDR] [20:35:22] [MainThread/DEBUG]: Parsed text from server stdout:
[MCDR] [20:35:22] [MainThread/DEBUG]:     Time: 20:35:22; ID: 1010
[MCDR] [20:35:22] [MainThread/DEBUG]:     Player: None; Source: 0; Logging level: INFO
[MCDR] [20:35:22] [MainThread/DEBUG]:     Content: tsxc_java left the game
[MCDR] [20:35:22] [MainThread/DEBUG]:     Raw content: [20:35:22 INFO]: tsxc_java left the game
[Server] [20:35:22 INFO]: tsxc_java left the game
[MCDR] [20:35:22] [TaskExecutor/DEBUG]: Dispatching MCDREvent[id='mcdr.general_info', default_method_name='on_info'] with args (Info)

@tsxc-github
Copy link
Author

此问题应该不是由PrimeBackup造成的。

@tsxc-github
Copy link
Author

tsxc-github commented Jun 1, 2024

找到问题所在了

image

可以注意到tsxc_java left the game的颜色信息(可能是?)在其中影响了玩家信息的检测,但看起来不是编码问题?

尚不知道如何解决

@Fallen-Breath
Copy link
Contributor

确认与 PrimeBackup 无关

@Fallen-Breath Fallen-Breath closed this as not planned Won't fix, can't repro, duplicate, stale Jun 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cannot reproduce The described issue is failed to be reproduced
Projects
None yet
Development

No branches or pull requests

2 participants