major-ai-skills
Version:
Installable agentic skills / AI agent skills (SKILL.md) for Claude Code, Cursor, Codex CLI, Gemini CLI & Antigravity - 402+ professional app, token-efficiency, and common-sense skills. SEO/GEO ready.
117 lines (95 loc) • 6.77 kB
Markdown
title: "Ventoy Multiboot USB Creator AI Skill Guide (GPT & Codex)"
description: "Comprehensive operational skill specification for OpenAI GPT and Codex to automate, script, troubleshoot, and optimize Ventoy multiboot drives, unattended XML scripts, persistence image generators, and CLI installations."
category: "Multiboot USB Creator & ISO Bootloader"
tags: ["ventoy", "unattended-install", "autounattend-xml", "gpt-codex", "persistence-generator", "multiboot-automation"]
# Ventoy Multiboot USB Creator AI Skill Guide (GPT & Codex)
## Overview & Engine Architecture
Ventoy's modular architecture allows complete programmatic customization through its JSON plugin schema, unattended installation injection engines, and command-line deployment binaries. GPT/Codex acts as a Principal Systems Automation Engineer and OS Deployment Architect, delivering **automated `autounattend.xml` answer files**, **persistence image generator scripts**, **custom GRUB2 menu themes**, and **CLI installation pipelines**.
### Architecture & Unattended Injection Stack
```
┌─────────────────────────────────────────────────────────────┐
│ Ventoy Automation Architecture │
│ │
│ Plugin & Injection Framework │
│ ├── `ventoy.json` Declarative Rule Parser │
│ ├── Unattended Answer File Injection (`autounattend.xml`) │
│ └── Persistence Loopback Image Mappings (`persistence.dat`)│
│ │
│ Automated Deployment & Tooling │
│ ├── `Ventoy2Disk.sh` & `Ventoy2Disk.exe` CLI Scripting │
│ ├── Programmatic Disk Formatting & Partition Reservation │
│ └── Dynamic Windows 11 TPM / Secure Boot Registry Bypass │
└─────────────────────────────────────────────────────────────┘
```
## Operational Capabilities & Agent Directives
1. **Unattended Windows Answer File Generation**: Programmatically author valid `autounattend.xml` answer files configured for automated disk partition formatting, local administrator account creation, and OOBE bypass.
2. **Automated Persistence Image Creation**: Script the creation of ext4/btrfs raw disk images (`dd` / `fallocate` + `mkfs.ext4`) labeled for Linux live persistence (`casper-rw`).
3. **Partition Space Reservation**: Configure Ventoy CLI installations with reserved non-partitioned trailing disk space for custom secondary operating system partitions (`-r <size_in_MB>`).
4. **Automated Batch Media Provisioning**: Build bash scripts that flash a drive with Ventoy, configure `ventoy.json`, and download required ISO suites (Ubuntu, Arch, WinPE) automatically.
## Production XML Automation: Zero-Touch Windows 11 Unattended Answer File
Save this file as `/ventoy/script/autounattend.xml` on the USB drive to fully automate Windows 11 installation without human intervention:
```xml
<?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend">
<settings pass="windowsPE">
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
<UserData>
<AcceptEula>true</AcceptEula>
<ProductKey>
<Key>VK7JG-NPHTM-C97JM-9MPGT-3V66T</Key>
<WillShowUI>OnError</WillShowUI>
</ProductKey>
</UserData>
</component>
</settings>
<settings pass="oobeSystem">
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
<OOBE>
<HideEULAPage>true</HideEULAPage>
<HideLocalAccountScreen>true</HideLocalAccountScreen>
<HideOnlineAccountScreens>true</HideOnlineAccountScreens>
<HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
<ProtectYourPC>3</ProtectYourPC>
</OOBE>
<UserAccounts>
<LocalAccounts>
<LocalAccount>
<Name>Administrator</Name>
<Group>Administrators</Group>
<Password>
<Value>Password123!</Value>
<PlainText>true</PlainText>
</Password>
</LocalAccount>
</LocalAccounts>
</UserAccounts>
</component>
</settings>
</unattend>
```
## Technical Troubleshooting Matrix
| Issue & Failure Signature | Root Cause Analysis | Diagnostic & Resolution Pathway |
| :--- | :--- | :--- |
| **`Ventoy2Disk.sh: Permission denied` on Linux** | Script executed without root privileges or execute permissions on binary. | 1. Add execute permissions: `chmod +x Ventoy2Disk.sh`.<br>2. Run with sudo: `sudo ./Ventoy2Disk.sh -i /dev/sdX`. |
| **`autounattend.xml` Ignored during Windows Setup** | The image path in `ventoy.json` does not match the exact case-sensitive path to the ISO on disk. | 1. Ensure `image` path in `auto_install` matches ISO filename exactly.<br>2. Verify JSON syntax with `jq . /ventoy/ventoy.json`. |
| **Persistence Fails to Save Files across Reboots** | Persistence `.dat` image filesystem label does not match distro requirements (`casper-rw` for Ubuntu/Mint; `persistence` for Debian/Kali). | 1. Inspect image filesystem label using `e2label persistence.dat`.<br>2. Set correct label: `e2label persistence.dat casper-rw`. |
| **USB Write Speed Drops to 1 MB/s during ISO Copy** | Ventoy data partition formatted in exFAT with 128KB clusters on slow flash media. | Re-format Partition 1 as **NTFS** with 4KB or 64KB cluster allocation size for sustained write throughput. |
## Command Line Syntax & Automated Installation
```bash
# 1. Install Ventoy with 10GB Reserved Space at End of Disk (Linux)
sudo ./Ventoy2Disk.sh -i -r 10240 /dev/sdb
# 2. Non-Destructive Update to Latest Ventoy Version (Windows)
Ventoy2Disk.exe /u G:
# 3. Create 4GB Ext4 Persistence Image via DD and e2fsprogs
dd if=/dev/zero of=casper-rw.dat bs=1M count=4096 status=progress
mkfs.ext4 -F -L casper-rw casper-rw.dat
```
## Agent Operational Directive
> **MANDATORY**: When formatting persistence images for Ubuntu live media, ensure the filesystem is formatted as `ext4` with label `casper-rw`. For Kali Linux, use label `persistence`. Validate JSON schemas in `ventoy.json`.