|-原 魔兽世界私服和魔兽世界客户端下载
https://www.dkpminus.com/wow/private-servers/
https://www.dkpminus.com/blog/vanilla-wow-download-1-12-1-client/...
|-原 mysql 重启报错,重启失败。
2025-10-06T08:27:04.914780Z 0 [Warning] option 'max_allowed_packet': unsigned value 107374182400 adjusted to 1073741824 2025-10-06T08:27:04.914979Z 0 [Warning] 'NO_ZERO_DATE', 'NO_ZERO_IN_DATE' and 'ERROR_FOR_DIVISION_BY_ZERO' sql modes should be used with strict mode. They will be merged with strict mode in a future release. 2025-10-06T08:27:04.914987Z 0 [Warning] 'NO_AUTO_CREATE_USER' sql mode was not set. 2025-10-06T08:27:04.915012Z 0 [Note] --secure-file-priv is set to NULL. Operations related to importing and exporting data are disabled 2025-10-06T08:27:04.915041Z 0 [Note] /www/server/mysql/bin/mysqld (mysqld 5.7.44-log) starting as process 85559 ... 2025-10-06T08:27:04.919351Z 0 [Warning] You need to use --log-bin to make --binlog-format work. 2025-10-06T08:27:04.934818Z 0 [Note] InnoDB: PUNCH HOLE support available 2025-10-06T08:27:04.934870Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins 2025-10-06T08:27:04.934876Z 0 [Note] InnoDB: Uses event mutexes 2025-10-06T08:27:04.934879Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier 2025-10-06T08:27:04.934885Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.13 2025-10-06T08:27:04.935330Z 0 [Note] InnoDB: Number of pools: 1 2025-10-06T08:27:04.935444Z 0 [Note] InnoDB: Using CPU crc32 instructions 2025-10-06T08:27:04.936628Z 0 [Note] InnoDB: Initializing buffer pool, total size = 512M, instances = 1, chunk size = 128M 2025-10-06T08:27:04.992772Z 0 [Note] InnoDB: Completed initialization of buffer pool 2025-10-06T08:27:05.010105Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority(). 2025-10-06T08:27:05.023372Z 0 [Note] InnoDB: Highest supported file format is Barracuda. 2025-10-06T08:27:05.044447Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables 2025-10-06T08:27:05.044529Z 0 [Note] InnoDB: Setting file '/www/server/data/ibtmp1' size to 12 MB. Physically writing the file full; Please wait ... 2025-10-06T08:27:05.087963Z 0 [Note] InnoDB: File '/www/server/data/ibtmp1' size is now 12 MB. 2025-10-06T08:27:05.089303Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active. 2025-10-06T08:27:05.089329Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active. 2025-10-06T08:27:05.090158Z 0 [Note] InnoDB: 5.7.44 started; log sequence number 2811868 2025-10-06T08:27:05.090369Z 0 [Note] InnoDB: Loading buffer pool(s) from /www/server/data/ib_buffer_pool 2025-10-06T08:27:05.090584Z 0 [Note] InnoDB: Buffer pool(s) load completed at 251006 16:27:05 2025-10-06T08:27:05.090636Z 0 [Note] Plugin 'FEDERATED' is disabled. mysqld: Table 'mysql.plugin' doesn't exist 2025-10-06T08:27:05.090833Z 0 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it. 2025-10-06T08:27:05.091488Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened. 2025-10-06T08:27:05.093354Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them. 2025-10-06T08:27:05.093377Z 0 [Note] Skipping generation of SSL certificates as certificate files are present in data directory. 2025-10-06T08:27:05.093385Z 0 [Warning] A deprecated TLS version TLSv1 is enabled. Please use TLSv1.2 or higher. 2025-10-06T08:27:05.093388Z 0 [Warning] A deprecated TLS version TLSv1.1 is enabled. Please use TLSv1.2 or higher. 2025-10-06T08:27:05.093973Z 0 [Warning] CA certificate ca.pem is self signed. 2025-10-06T08:27:05.094011Z 0 [Note] Skipping generation of RSA key pair as key files are present in data directory. 2025-10-06T08:27:05.094084Z 0 [Note] Server hostname (bind-address): '*'; port: 3306 2025-10-06T08:27:05.094128Z 0 [Note] IPv6 is available. 2025-10-06T08:27:05.094134Z 0 [Note] - '::' resolves to '::'; 2025-10-06T08:27:05.094153Z 0 [Note] Server socket created on IP: '::'. 2025-10-06T08:27:05.096829Z 0 [Warning] Failed to open optimizer cost constant tables 2025-10-06T08:27:05.096982Z 0 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.user' doesn't exist 2025-10-06T08:27:05.097013Z 0 [ERROR] Fatal error: Failed to initialize ACL/grant/time zones structures or failed to remove temporary table files. 2025-10-06T08:27:05.097091Z 0 [ERROR] Aborting 2025-10-06T08:27:05.097118Z 0 [Note] Binlog end 2025-10-06T08:27:05.097186Z 0 [Note] Shutting down plugin 'ngram' 2025-10-06T08:27:05.097193Z 0 [Note] Shutting down plugin 'partition' 2025-10-06T08:27:05.097197Z 0 [Note] Shutting down plugin 'BLACKHOLE' 2025-10-06T08:27:05.097200Z 0 [Note] Shutting down plugin 'ARCHIVE' 2025-10-06T08:27:05.097203Z 0 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA' 2025-10-06T08:27:05.097257Z 0 [Note] Shutting down plugin 'MRG_MYISAM' 2025-10-06T08:27:05.097260Z 0 [Note] Shutting down plugin 'MyISAM' 2025-10-06T08:27:05.097275Z 0 [Note] Shutting down plugin 'INNODB_SYS_VIRTUAL' 2025-10-06T08:27:05.097279Z 0 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES' 2025-10-06T08:27:05.097282Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES' 2025-10-06T08:27:05.097285Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS' 2025-10-06T08:27:05.097288Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN' 2025-10-06T08:27:05.097290Z 0 [Note] Shutting down plugin 'INNODB_SYS_FIELDS' 2025-10-06T08:27:05.097293Z 0 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS' 2025-10-06T08:27:05.097296Z 0 [Note] Shutting down plugin 'INNODB_SYS_INDEXES' 2025-10-06T08:27:05.097299Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS' 2025-10-06T08:27:05.097301Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLES' 2025-10-06T08:27:05.097304Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE' 2025-10-06T08:27:05.097307Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE' 2025-10-06T08:27:05.097310Z 0 [Note] Shutting down plugin 'INNODB_FT_CONFIG' 2025-10-06T08:27:05.097312Z 0 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED' 2025-10-06T08:27:05.097315Z 0 [Note] Shutting down plugin 'INNODB_FT_DELETED' 2025-10-06T08:27:05.097317Z 0 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD' 2025-10-06T08:27:05.097320Z 0 [Note] Shutting down plugin 'INNODB_METRICS' 2025-10-06T08:27:05.097323Z 0 [Note] Shutting down plugin 'INNODB_TEMP_TABLE_INFO' 2025-10-06T08:27:05.097325Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS' 2025-10-06T08:27:05.097328Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU' 2025-10-06T08:27:05.097330Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE' 2025-10-06T08:27:05.097333Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET' 2025-10-06T08:27:05.097336Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX' 2025-10-06T08:27:05.097338Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET' 2025-10-06T08:27:05.097341Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM' 2025-10-06T08:27:05.097344Z 0 [Note] Shutting down plugin 'INNODB_CMP_RESET' 2025-10-06T08:27:05.097347Z 0 [Note] Shutting down plugin 'INNODB_CMP' 2025-10-06T08:27:05.097349Z 0 [Note] Shutting down plugin 'INNODB_LOCK_WAITS' 2025-10-06T08:27:05.097352Z 0 [Note] Shutting down plugin 'INNODB_LOCKS' 2025-10-06T08:27:05.097355Z 0 [Note] Shutting down plugin 'INNODB_TRX' 2025-10-06T08:27:05.097357Z 0 [Note] Shutting down plugin 'InnoDB' 2025-10-06T08:27:05.097468Z 0 [Note] InnoDB: FTS optimize thread exiting. 2025-10-06T08:27:05.097606Z 0 [Note] InnoDB: Starting shutdown... 2025-10-06T08:27:05.198024Z 0 [Note] InnoDB: Dumping buffer pool(s) to /www/server/data/ib_buffer_pool 2025-10-06T08:27:05.198252Z 0 [Note] InnoDB: Buffer pool(s) dump completed at 251006 16:27:05 2025-10-06T08:27:06.512887Z 0 [Note] InnoDB: Shutdown completed; log sequence number 2811887 2025-10-06T08:27:06.514962Z 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1" 2025-10-06T08:27:06.514993Z 0 [Note] Shutting down plugin 'MEMORY' 2025-10-06T08:27:06.515000Z 0 [Note] Shutting down plugin 'CSV' 2025-10-06T08:27:06.515004Z 0 [Note] Shutting down plugin 'sha256_password' 2025-10-06T08:27:06.515006Z 0 [Note] Shutting down plugin 'mysql_native_password' 2025-10-06T08:27:06.515148Z 0 [Note] Shutting down plugin 'binlog' 2025-10-06T08:27:06.516999Z 0 [Note] /www/server/mysql/bin/mysqld: Shutdown complete
20251006 1628 ...
|-原 WOW 202510
ss -tulnp | grep -E '80|443'
set realmlist 137.184.177.199:80
# 修改 .env 文件中的端口映射 sed -i 's/DOCKER_AUTH_EXTERNAL_PORT=.*/DOCKER_AUTH_EXTERNAL_PORT=80/' /opt/azerothcore-wotlk/.env sed -i 's/DOCKER_WORLD_EXTERNAL_PORT=.*/DOCKER_WORLD_EXTERNAL_PORT=443/' /opt/azerothcore-wotlk/.env # 修改 authserver.conf 文件 sed -i 's/RealmServerPort.*/RealmServerPort = 80/' /opt/azerothcore-wotlk/env/dist/etc/authserver.conf # 修改 worldserver.conf 文件 sed -i 's/WorldServerPort.*/WorldServerPort = 443/' /opt/azerothcore-wotlk/env/dist/etc/worldserver.conf # 重启容器 docker compose down && docker compose up -d
20251006 ...
|-原 aaPanel 一键安装 MySQL 5.7 后,**「重启 MySQL」按钮(或 systemctl restart mysql)总是失败
现在整机扫描mysqld.service
sudo find / -name mysqld.service -type f 2>/dev/null
Kimi:
问题复盘:aaPanel 一键安装 MySQL 5.7 后,**「重启 MySQL」按钮(或 systemctl restart mysql)总是失败**,日志只看到 mysqld 干净退出,无端口冲突报错。
根因
aaPanel 把 MySQL 程序和数据放在非标准路径(`/www/server/mysql` + `/www/server/data`),却**没有生成永久的 systemd 单元文件**;系统默认的 `mysql.service` 指向 `/var/lib/mysql`,路径不对,启动即失败。
表象
```
systemctl restart mysql → 失败
systemctl status mysql → 找不到服务或路径错误
/run/systemd/generator.late/mysqld.service 是唯一生成的临时单元,重启后消失。
```
解决办法(三步)
1. 找到真实单元
```bash
sudo find / -name mysqld.service -type f
```
通常返回:
`/run/systemd/generator.late/mysqld.service`
2. 重载并立即启动
```bash
sudo systemctl daemon-reload
sudo systemctl restart mysqld # 注意服务名是 mysqld 不是 mysql
sudo systemctl status mysqld # 确认 active (running)
```
3. 转成永久开机单元(可选但强烈建议)
```bash
sudo cp /run/systemd/generator.late/mysqld.service /etc/systemd/system/
sudo systemctl enable mysqld
```
结果
- 面板「重启 MySQL」按钮正常
- 服务器重启后 MySQL 自启且路径正确 ...
|-原 宝塔创建数据库默认要用不同的,否则提示已经存在,phpmyadmin进去后老是提示红色的,你看下phpmyadimin上的问题Warning in ./libraries/classes/Config.php
sudo chown -R www:www /www/server/phpmyadmin/tmp
sudo chmod -R 755 /www/server/phpmyadmin/tmp
提示不存在则去找的实际的目录比如
sudo chown -R www:www /www/server/phpmyadmin/phpmyadmin_ecccf751e/tmp
sudo chmod -R 755 /www/server/phpmyadmin/phpmyadmin_ecccf751e/tmp
宝塔创建数据库默认要用不同的,否则提示已经存在,phpmyadmin进去后老是提示红色的,你看下phpmyadimin上的问题 ...
|-原 docker 安装魔兽世界
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:~# cd /opt/azerothcore-wotlk ./acore.sh compiler all NOTICE: file not found, we use default configuration only. NOTICE: file not found, we use default configuration only. Running hooks: HOOKS_MAP_ON_AFTER_OPTIONS Cleaning build files in /opt/azerothcore-wotlk/var/build/obj Build path: /opt/azerothcore-wotlk/var/build/obj DEBUG info: OFF Compilation type: Release CCache: false Platform: linux-gnu -- CMake version: 3.28.3 -- The CXX compiler identification is Clang 18.1.3 -- The C compiler identification is Clang 18.1.3 -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /usr/bin/clang++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: /usr/bin/clang - skipped -- Detecting C compile features -- Detecting C compile features - done -- Running cmake hook: AFTER_LOAD_CONF -- No hooks registered for AFTER_LOAD_CONF -- Enabled С++20 standard -- Detected 64-bit platform -- UNIX: Using jemalloc -- UNIX: Using default configuration directory -- UNIX: Using default library directory -- UNIX: Configuring uninstall target -- UNIX: Created uninstall target -- UNIX: Detected compiler: /usr/bin/clang -- Clang: Minimum version required is 10.0.0, found 18.1.3 - ok! -- Performing Test CLANG_HAVE_PROPER_CHARCONV -- Performing Test CLANG_HAVE_PROPER_CHARCONV - Success -- Clang: All warnings enabled -- Running cmake hook: AFTER_LOAD_CMAKE_MODULES -- No hooks registered for AFTER_LOAD_CMAKE_MODULES -- Using mysql-config: /usr/bin/mysql_config -- Found MySQL: CMake Error at src/cmake/macros/FindMySQL.cmake:64 (message): MySQL version found (5.7.44) is less than the required version (8.0) Call Stack (most recent call first): src/cmake/macros/FindMySQL.cmake:319 (check_mysql_version) CMakeLists.txt:109 (find_package) -- Configuring incomplete, errors occurred! root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk#
20251007 0725 ...
|-原 国内主机-aaPanel面板搭建魔兽世界服务器
把下面这一行写进 全局 bash 启动脚本 即可,无论谁登录、无论是不是交互式 shell 都会生效
sudo tee -a /etc/bash.bashrc >/dev/null <<< "alias ac='cd /opt/azerothcore-wotlk'"
source /etc/bash.bashrc
# 1. 拉镜像 cd /opt git clone https://github.com/azerothcore/azerothcore-wotlk.git cd /opt/azerothcore-wotlk # 2. 一键下载客户端数据(自动下官方 3.3.5a 客户端 + 提取地图) ./acore.sh docker client-data # 2.5文件权限设置 sudo chown -R 1000:1000 /opt/azerothcore-wotlk/env/dist # 2.6 授权 root 远程登录(容器来的连接会被当成“远程”) sudo mysql -u root -p -- 授权 root 从任意地址连接 GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION; FLUSH PRIVILEGES; exit sudo ufw allow 3780 sudo ufw allow 8086 # 3. 编译 + 初始化数据库 ./acore.sh docker build ./acore.sh docker start:app # 4. 建个 GM 账号 docker exec -it ac-worldserver bash # 进容器后 account create test 123456 account set gmlevel test 3 -1 exit
20251008 0819
root@iv-ye6dm944cgbw80bfp6qc:/# cd /opt root@iv-ye6dm944cgbw80bfp6qc:/opt# ll total 16 drwxrwxrwx 4 root root 4096 Oct 8 02:53 ./ drwxr-xr-x 26 root root 4096 Oct 8 02:30 ../ drwxrwxrwx 4 root root 4096 Oct 8 02:53 containerd/ drwxrwxrwx 3 root root 4096 Mar 14 2025 proxima/ root@iv-ye6dm944cgbw80bfp6qc:/opt# git clone https://github.com/azerothcore/azerothcore-wotlk.git Cloning into 'azerothcore-wotlk'... remote: Enumerating objects: 186580, done. remote: Counting objects: 100% (254/254), done. remote: Compressing objects: 100% (135/135), done. error: RPC failed; curl 56 Recv failure: Connection reset by peer error: 3278 bytes of body are still expected fetch-pack: unexpected disconnect while reading sideband packet fatal: early EOF fatal: fetch-pack: invalid index-pack output root@iv-ye6dm944cgbw80bfp6qc:/opt# ll total 16 drwxrwxrwx 4 root root 4096 Oct 8 08:42 ./ drwxr-xr-x 26 root root 4096 Oct 8 02:30 ../ drwxrwxrwx 4 root root 4096 Oct 8 02:53 containerd/ drwxrwxrwx 3 root root 4096 Mar 14 2025 proxima/ root@iv-ye6dm944cgbw80bfp6qc:/opt#
20251008 0848 ...
|-原 azerothcore-wotlk 编译 + 初始化数据库
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# # 3. 编译 + 初始化数据库
./acore.sh docker build
./acore.sh docker start:app
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# # 3. 编译 + 初始化数据库 ./acore.sh docker build ./acore.sh docker start:app NOTICE: file not found, we use default configuration only. + docker compose build [+] Building 254.0s (23/42) [+] Building 2105.5s (48/48) FINISHED => [internal] load local bake definitions 0.0s => => reading from stdin 2.56kB 0.0s => [ac-db-import internal] load build definition from Dockerfile 0.0s => => transferring dockerfile: 8.37kB 0.0s => [ac-worldserver internal] load metadata for docker.io/library/ubuntu:22.04 6.8s => [ac-worldserver internal] load .dockerignore 0.0s => => transferring context: 261B 0.0s => [ac-db-import internal] load build context 63.1s => => transferring context: 2.02GB 63.1s => [ac-worldserver skeleton 1/4] FROM docker.io/library/ubuntu:22.04@sha256:09506232a8004baa32c47d68f1e5c307d648fdd59f5e7eaa42aaf87914100db3 0.1s => => resolve docker.io/library/ubuntu:22.04@sha256:09506232a8004baa32c47d68f1e5c307d648fdd59f5e7eaa42aaf87914100db3 0.0s => => sha256:09506232a8004baa32c47d68f1e5c307d648fdd59f5e7eaa42aaf87914100db3 6.69kB / 6.69kB 0.0s => => sha256:4cb780d50443fc4463f1f9360c03ca46512e4fdd8fd97c5ce7e69c8758924575 424B / 424B 0.0s => => sha256:392fa14dddd09da29a5c3d26948ff81c494424035b755d01b84ab12d92127433 2.30kB / 2.30kB 0.0s => [ac-worldserver internal] load build context 50.7s => => transferring context: 1.19GB 50.6s => [ac-client-data-init internal] load build context 0.2s => => transferring context: 524.95kB 0.1s => [ac-client-data-init skeleton 2/4] RUN mkdir -pv /azerothcore/bin /azerothcore/data /azerothcore/deps 0.5s => [ac-worldserver skeleton 3/4] RUN apt-get update && apt-get install -y --no-install-recommends tzdata ca-certificate 22.2s => [ac-authserver skeleton 4/4] WORKDIR /azerothcore 0.0s => [ac-client-data-init client-data 1/2] RUN apt-get update && apt-get install -y curl unzip && rm -rf /var/lib/apt/lists/* 24.5s => [ac-authserver build 1/8] RUN apt-get update && apt-get install -y --no-install-recommends 67.2s => [ac-worldserver runtime 1/4] RUN apt-get update && apt-get install -y --no-install-recommends libmysqlclient21 libreadline8 gettext-base default-mysql-client 25.0s => [ac-client-data-init client-data 2/2] COPY --chown=: apps apps 0.4s => [ac-client-data-init] exporting to image 1.4s => => exporting layers 1.3s => => writing image sha256:93cdafc90fb4100583f17aa846c26b56fd85d9d01831711c6a8c9bda49bab342 0.0s => => naming to docker.io/acore/ac-wotlk-client-data:master 0.0s => [ac-client-data-init] resolving provenance for metadata file 0.1s => [ac-db-import build 2/8] COPY CMakeLists.txt /azerothcore/CMakeLists.txt 0.0s => [ac-worldserver build 3/8] COPY conf /azerothcore/conf 0.0s => [ac-worldserver build 4/8] COPY deps /azerothcore/deps 0.3s => [ac-authserver build 5/8] COPY src /azerothcore/src 0.6s => [ac-authserver build 6/8] COPY modules /azerothcore/modules 0.0s => [ac-db-import build 7/8] WORKDIR /azerothcore/build 0.0s => [ac-worldserver build 8/8] RUN --mount=type=cache,target=/ccache,sharing=locked --mount=type=bind,target=/azerothcore/.git,source=.git git config --global --add saf 1994.9s => [ac-worldserver runtime 2/4] COPY --from=build /azerothcore/env/dist/etc/ /azerothcore/env/ref/etc 0.0s => [ac-authserver runtime 3/4] RUN groupadd --gid "1000" "acore" && useradd -d /azerothcore --uid "1000" --gid "1000" "acore" && passwd -d "acore" && chown -R "aco 0.3s => [ac-db-import runtime 4/4] COPY --chown=1000:1000 --chmod=755 apps/docker/entrypoint.sh /azerothcore/entrypoint.sh 0.1s => CACHED [ac-worldserver build 2/8] COPY CMakeLists.txt /azerothcore/CMakeLists.txt 0.0s => CACHED [ac-worldserver build 3/8] COPY conf /azerothcore/conf 0.0s => CACHED [ac-worldserver build 4/8] COPY deps /azerothcore/deps 0.0s => CACHED [ac-worldserver build 5/8] COPY src /azerothcore/src 0.0s => CACHED [ac-worldserver build 6/8] COPY modules /azerothcore/modules 0.0s => CACHED [ac-worldserver build 7/8] WORKDIR /azerothcore/build 0.0s => CACHED [ac-worldserver build 8/8] RUN --mount=type=cache,target=/ccache,sharing=locked --mount=type=bind,target=/azerothcore/.git,source=.git git config --global --add 0.0s => CACHED [ac-worldserver runtime 2/4] COPY --from=build /azerothcore/env/dist/etc/ /azerothcore/env/ref/etc 0.0s => CACHED [ac-worldserver runtime 3/4] RUN groupadd --gid "1000" "acore" && useradd -d /azerothcore --uid "1000" --gid "1000" "acore" && passwd -d "acore" && chown 0.0s => CACHED [ac-worldserver runtime 4/4] COPY --chown=1000:1000 --chmod=755 apps/docker/entrypoint.sh /azerothcore/entrypoint.sh 0.0s => [ac-authserver authserver 1/1] COPY --chown=acore:acore --from=build /azerothcore/env/dist/bin/authserver /azerothcore/env/dist/bin/authserver 0.1s => [ac-db-import db-import 1/3] COPY --chown=acore:acore data data 5.4s => [ac-worldserver worldserver 1/1] COPY --chown=acore:acore --from=build /azerothcore/env/dist/bin/worldserver /azerothcore/env/dist/bin/worldserver 0.6s => [ac-authserver] exporting to image 1.1s => => exporting layers 1.0s => => writing image sha256:b3f8e0d6a70be4d2c27f3f42139886a70a124bfe6c4b0007f218690ab0f9353e 0.0s => => naming to docker.io/acore/ac-wotlk-authserver:master 0.0s => [ac-worldserver] exporting to image 2.7s => => exporting layers 2.6s => => writing image sha256:9a8ec0c842369a73f1dbbbb2f8f422fc65394acfdc94ea8cf35f8dd3de1c1557 0.0s => => naming to docker.io/acore/ac-wotlk-worldserver:master 0.0s => [ac-authserver] resolving provenance for metadata file 0.0s => [ac-worldserver] resolving provenance for metadata file 0.0s => [ac-db-import db-import 2/3] COPY --chown=acore:acore modules modules 0.0s => [ac-db-import db-import 3/3] COPY --chown=acore:acore --from=build /azerothcore/env/dist/bin/dbimport /azerothcore/env/dist/bin/dbimport 0.1s => [ac-db-import] exporting to image 5.0s => => exporting layers 5.0s => => writing image sha256:ee2a97f8761ee1f60a5e01cd89ea17c8fe52ab37664886f1bf6d015ce55716ea 0.0s => => naming to docker.io/acore/ac-wotlk-db-import:master 0.0s => [ac-db-import] resolving provenance for metadata file 0.0s [+] Building 4/4 ✔ acore/ac-wotlk-worldserver:master Built 0.0s ✔ acore/ac-wotlk-authserver:master Built 0.0s ✔ acore/ac-wotlk-client-data:master Built 0.0s ✔ acore/ac-wotlk-db-import:master Built 0.0s + set +x NOTICE: file not found, we use default configuration only. + docker compose up [+] Running 5/5 ✔ Network azerothcore-wotlk_ac-network Created 0.1s ✔ Container ac-db-import Created 0.1s ✔ Container ac-client-data-init Recreated 0.1s ✔ Container ac-authserver Created 0.0s ✔ Container ac-worldserver Created 0.0s Attaching to ac-authserver, ac-client-data-init, ac-db-import, ac-worldserver ac-client-data-init | ####################### ac-client-data-init | Client data downloader ac-client-data-init | ####################### ac-client-data-init | /azerothcore/apps/installer/includes/functions.sh: line 146: /includes/modules-manager/modules.sh: No such file or directory ac-client-data-init | Data v16 already installed. If you want to force the download remove the following file: /azerothcore/env/dist/data/data-version ac-db-import | touch: cannot touch '/azerothcore/env/dist/etc/.write-test': Permission denied ac-db-import | ===== WARNING ===== ac-db-import | The current user doesn't have write permissions for ac-db-import | the configuration dir (/azerothcore/env/dist/etc) or logs dir (/azerothcore/env/dist/logs). ac-db-import | It's likely that services will fail due to this. ac-db-import | ac-db-import | This is usually caused by cloning the repository as root, ac-db-import | so the files are owned by root (uid 0). ac-db-import | ac-db-import | To resolve this, you can set the ownership of the ac-db-import | configuration directory with the command on the host machine. ac-db-import | Note that if the files are owned as root, the ownership must ac-db-import | be changed as root (hence sudo). ac-db-import | ac-db-import | $ sudo chown -R 1000:1000 /path/to/azerothcore/env/dist/etc /path/to/azerothcore/env/dist/logs ac-db-import | ac-db-import | Alternatively, you can set the DOCKER_USER environment ac-db-import | variable (on the host machine) to "root", though this ac-db-import | isn't recommended. ac-db-import | ac-db-import | $ DOCKER_USER=root docker-compose up -d ac-db-import | ==================== ac-db-import | cp: cannot create regular file '/azerothcore/env/dist/etc/authserver.conf.dist': Permission denied ac-db-import | cp: cannot create regular file '/azerothcore/env/dist/etc/dbimport.conf.dist': Permission denied ac-db-import | cp: cannot create regular file '/azerothcore/env/dist/etc/worldserver.conf.dist': Permission denied ac-db-import | '/azerothcore/env/ref/etc/authserver.conf.dist' -> '/azerothcore/env/dist/etc/authserver.conf.dist' ac-db-import | '/azerothcore/env/ref/etc/dbimport.conf.dist' -> '/azerothcore/env/dist/etc/dbimport.conf.dist' ac-db-import | '/azerothcore/env/ref/etc/worldserver.conf.dist' -> '/azerothcore/env/dist/etc/worldserver.conf.dist' ac-client-data-init exited with code 0 ac-db-import exited with code 1 service "ac-db-import" didn't complete successfully: exit 1 root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk#
20251008 1021 ...
|-原 非国内主机-aaPanel面板搭建魔兽世界服务器
docker port ac-worldserver
# 1. 拉镜像 cd /opt git clone https://github.com/azerothcore/azerothcore-wotlk.git cd /opt/azerothcore-wotlk # 2. 一键下载客户端数据(自动下官方 3.3.5a 客户端 + 提取地图) ./acore.sh docker client-data # 2.5文件权限设置 sudo chown -R 1000:1000 /opt/azerothcore-wotlk/env/dist # 2.6 授权 root 远程登录(容器来的连接会被当成“远程”) sudo mysql -u root -p -- 授权 root 从 172.19.0.% 网段登录,密码与本地一致 GRANT ALL PRIVILEGES ON *.* TO 'root'@'172.19.0.%' IDENTIFIED BY 'password' WITH GRANT OPTION; -- 刷新权限 FLUSH PRIVILEGES; exit sudo ufw allow 3780 sudo ufw allow 8086 nano /opt/azerothcore-wotlk/.env DOCKER_DB_ROOT_PASSWORD=你的mysql数据库root的密码 # 3. 编译 + 初始化数据库 ./acore.sh docker build ./acore.sh docker start:app # 4. 建个 GM 账号 docker exec -it ac-worldserver bash # 进容器后 account create test 123456 account set gmlevel test 3 -1 exit
20251008 1107 ...
|-原 如何快速定位是哪份代码在退出
cd /opt/azerothcore-wotlk
grep -r "AzerothCore does not support MySQL versions below 8.0" src/
src/server/database/Database/DatabaseWorkerPool.cpp: WPFatal(isSupportClientDB, "AzerothCore does not support MySQL versions below 8.0\n\nFound version: {} / {}. Server compiled with: {}.\nSearch the wiki for ACE00043 in Common Errors (https://www.azerothcore.org/wiki/common-errors#ace00043).",
src/server/database/Database/DatabaseWorkerPool.cpp: LOG_ERROR("sql.driver", "AzerothCore does not support MySQL versions below 8.0\n\nFound server version: {}. Server compiled with: {}.",
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk#
+ docker compose up [+] Running 3/3 ✔ Container ac-db-import Recreated 0.1s ✔ Container ac-authserver Recreated 0.1s ✔ Container ac-worldserver Recreated 0.1s Attaching to ac-authserver, ac-client-data-init, ac-db-import, ac-worldserver ac-db-import | Starting dbimport... ac-client-data-init | ####################### ac-client-data-init | Client data downloader ac-client-data-init | ####################### ac-client-data-init | /azerothcore/apps/installer/includes/functions.sh: line 146: /includes/modules-manager/modules.sh: No such file or directory ac-client-data-init | Data v16 already installed. If you want to force the download remove the following file: /azerothcore/env/dist/data/data-version ac-db-import | >>> Bypass MySQL 8.0 check, allow 5.7 <<< ac-db-import | AzerothCore does not support MySQL versions below 8.0 ac-db-import | ac-db-import | Found server version: 5.7.44-log. Server compiled with: 80043. ac-client-data-init exited with code 0
20251008 ...
|-原 docker exec -it ac-worldserver cat /etc/hosts 172.17.0.1 host.docker.internal
docker exec -it ac-worldserver cat /etc/hosts
重要命令
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# docker exec -it ac-worldserver cat /etc/hosts 127.0.0.1 localhost ::1 localhost ip6-localhost ip6-loopback fe00:: ip6-localnet ff00:: ip6-mcastprefix ff02::1 ip6-allnodes ff02::2 ip6-allrouters 172.17.0.1 host.docker.internal 172.18.0.3 e58b81a118e4 root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk#
20251008 1724 ...
|-原 關鍵命令docker logs -f --tail 30 ac-authserver & docker logs -f --tail 30 ac-worldserver &
docker logs -f --tail 30 ac-authserver &
docker logs -f --tail 30 ac-worldserver &
docker exec ac-worldserver ss -tln | grep 8085 查看容器内部的端口8085有沒有被監聽。
docker compose restart ac-worldserver
---------------------------------------------------------------------------------------------------------------
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# docker exec ac-worldserver strings /usr/local/bin/worldserver | grep -i worldsocket
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk#
docker logs --tail 200 ac-worldserver | less
============================================
docker compose build --no-cache ac-worldserver 2>&1 | tee build.log
docker ps --format "table {{.Names}}\t{{.Status}}\t{{.Image}}"
docker logs -f --tail 30 ac-authserver &
docker logs -f --tail 30 ac-worldserver &
sudo ufw allow from 172.17.0.0/16 to any port 3306 ...
|-原 關鍵報錯 WOW 服務器
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# docker logs --tail 30 ac-authserver
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# docker logs --tail 30 ac-worldserver
查看所有被監聽的端口
sudo ss -tulnp
各参数含义
-t TCP
-u UDP
-l 正在 监听 的套接字(listen)
-n 不把端口解析成服务名,直接显示数字
-p 显示占用该端口的进程 PID 与名称(需要 root 才能看到所有进程)
如果你想看得更“全”一点(包括 UNIX 域套接字、RAW、分组接口等),可以再加 -a:
sudo ss -tulnap
老机器上没有 ss 时,可退而求其次用 netstat:
sudo netstat -tulnp
只想快速扫一遍“哪些 TCP/UDP 端口处于 LISTEN 状态”,也可以:
sudo lsof -i -P -n | grep LISTEN
总结:
推荐 → sudo ss -tulnp
兼容老系统 → sudo netstat -tulnp
關鍵報錯
Welcome to Ubuntu 24.04.3 LTS (GNU/Linux 6.8.0-71-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/pro
System information as of Wed Oct 8 13:54:14 UTC 2025
System load: 0.88 Processes: 205
Usage of /: 21.4% of 153.94GB Users logged in: 1
Memory usage: 51% IPv4 address for eth0: 137.184.177.199
Swap usage: 0% IPv4 address for eth0: 10.48.0.5
Expanded Security Maintenance for Applications is not enabled.
16 updates can be applied immediately.
To see these additional updates run: apt list --upgradable
6 additional security updates can be applied with ESM Apps.
Learn more about enabling ESM Apps service at https://ubuntu.com/esm
*** System restart required ***
Last login: Wed Oct 8 13:35:21 2025 from 218.18.207.209
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:~# mysql -uroot -p acore_auth -e "UPDATE realmlist SET port = 3780 WHERE id = 1;"
Enter password:
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:~# ac
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# docker compose up -d --force-recreate ac-worldserver
[+] Running 3/3
✔ Container ac-worldserver Started 3.4s
✔ Container ac-client-data-init Exited 0.7s
✔ Container ac-db-import Exited 1.7s
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# docker logs -f --tail 30 ac-authserver &
docker logs -f --tail 30 ac-worldserver &
[1] 165309
[2] 165310
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# Started auth database connection pool.
Loading IP Location Database...
Added realm "AzerothCore" at 137.184.177.199:3780.
SQL(p): DELETE FROM ip_banned WHERE unbandate<>bandate AND unbandate<=UNIX_TIMESTAMP()
[ERROR]: [2013] Lost connection to MySQL server during query
Lost the connection to the MySQL server!
Attempting to reconnect to the MySQL server...
Connected to MySQL database at host.docker.internal
Successfully reconnected to acore_auth @host.docker.internal:3306 (asynchronous).
SQL(p): SELECT id, name, address, localAddress, localSubnetMask, port, icon, flag, timezone, allowedSecurityLevel, population, gamebuild FROM realmlist WHERE flag <> 3 ORDER BY name
[ERROR]: [2013] Lost connection to MySQL server during query
Lost the connection to the MySQL server!
Attempting to reconnect to the MySQL server...
Connected to MySQL database at host.docker.internal
Successfully reconnected to acore_auth @host.docker.internal:3306 (synchronous).
SQL(p): SELECT id, name, address, localAddress, localSubnetMask, port, icon, flag, timezone, allowedSecurityLevel, population, gamebuild FROM realmlist WHERE flag <> 3 ORDER BY name
[ERROR]: [2013] Lost connection to MySQL server during query
Lost the connection to the MySQL server!
Attempting to reconnect to the MySQL server...
Could not connect to MySQL database at host.docker.internal: Can't connect to MySQL server on 'host.docker.internal:3306' (111)
Attempting to reconnect to the MySQL server...
Connected to MySQL database at host.docker.internal
Successfully reconnected to acore_auth @host.docker.internal:3306 (synchronous).
SQL(p): DELETE FROM ip_banned WHERE unbandate<>bandate AND unbandate<=UNIX_TIMESTAMP()
[ERROR]: [2013] Lost connection to MySQL server during query
Lost the connection to the MySQL server!
Attempting to reconnect to the MySQL server...
Connected to MySQL database at host.docker.internal
Successfully reconnected to acore_auth @host.docker.internal:3306 (asynchronous).
Deleting Expired Bans...
Calculate Next Daily Quest Reset Time...
Calculate Next Weekly Quest Reset Time...
Calculate Next Monthly Quest Reset Time...
Calculate Random Battleground Reset Time...
Calculate Deletion Of Old Calendar Events Time...
Calculate Guild Cap Reset Time...
Load Petitions...
>> Loaded 0 Petitions!
Load Petition Signs...
>> Loaded 0 Petition signs!
Load Stored Loot Items...
>> Loaded 0 stored items!
Load Channel Rights...
>> Loaded 0 Channel Rights!
Load Channels...
>> Loaded 0 channels. DB table `channels` is empty.
Loading AntiDos opcode policies
>> Loaded 102 AntiDos Opcode Policies in 0 ms
WORLD: World Initialized In 0 Minutes 8 Seconds
AzerothCore rev. 2c5aab9ed287+ 2025-10-07 09:41:15 +0200 (master branch) (Unix, RelWithDebInfo, Static) (worldserver-daemon) ready...
AC> Calendar deletion of old events.
ss -lntp | grep :3306^C
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# ll
total 184
drwxr-xr-x 16 root root 4096 Oct 8 13:43 ./
drwxr-xr-x 6 root root 4096 Oct 8 01:28 ../
drwxr-xr-x 2 root root 4096 Oct 8 00:31 .devcontainer/
-rw-r--r-- 1 root root 219 Oct 8 00:31 .dockerignore
-rw-r--r-- 1 root root 325 Oct 8 00:31 .editorconfig
-rw-r--r-- 1 www www 366 Oct 8 13:52 .env
drwxr-xr-x 8 root root 4096 Oct 8 00:31 .git/
-rw-r--r-- 1 root root 2264 Oct 8 00:31 .git_commit_template.txt
-rw-r--r-- 1 root root 894 Oct 8 00:31 .gitattributes
drwxr-xr-x 5 root root 4096 Oct 8 00:31 .github/
-rw-r--r-- 1 root root 1249 Oct 8 00:31 .gitignore
-rw-r--r-- 1 root root 14 Oct 8 00:31 .suppress.cppcheck
drwxr-xr-x 2 root root 4096 Oct 8 00:31 .vscode/
-rw-r--r-- 1 root root 3093 Oct 8 00:31 AUTHORS
-rw-r--r-- 1 root root 4835 Oct 8 00:31 CMakeLists.txt
-rw-r--r-- 1 root root 34520 Oct 8 00:31 LICENSE
-rw-r--r-- 1 root root 908 Oct 8 00:31 PreLoad.cmake
-rw-r--r-- 1 root root 92 Oct 8 00:31 acore.json
-rwxr-xr-x 1 root root 159 Oct 8 00:31 acore.sh*
drwxr-xr-x 19 root root 4096 Oct 8 00:31 apps/
drwxr-xr-x 2 root root 4096 Oct 8 00:31 bin/
drwxr-xr-x 3 root root 4096 Oct 8 00:31 conf/
drwxr-xr-x 3 root root 4096 Oct 8 00:31 data/
drwxr-xr-x 23 root root 4096 Oct 8 00:31 deps/
drwxr-xr-x 3 root root 4096 Oct 8 00:31 doc/
-rw-r--r-- 1 root root 7844 Oct 8 01:21 docker-compose.bak.yml
-rw-r--r-- 1 root root 6886 Oct 8 13:52 docker-compose.yml
drwxr-xr-x 4 root root 4096 Oct 8 00:31 env/
-rw-r--r-- 1 root root 1582 Oct 8 00:31 flake.lock
-rw-r--r-- 1 root root 864 Oct 8 00:31 flake.nix
-rwxr-xr-x 1 root root 149 Oct 8 00:31 install.sh*
drwxr-xr-x 2 root root 4096 Oct 8 00:31 modules/
-rw-r--r-- 1 root root 3183 Oct 8 00:31 pull_request_template.md
drwxr-xr-x 8 root root 4096 Oct 8 00:31 src/
drwxr-xr-x 6 root root 4096 Oct 8 00:31 var/
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# ss -lntp | grep :3306
LISTEN 0 150 0.0.0.0:3306 0.0.0.0:* users:(("mysqld",pid=161356,fd=59))
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# sudo ufw allow from 172.17.0.0/16 to any port 3306
sudo ufw reload
Rule added
Firewall reloaded
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# mysql -uroot -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 109
Server version: 5.7.44-log Source distribution
Copyright (c) 2000, 2023, Oracle and/or its affiliates.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> -- 1. 收回“全网”钥匙
mysql> REVOKE ALL ON *.* FROM 'acore'@'%';
Query OK, 0 rows affected (0.00 sec)
mysql>
mysql> -- 2. 只开 3 个库 + 只给容器网段
mysql> GRANT ALL PRIVILEGES ON acore_auth.* TO 'acore'@'172.17.%.%';
Query OK, 0 rows affected, 1 warning (0.00 sec)
mysql> GRANT ALL PRIVILEGES ON acore_world.* TO 'acore'@'172.17.%.%';
Query OK, 0 rows affected (0.00 sec)
mysql> GRANT ALL PRIVILEGES ON acore_characters.* TO 'acore'@'172.17.%.%';
Query OK, 0 rows affected (0.00 sec)
mysql> FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.00 sec)
mysql> DROP USER 'root'@'%';
Query OK, 0 rows affected (0.00 sec)
mysql> -- 只留本地
mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' WITH GRANT OPTION;
Query OK, 0 rows affected, 1 warning (0.00 sec)
mysql> exit
Bye
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk#
20251008 2210 ...
|-原 /opt/azerothcore-wotlk# docker exec ac-worldserver strings /usr/local/bin/worldserver | grep -i worldsocket
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk# docker exec ac-worldserver strings /usr/local/bin/worldserver | grep -i worldsocket
root@ubuntu-s-2vcpu-8gb-160gb-intel-sfo3-01:/opt/azerothcore-wotlk#
你**自己确实没手动加过**`-DWITHOUT_NETWORK=1`,但 AzerothCore 的 **docker-compose.yml** 里默认就带了一个环境变量/编译参数,**只要勾了 tools-only 或者用了 dev-server profile,就会自动把网络关掉**——这就是很多人“明明没动过”却监听不了 8085 的根源。
下面给你**两分钟自检**到底在哪一步被静默加了 `WITHOUT_NETWORK`。
------------------------------------------------
1. 先看当前 compose 文件有没有“陷阱”
------------------------------------------------
```bash
grep -n -i 'without\|tools\|dev' docker-compose.yml...
|-原 acore 創建管理員賬號
acore用mysql是宿主機上的mysql
sudo mysql -u root -p <<'EOF'
USE acore_auth;
INSERT INTO account (username, salt, verifier, email, reg_mail, joindate)
VALUES ('admin', '11', '11', 'admin@localhost', 'admin@localhost', NOW())
ON DUPLICATE KEY UPDATE username='admin';
-- 把账号设 GM 等级 3(最高)
INSERT INTO account_access (id, gmlevel, RealmID)
SELECT id, 3, -1 FROM account WHERE username='admin'
ON DUPLICATE KEY UPDATE gmlevel=3;
EOF
20251010 1519 ...
|-原 progression_requirement表不是项目的表https://github.com/ZhengPeiRu21/mod-individual-progression
progression_requirement不是项目的表,我现在需要你先审核下文件pro_race.sh,对这个脚本进行评估,判断是否能做到不完成boss击杀就会锁经验的功能。
https://github.com/ZhengPeiRu21/mod-individual-progression/tree/master/data/sql/world/base
明白,你要的是对 pro_race.sh 的“功能评估”:它是否能实现“没完成指定 Boss 击杀前,角色经验被锁住(无法继续升级)”。
结论(先说人话)
如果你的服务端已正确安装并启用了 mod-individual-progression 模块,那么这个脚本能实现“按阶段锁等级/经验”的效果:每个阶段设置一个上限等级(12/20/30/40/50/60/70/75/80),玩家没完成该阶段要求的 Boss 数量(每档 16 选 2)前,无法突破对应的等级上限。
但它依赖模块侧对以下三张表的支持与钩子逻辑:progression_requirement、progression_meta、progression_level_lock。只要这些表存在且模块代码按预期生效,就能锁住经验/等级;如果你的模块版本没有这些表或未启用相关逻辑,就需要先补齐建表并确认模块配置。
这个脚本是怎么做到“锁经验”的
你脚本生成并导入的 SQL 里,核心是两类数据:
progression_requirement:为每个阶段写入“击杀哪些 Boss”作为解锁条件(前几档按种族/阵营区分,后面统一)。
progression_meta:设置 kill_any_count = 2,即每档从 16 个 Boss 里击杀任意 2 个即可过档。
progression_level_lock:为每个阶段写入 max_level,比如阶段1=12级、阶段2=20级…玩家在未过档前,模块应据此限制继续获得经验/升级。
同时它把 worldserver.conf 的 IP.MaxProgression 设置为 8,意味着阶段上限为 8 档,与上面的 12/20/30/40/50/60/70/75/80 一一对应。
最后重启 ac-worldserver,让配置和新导入的规则生效。
脚本本身的评估
生成 SQL:对 1..8 阶段批量写入 requirement/meta/level_lock,逻辑完整,且先清空老数据(DELETE … WHERE stage BETWEEN 1 AND 9)。
导入 SQL:使用 acore 用户导入 acore_world,适合“只写入数据、不建表”的场景;如果表未建,导入会报错(这类缺表需要提前由模块 SQL 或初始化脚本创建)。
配置与热重载:自动把 IP.MaxProgression 写到 worldserver.conf,并重启 world 进程,步骤正确。
总结:脚本“写规则+触发生效”的链路是合理的,关键取决于模块是否存在并启用了对这三张表的逻辑处理。
要想锁经验,必须满足的前提
模块已编译并加载:mod-individual-progression 必须在源码中启用并编译进 worldserver(启动日志里应能看到模块加载)。
三张表已存在于 acore_world:
progression_requirement
progression_meta
progression_level_lock 这些表通常由模块的 world/base SQL 创建。如果缺表,任何 INSERT 都会失败,自然无法“锁经验”。你之前的报错就来自这一点。
worldserver 配置:
已设置 IP.MaxProgression = 8(脚本会设置)
模块需要的通用开关(例如启用 PlayerSettings)也要满足,否则角色进度不会保存。
账号/权限:
用于导入的 acore 用户需要有写权限(INSERT/DELETE)到 acore_world。
快速验证“锁经验是否生效”
新建一个角色,确保处于阶段1(默认);
把角色练到 12 级附近,然后继续刷怪尝试升到 13:
如果模块逻辑生效,12 级就是阶段1的 max_level,经验/升级会被卡住(到不了 13)。
去打你配置的“12档”Boss 池里的任意 2 个 Boss(脚本里每个阶段要求 2 个):
击杀达成后,应自动提升到下一阶段(阶段2),此时等级上限变为 20,继续刷怪可以突破 12,直到 20 再次被锁。
也可在数据库里观察玩家阶段变动(模块通常将进度存在 PlayerSettings 相关表中),或通过模块提供的 .progression 命令查看当前阶段。
可能的风险点与建议
缺表:如果 progression_requirement / progression_meta / progression_level_lock 任一缺失,你会在导入时报 “Table … doesn’t exist”,锁经验自然无从谈起。建议先执行模块自带的建表 SQL,或我可以为你加一段“缺表自动创建”的兜底逻辑(不改变字段含义,仅保证表存在)。 ...