站点图标 科技雷达

All-in-One WP Migration 插件导出卡死或卡顿问题解决方案

使用 Amazon Lightsail 轻量 VPS,不比 EC2 的高稳定性和可靠性,其可能会遇到很多问题,比如 Amazon Lightsail + OpenLiteSpeed + WordPress 环境下,使用 All-in-One WP Migration 导出时卡住,有时虽然最后可以正常导出,但需要额外的超长时间,有时则会导出失败,一直停留在导出阶段。


🔍 可能原因

1. PHP 执行时间或内存限制不足

2. 服务器 CPU / IO 性能瓶颈

3. PHP 配置未针对大任务优化

4. 数据库连接或查询超时

5. 插件兼容问题或已知 Bug


🛠 解决方案

【A. 调整 PHP 设置】

  1. 编辑你的 PHP 配置文件(例如 php.ini 或 OpenLiteSpeed 对应 PHP 的自定义配置),增加以下值:

max_execution_time = 3600
max_input_time = 3600
memory_limit = 512M
post_max_size = 512M
upload_max_filesize = 512M

修改方法:

  1. 重启 OpenLiteSpeed 使配置生效:

sudo systemctl restart lsws


【B. 提升 Lightsail 性能(临时或长期)】


【C. 使用插件“高级导出设置”分卷导出】

在 All-in-One WP Migration 导出设置中:


【D. 使用 phpMyAdmin 备份数据库(替代方案)】

如果多次尝试均卡住,可直接通过 phpMyAdminmysqldump 命令导出数据库,再通过 All-in-One WP Migration 导入文件结构。

🔧 导出命令:

mysqldump -u your_db_user -p your_db_name > backup.sql


【E. 检查数据库表结构异常】

部分插件(如 WooCommerce、wp_options 表自动增长)会导致数据库出现过大单表,


⚠️ 注意

导出时建议访问服务器监控(htop / top / Lightsail Metrics)查看 CPU、RAM、IO 是否饱和,确认瓶颈环节。

 

退出移动版