From 953d87f59d83c452bf3decedd54de7a517f965c5 Mon Sep 17 00:00:00 2001 From: hfshfg <38004547@qq.com> Date: Mon, 16 Mar 2026 20:08:14 +0800 Subject: [PATCH] fix: update Linux bootable to Ubuntu 24.04.4, add format-persistence.sh, rewrite guide MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Update all 24.04.2 references to 24.04.4 (ISO name, URLs, SHA256, docs) - Add format-persistence.sh to bootable/linux-setup/ (from working E: drive) - Rewrite website guide.html Linux tutorial: Linux Mint + Rufus → Ventoy + Ubuntu Co-Authored-By: Claude Opus 4.6 --- bootable/2-download-iso.ps1 | 18 ++-- bootable/4-copy-to-usb.ps1 | 2 +- bootable/README.md | 7 +- bootable/TROUBLESHOOTING.md | 2 +- bootable/linux-setup/format-persistence.sh | 10 ++ bootable/ventoy/ventoy.json | 2 +- website/guide.html | 102 +++++++++------------ 7 files changed, 68 insertions(+), 75 deletions(-) create mode 100644 bootable/linux-setup/format-persistence.sh diff --git a/bootable/2-download-iso.ps1 b/bootable/2-download-iso.ps1 index 956c43c..c456962 100644 --- a/bootable/2-download-iso.ps1 +++ b/bootable/2-download-iso.ps1 @@ -12,17 +12,17 @@ Write-Host "============================================" -ForegroundColor Cyan Write-Host "" # ── Config ── -$ISOName = "ubuntu-24.04.2-desktop-amd64.iso" -$SHA256Expected = "d6dab0c3a657988501b4bd76f1297c053df710e06e0c3aece60dead24f270b4d" +$ISOName = "ubuntu-24.04.4-desktop-amd64.iso" +$SHA256Expected = "3a4c9877b483ab46d7c3fbe165a0db275e1ae3cfe56a5657e5a47c2f99a99d1e" $CacheDir = Join-Path $PSScriptRoot ".download-cache" $ISOPath = Join-Path $CacheDir $ISOName # Mirror list (China mirrors first) $Mirrors = @( - "https://mirrors.tuna.tsinghua.edu.cn/ubuntu-releases/24.04.2/$ISOName", - "https://mirrors.aliyun.com/ubuntu-releases/24.04.2/$ISOName", - "https://mirrors.ustc.edu.cn/ubuntu-releases/24.04.2/$ISOName", - "https://releases.ubuntu.com/24.04.2/$ISOName" + "https://mirrors.tuna.tsinghua.edu.cn/ubuntu-releases/24.04.4/$ISOName", + "https://mirrors.aliyun.com/ubuntu-releases/24.04.4/$ISOName", + "https://mirrors.ustc.edu.cn/ubuntu-releases/24.04.4/$ISOName", + "https://releases.ubuntu.com/24.04.4/$ISOName" ) # ── Create cache directory ── @@ -50,7 +50,7 @@ if (Test-Path $ISOPath) { } # ── Download ISO ── -Write-Host "[INFO] Downloading Ubuntu 24.04.2 Desktop (~5.8 GB)..." -ForegroundColor Yellow +Write-Host "[INFO] Downloading Ubuntu 24.04.4 Desktop (~5.8 GB)..." -ForegroundColor Yellow Write-Host " This will take a while depending on your connection." -ForegroundColor Gray Write-Host "" @@ -76,8 +76,8 @@ foreach ($mirror in $Mirrors) { if (-not $downloaded) { Write-Host "" Write-Host "[ERROR] All download mirrors failed." -ForegroundColor Red - Write-Host " Please download Ubuntu 24.04.2 Desktop ISO manually:" -ForegroundColor Yellow - Write-Host " https://releases.ubuntu.com/24.04.2/" -ForegroundColor Yellow + Write-Host " Please download Ubuntu 24.04.4 Desktop ISO manually:" -ForegroundColor Yellow + Write-Host " https://releases.ubuntu.com/24.04.4/" -ForegroundColor Yellow Write-Host " Save it as: $ISOPath" -ForegroundColor Yellow Read-Host "Press Enter to exit" exit 1 diff --git a/bootable/4-copy-to-usb.ps1 b/bootable/4-copy-to-usb.ps1 index e2aba45..82bc454 100644 --- a/bootable/4-copy-to-usb.ps1 +++ b/bootable/4-copy-to-usb.ps1 @@ -13,7 +13,7 @@ Write-Host "" # ── Config ── $CacheDir = Join-Path $PSScriptRoot ".download-cache" -$ISOName = "ubuntu-24.04.2-desktop-amd64.iso" +$ISOName = "ubuntu-24.04.4-desktop-amd64.iso" $ISOPath = Join-Path $CacheDir $ISOName $PersistencePath = Join-Path $CacheDir "persistence.dat" $VentoyConfigDir = Join-Path $PSScriptRoot "ventoy" diff --git a/bootable/README.md b/bootable/README.md index 879667f..10d3777 100644 --- a/bootable/README.md +++ b/bootable/README.md @@ -35,7 +35,7 @@ │ - 开源引导管理器 v1.0.99 │ │ │ │ Ventoy 数据分区(可见) │ -│ ubuntu-24.04.2-desktop-amd64.iso 5.8GB │ +│ ubuntu-24.04.4-desktop-amd64.iso 5.8GB │ │ persistence.dat 20GB │ │ ventoy/ventoy.json 配置 │ │ u-claw-linux/ 脚本 │ @@ -93,7 +93,7 @@ cd path\to\u-claw\bootable ### Step 2: 下载 Ubuntu ISO (`2-download-iso.ps1`) -- 从国内镜像下载 Ubuntu 24.04.2 桌面版(~5.8GB) +- 从国内镜像下载 Ubuntu 24.04.4 桌面版(~5.8GB) - 镜像优先级:清华 → 阿里 → 中科大 → 官方 - SHA256 校验确保文件完整 - 有缓存,不会重复下载 @@ -176,7 +176,7 @@ sudo bash /media/*/Ventoy/u-claw-linux/setup-openclaw.sh { "persistence": [ { - "image": "/ubuntu-24.04.2-desktop-amd64.iso", + "image": "/ubuntu-24.04.4-desktop-amd64.iso", "backend": "/persistence.dat", "autosel": 1 } @@ -204,6 +204,7 @@ bootable/ ├── 3-create-persistence.ps1 Step 3: 持久化镜像 ├── 4-copy-to-usb.ps1 Step 4: 拷贝到 U 盘 ├── linux-setup/ +│ ├── format-persistence.sh 格式化持久化镜像 │ ├── setup-openclaw.sh 一键安装 OpenClaw │ ├── start-openclaw.sh 启动脚本 │ └── openclaw.desktop 桌面快捷方式 diff --git a/bootable/TROUBLESHOOTING.md b/bootable/TROUBLESHOOTING.md index fa32789..d9cb00c 100644 --- a/bootable/TROUBLESHOOTING.md +++ b/bootable/TROUBLESHOOTING.md @@ -18,7 +18,7 @@ 1. 脚本会自动尝试多个国内镜像(清华、阿里、中科大) 2. 如果全部失败,可以手动下载: - 访问 https://mirrors.tuna.tsinghua.edu.cn/ubuntu-releases/24.04/ - - 下载 `ubuntu-24.04.2-desktop-amd64.iso` + - 下载 `ubuntu-24.04.4-desktop-amd64.iso` - 放到 `bootable/.download-cache/` 目录 3. 重新运行 `2-download-iso.ps1` diff --git a/bootable/linux-setup/format-persistence.sh b/bootable/linux-setup/format-persistence.sh new file mode 100644 index 0000000..eca6a9c --- /dev/null +++ b/bootable/linux-setup/format-persistence.sh @@ -0,0 +1,10 @@ +#!/usr/bin/env bash +# One-click create and format persistence.dat for Ventoy +set -euo pipefail +VENTOY_DIR=$(dirname "$(dirname "$(readlink -f "$0")")") +PERSIST="$VENTOY_DIR/persistence.dat" +SIZE_GB=20 +echo "Creating ${SIZE_GB}GB persistence image..." +dd if=/dev/zero of="$PERSIST" bs=1M count=0 seek=$((SIZE_GB * 1024)) +mkfs.ext4 -F -L casper-rw "$PERSIST" +echo "Done! Reboot for persistence to take effect." diff --git a/bootable/ventoy/ventoy.json b/bootable/ventoy/ventoy.json index 7b87df5..d1a228b 100644 --- a/bootable/ventoy/ventoy.json +++ b/bootable/ventoy/ventoy.json @@ -1,7 +1,7 @@ { "persistence": [ { - "image": "/ubuntu-24.04.2-desktop-amd64.iso", + "image": "/ubuntu-24.04.4-desktop-amd64.iso", "backend": "/persistence.dat", "autosel": 1 } diff --git a/website/guide.html b/website/guide.html index 5f51366..6eb9a22 100644 --- a/website/guide.html +++ b/website/guide.html @@ -1092,34 +1092,32 @@ openclaw plugin uninstall <插件名>

准备材料

- - - + + +
材料要求说明
U 盘64GB+ USB 3.0最低 32GB,推荐 64GB USB 3.0+(USB 2.0 太慢不推荐)
Linux Mint ISOCinnamon 版下载: 清华镜像中科大镜像
Rufusv4.0+下载: rufus.ie(仅 Windows 制作启动盘用)
U 盘32GB+ USB 3.0推荐 64GB USB 3.0+(USB 2.0 太慢不推荐)
Ubuntu 24.04.4 ISODesktop 版下载: 清华镜像阿里镜像
Ventoyv1.0.99下载: GitHub Releases(开源引导管理器)
-
为什么选 Linux Mint?界面最接近 Windows,中文支持好,硬件兼容性强,适合新手。
+
为什么选 Ventoy + Ubuntu?Ventoy 支持 ISO 直接启动,更新系统只需替换 ISO 文件;Ubuntu 24.04 LTS 驱动兼容性最好,社区最大。

制作启动盘步骤

-
1
打开 Rufus -

插入 U 盘,打开 Rufus,选择你的 U 盘设备

+
1
用 Ventoy 写入 U 盘 +

打开 Ventoy2Disk.exe,选择 U 盘,点 Install。注意:会格式化 U 盘,数据全丢!

-
2
选择 ISO 镜像 -

点击"选择",找到下载的 Linux Mint ISO 文件

-
- -
3
关键设置 +
2
拷贝文件到 U 盘 +

将以下文件拷贝到 Ventoy 数据分区(U 盘可见分区)根目录:

- - - - + + + + +
选项设置
分区类型GPT(新电脑)或 MBR(老电脑)
目标系统UEFI(新电脑)或 BIOS(老电脑)
Persistent Partition Size8-16 GB(重要!这是持久化存储空间)
文件说明
ubuntu-24.04.4-desktop-amd64.isoUbuntu 系统镜像(~5.8GB)
persistence.dat持久化存储镜像(20GB,需 ext4 格式化)
ventoy/ventoy.jsonVentoy 配置(自动加载持久化)
u-claw-linux/安装脚本目录
-
Persistent Storage 必须开启!否则重启后所有安装和配置都会丢失。Rufus 4.0+ 支持此功能。
+
自动化制作:也可以在 Windows PowerShell 中运行 bootable/ 目录下的 4 个脚本,自动完成下载和拷贝。
-
4
开始制作 -

点击"开始",等待完成(约 5-10 分钟)

+
3
启动测试 +

插入 U 盘,重启电脑,按启动键选择 USB → Ventoy 菜单出现 → 选择 Ubuntu → 进入桌面

BIOS/UEFI 设置 USB 启动

@@ -1147,52 +1145,36 @@ openclaw plugin uninstall <插件名>
Secure Boot 问题:如果无法从 USB 启动,进入 BIOS 设置关闭 Secure Boot。路径通常是 Security → Secure Boot → Disabled。
-

首次启动 Linux Mint

+

首次启动 Ubuntu

-
1
选择 "Start Linux Mint" -

启动菜单中选择第一项,等待进入桌面(约 1-2 分钟)

+
1
Ventoy 菜单选择 Ubuntu +

从 USB 启动后进入 Ventoy 菜单,选择 Ubuntu ISO,等待进入桌面(约 1-3 分钟)

-
2
连接网络 -

点击右下角网络图标,连接 WiFi 或插入网线

-
- -
3
设置中文(可选) +
2
格式化持久化镜像(仅首次) +

如果持久化镜像尚未格式化(Windows 无 WSL 的情况),打开终端运行:

# 打开终端 (Ctrl+Alt+T)
-sudo apt update
-sudo apt install -y language-pack-zh-hans fonts-wqy-microhei
+sudo bash /media/*/Ventoy/u-claw-linux/format-persistence.sh +

格式化完成后必须重启,持久化才能生效

-

安装 OpenClaw

- -
1
下载安装脚本 -
# 打开终端 (Ctrl+Alt+T)
-curl -O https://raw.githubusercontent.com/dongsheng123132/u-claw/main/portable/setup-linux-usb.sh
-bash setup-linux-usb.sh
-

脚本自动下载 Node.js + OpenClaw + QQ 插件,全部使用国内镜像

+
3
连接网络 + 安装 OpenClaw +

连接 WiFi,然后运行安装脚本:

+
sudo bash /media/*/Ventoy/u-claw-linux/setup-openclaw.sh
+

脚本自动下载 Node.js + OpenClaw + QQ 插件,全部使用国内镜像,约 1-2 分钟

-
2
或手动安装 -
# 1. 安装 Node.js
-curl -# -L https://npmmirror.com/mirrors/node/v22.14.0/node-v22.14.0-linux-x64.tar.gz -o /tmp/node.tar.gz
-mkdir -p ~/node && tar -xzf /tmp/node.tar.gz -C ~/node --strip-components=1
-export PATH="$HOME/node/bin:$PATH"
-
-# 2. 安装 OpenClaw
-mkdir -p ~/openclaw && cd ~/openclaw
-npm init -y
-npm install openclaw@latest --registry=https://registry.npmmirror.com
-
-# 3. 启动
-node node_modules/openclaw/openclaw.mjs gateway run --port 18789
+
4
启动 AI 助手 +

桌面出现 "U-Claw AI Assistant" 图标,双击即可使用

日常使用

    -
  • 开机选择 USB 启动 → 自动进入 Linux Mint 桌面
  • -
  • 双击桌面的 U-Claw AI 助手 图标启动
  • +
  • 插入 U 盘 → 开机选 USB 启动 → Ventoy 菜单选 Ubuntu → 自动进入桌面
  • +
  • 双击桌面的 U-Claw AI Assistant 图标启动
  • 浏览器自动打开控制台,开始使用
  • -
  • 关机前正常关闭 Linux(不要直接拔 U 盘)
  • +
  • 所有数据保存在持久化镜像中,重启不丢
  • +
  • 关机前正常关闭 Ubuntu(不要直接拔 U 盘)

常见问题

@@ -1200,23 +1182,23 @@ node node_modules/openclaw/openclaw.mjs gateway run --port 18789

USB 启动不了

  • 检查 BIOS 启动顺序,确保 USB 排在硬盘前面
  • -
  • 关闭 Secure Boot
  • -
  • GPT/MBR 选择要匹配电脑的 UEFI/Legacy 模式
  • -
  • 换一个 USB 口试试(优先 USB 3.0 口)
  • +
  • 关闭 Secure Boot(BIOS → Security → Secure Boot → Disabled)
  • +
  • 换一个 USB 口试试(优先 USB 3.0 蓝色口)
  • +
  • Legacy/CSM 和 UEFI 模式都试试

持久化不生效(重启后配置丢失)

    -
  • 确认 Rufus 制作时设置了 Persistent Partition Size(8-16 GB)
  • -
  • Rufus 版本需要 4.0 以上才支持持久化
  • -
  • 部分电脑 UEFI 模式下持久化可能有问题,尝试用 MBR + BIOS 模式
  • +
  • 确认 persistence.dat 已格式化为 ext4(运行 format-persistence.sh
  • +
  • 确认 ventoy/ventoy.json 配置正确(image 路径与 ISO 文件名匹配)
  • +
  • 格式化后必须重启才能生效

运行很慢

    -
  • 使用 USB 3.0 或更快的 U 盘
  • -
  • 避免使用太便宜的 U 盘(随机读写速度太低)
  • -
  • 推荐品牌:三星 BAR Plus、闪迪 CZ880
  • +
  • 使用 USB 3.0 或更快的 U 盘 + USB 3.0 接口
  • +
  • 首次加载约 1-3 分钟属正常
  • +
  • 推荐品牌:三星 BAR Plus、闪迪 CZ880、金士顿