{"id":18132722,"url":"https://github.com/bin456789/reinstall","last_synced_at":"2025-05-13T20:18:42.974Z","repository":{"id":97400893,"uuid":"541188877","full_name":"bin456789/reinstall","owner":"bin456789","description":"一键DD/重装脚本 (One-click reinstall OS on VPS)","archived":false,"fork":false,"pushed_at":"2025-05-13T04:32:07.000Z","size":1535,"stargazers_count":5068,"open_issues_count":30,"forks_count":848,"subscribers_count":19,"default_branch":"main","last_synced_at":"2025-05-13T05:26:56.287Z","etag":null,"topics":["alpine","alpine-linux","boot","distro","grub","installer","iso","linux","linux-distribution","liveos","netboot","netinst","netinstall","operating-systems","os","reinstall","shell-script","vps","windows"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bin456789.png","metadata":{"files":{"readme":"README.en.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":"bin456789"}},"created_at":"2022-09-25T13:56:51.000Z","updated_at":"2025-05-13T04:32:12.000Z","dependencies_parsed_at":null,"dependency_job_id":"47499f39-0b86-40cd-8631-04f607804cb1","html_url":"https://github.com/bin456789/reinstall","commit_stats":{"total_commits":599,"total_committers":1,"mean_commits":599.0,"dds":0.0,"last_synced_commit":"3f6b40c8e4506f5863cb3b344d88c0e349a0c0d7"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bin456789%2Freinstall","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bin456789%2Freinstall/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bin456789%2Freinstall/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bin456789%2Freinstall/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bin456789","download_url":"https://codeload.github.com/bin456789/reinstall/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254020659,"owners_count":22000757,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["alpine","alpine-linux","boot","distro","grub","installer","iso","linux","linux-distribution","liveos","netboot","netinst","netinstall","operating-systems","os","reinstall","shell-script","vps","windows"],"created_at":"2024-11-01T13:05:25.645Z","updated_at":"2025-05-13T20:18:42.967Z","avatar_url":"https://github.com/bin456789.png","language":"Shell","readme":"\u003c!-- markdownlint-disable MD028 MD033 MD045 --\u003e\n\n# reinstall\n\n[![Codacy](https://img.shields.io/codacy/grade/dc679a17751448628fe6d8ac35e26eed?logo=Codacy\u0026label=Codacy\u0026style=flat-square)](https://app.codacy.com/gh/bin456789/reinstall/dashboard)\n[![CodeFactor](https://img.shields.io/codefactor/grade/github/bin456789/reinstall?logo=CodeFactor\u0026logoColor=white\u0026label=CodeFactor\u0026style=flat-square)](https://www.codefactor.io/repository/github/bin456789/reinstall)\n[![Lines of Code](https://tokei.rs/b1/github/bin456789/reinstall?category=code\u0026label=Lines%20of%20Code\u0026style=flat-square)](https://github.com/XAMPPRocky/tokei_rs)\n[![Telegram Group](https://img.shields.io/badge/Telegram-2CA5E0?style=flat-square\u0026logo=telegram\u0026logoColor=white)](https://t.me/reinstall_os)\n[![Github Sponsors](https://img.shields.io/badge/sponsor-30363D?style=flat-square\u0026logo=GitHub-Sponsors\u0026logoColor=#EA4AAA)](https://github.com/sponsors/bin456789)\n\nOne-Click Script to Reinstall System [中文](README.md)\n\n[![Sponsors](https://raw.githubusercontent.com/bin456789/sponsors/refs/heads/master/sponsors.svg)](https://github.com/sponsors/bin456789)\n\n## Highlights\n\n- One-click Linux installation: Supports 19 common distributions.\n- One-click Windows installation: Uses the official ISO for installation instead of custom images. The script can automatically ~~retrieves the ISO link~~ and installs common drivers like `Virtio`.\n- Supports installation in any direction, i.e., `Linux to Linux`, `Linux to Windows`, `Windows to Windows`, `Windows to Linux`\n- No need to input IP parameters; automatically recognizes dynamic and static IPs, supports `/32`, `/128`, `gateway outside subnet`, `IPv6 only`, `dual NIC`\n- Specially optimized for low-spec servers, requires less memory than the official netboot\n- Uses partition table ID to identify hard drives throughout the process, ensuring no wrong disk is written\n- Supports BIOS and EFI boot, and ARM Server\n- No homemades image included, all resources are obtained in real-time from mirror sites\n\n## System Requirements\n\nThe original system can be any system listed in the table.\n\nThe system requirements for the target system are as follows:\n\n| System                                                                                                                                                                                                                                                                                                                                                                 | Version                               | Memory    | Disk             |\n| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------- | --------- | ---------------- |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://www.alpinelinux.org/alpine-logo.ico\" /\u003e Alpine                                                                                                                                                                                                                                                                                | 3.18, 3.19, 3.20, 3.21                | 256 MB    | 1 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://www.debian.org/favicon.ico\" /\u003e Debian                                                                                                                                                                                                                                                                                         | 9, 10, 11, 12                         | 256 MB    | 1 ~ 1.5 GB ^     |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://github.com/bin456789/reinstall/assets/7548515/f74b3d5b-085f-4df3-bcc9-8a9bd80bb16d\" /\u003e Kali                                                                                                                                                                                                                                   | Rolling                               | 256 MB    | 1 ~ 1.5 GB ^     |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://documentation.ubuntu.com/server/_static/favicon.png\" /\u003e Ubuntu                                                                                                                                                                                                                                                                | 16.04 LTS - 24.04 LTS, 25.04          | 512 MB \\* | 2 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://img.alicdn.com/imgextra/i1/O1CN01oJnJZg1yK4RzI4Rx2_!!6000000006559-2-tps-118-118.png\" /\u003e Anolis                                                                                                                                                                                                                               | 7, 8, 23                              | 512 MB \\* | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://www.redhat.com/favicon.ico\" /\u003e RHEL \u0026nbsp;\u003cimg width=\"16\" height=\"16\" src=\"https://almalinux.org/fav/favicon.ico\" /\u003e AlmaLinux \u0026nbsp;\u003cimg width=\"16\" height=\"16\" src=\"https://rockylinux.org/favicon.png\" /\u003e Rocky \u0026nbsp;\u003cimg width=\"16\" height=\"16\" src=\"https://www.oracle.com/asset/web/favicons/favicon-32.png\" /\u003e Oracle | 8, 9                                  | 512 MB \\* | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://opencloudos.org/qq.ico\" /\u003e OpenCloudOS                                                                                                                                                                                                                                                                                        | 8, 9, Stream 23                       | 512 MB \\* | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://www.centos.org/assets/icons/favicon.svg\" /\u003e CentOS Stream                                                                                                                                                                                                                                                                     | 9, 10                                 | 512 MB \\* | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://fedoraproject.org/favicon.ico\" /\u003e Fedora                                                                                                                                                                                                                                                                                      | 41, 42                                | 512 MB \\* | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://www.openeuler.org/favicon.ico\" /\u003e openEuler                                                                                                                                                                                                                                                                                   | 20.03 LTS - 24.03 LTS, 25.03          | 512 MB \\* | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://static.opensuse.org/favicon.ico\" /\u003e openSUSE                                                                                                                                                                                                                                                                                  | Leap 15.6, Tumbleweed (Rolling)       | 512 MB \\* | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://nixos.org/favicon.svg\" /\u003e NixOS                                                                                                                                                                                                                                                                                               | 24.11                                 | 512 MB    | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://archlinux.org/static/favicon.png\" /\u003e Arch                                                                                                                                                                                                                                                                                     | Rolling                               | 512 MB    | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://www.gentoo.org/assets/img/logo/gentoo-g.png\" /\u003e Gentoo                                                                                                                                                                                                                                                                        | Rolling                               | 512 MB    | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://aosc.io/assets/distros/aosc-os.svg\" /\u003e AOSC OS                                                                                                                                                                                                                                                                                | Rolling                               | 512 MB    | 5 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://www.fnnas.com/favicon.ico\" /\u003e fnOS                                                                                                                                                                                                                                                                                            | Beta                                  | 512 MB    | 8 GB             |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://blogs.windows.com/wp-content/uploads/prod/2022/09/cropped-Windows11IconTransparent512-32x32.png\" /\u003e Windows (DD)                                                                                                                                                                                                              | Any                                   | 512 MB    | Depends on image |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://blogs.windows.com/wp-content/uploads/prod/2022/09/cropped-Windows11IconTransparent512-32x32.png\" /\u003e Windows (ISO)                                                                                                                                                                                                             | Vista, 7, 8.x (Server 2008 - 2012 R2) | 512 MB    | 25 GB            |\n| \u003cimg width=\"16\" height=\"16\" src=\"https://blogs.windows.com/wp-content/uploads/prod/2022/09/cropped-Windows11IconTransparent512-32x32.png\" /\u003e Windows (ISO)                                                                                                                                                                                                             | 10, 11 (Server 2016 - 2025)           | 1 GB      | 25 GB            |\n\n\\* Indicates installation using cloud images, not traditional network installation.\n\n^ Indicates requiring either 256 MB memory + 1.5 GB disk, or 512 MB memory + 1 GB disk\n\n\u003e [!WARNING]\n\u003e ❌ This script does not support OpenVZ or LXC virtual machines.\n\u003e\n\u003e Please use \u003chttps://github.com/LloydAsp/OsMutation\u003e instead.\n\n## Download (Current system is \u003cimg width=\"20\" height=\"20\" src=\"https://www.kernel.org/theme/images/logos/favicon.png\" /\u003e Linux)\n\nFor server outside China:\n\n```bash\ncurl -O https://raw.githubusercontent.com/bin456789/reinstall/main/reinstall.sh || wget -O reinstall.sh $_\n```\n\nFor server inside China:\n\n```bash\ncurl -O https://cnb.cool/bin456789/reinstall/-/git/raw/main/reinstall.sh || wget -O reinstall.sh $_\n```\n\n## Download (Current system is \u003cimg width=\"20\" height=\"20\" src=\"https://blogs.windows.com/wp-content/uploads/prod/2022/09/cropped-Windows11IconTransparent512-32x32.png\" /\u003e Windows)\n\n\u003e [!IMPORTANT]\n\u003e Before proceeding, please disable the 'Real-time protection' feature in `Windows Defender`. This feature may prevent `certutil` from downloading any files.\n\n\u003cdetails\u003e\n\n\u003csummary\u003eResolving Script Download Issues on Windows 7\u003c/summary\u003e\n\nDue to lack of support for TLS 1.2, SHA-256, or outdated root certificates, Windows Vista, 7, and Server 2008 (R2) may not be able to download scripts automatically. Manual downloading is required, as follows:\n\nUse Internet Explorer (enable TLS 1.2 in IE's advanced settings first) to download, or use Remote Desktop to save the following two files into the same directory:\n\n- \u003chttps://raw.githubusercontent.com/bin456789/reinstall/main/reinstall.bat\u003e\n\n- \u003chttps://www.cygwin.com/setup-x86.exe\u003e\n\nTo use, run the downloaded `reinstall.bat`.\n\n\u003c/details\u003e\n\nFor server outside China:\n\n```batch\ncertutil -urlcache -f -split https://raw.githubusercontent.com/bin456789/reinstall/main/reinstall.bat\n```\n\nFor server inside China:\n\n```batch\ncertutil -urlcache -f -split https://cnb.cool/bin456789/reinstall/-/git/raw/main/reinstall.bat\n```\n\n## Usage\n\n**All features** can be used on both Linux and Windows.\n\n- on Linux, run `bash reinstall.sh ...`\n- on Windows, first run `cmd`, then run `.\\reinstall.bat ...`\n  - If the link in the parameter contains special characters, it should be enclosed in `\"\"`, not `''`.\n\n### Feature 1: Install \u003cimg width=\"16\" height=\"16\" src=\"https://www.kernel.org/theme/images/logos/favicon.png\" /\u003e Linux\n\n- The username is `root` with a default password of `123@@@`.\n- When installing the latest version, the version number does not need to be specified.\n- Maximizes disk space usage: no boot partition (except for Fedora) and no swap partition.\n- Automatically selects different optimized kernels based on machine type, such as `Cloud` or `HWE` kernels.\n- When installing Red Hat, you must provide the `qcow2` image link obtained from \u003chttps://access.redhat.com/downloads/content/rhel\u003e. You can also install other RHEL-based OS, such as `Alibaba Cloud Linux` and `TencentOS Server`.\n- After reinstallation, if you need to change the SSH port or switch to key-based login, make sure to also modify the files inside `/etc/ssh/sshd_config.d/`.\n\n```bash\nbash reinstall.sh anolis      7|8|23\n                  opencloudos 8|9|23\n                  rocky       8|9\n                  redhat      8|9   --img=\"http://xxx.com/xxx.qcow2\"\n                  oracle      8|9\n                  almalinux   8|9\n                  centos      9|10\n                  fedora      41|42\n                  nixos       24.11\n                  debian      9|10|11|12\n                  opensuse    15.6|tumbleweed\n                  alpine      3.18|3.19|3.20|3.21\n                  openeuler   20.03|22.03|24.03|25.03\n                  ubuntu      16.04|18.04|20.04|22.04|24.04|25.04 [--minimal]\n                  kali\n                  arch\n                  gentoo\n                  aosc\n                  fnos\n```\n\n#### Optional Parameters\n\n- `--password PASSWORD` Set the password\n- `--ssh-key KEY` Set up SSH login public key, supports these formats. When using public key, password is empty.\n  - `--ssh-key \"ssh-rsa ...\"`\n  - `--ssh-key \"ssh-ed25519 ...\"`\n  - `--ssh-key \"ecdsa-sha2-nistp256/384/521 ...\"`\n  - `--ssh-key http://path/to/public_key`\n  - `--ssh-key github:your_username`\n  - `--ssh-key gitlab:your_username`\n  - `--ssh-key /path/to/public_key`\n  - `--ssh-key C:\\path\\to\\public_key`\n- `--ssh-port PORT` Change the SSH port (for log observation during installation and for the new system)\n- `--web-port PORT` Change the Web port (for log observation during installation)\n- `--frpc-toml /path/to/frpc.toml` Add frpc for intranet tunneling\n- `--hold 2` Prevent reboot after installation completes, allowing SSH login to modify system content; the system is mounted at `/os` (this feature is not supported on Debian/Kali).\n\n\u003e [!TIP]\n\u003e When installing Debian/Kali, x86 architectures can monitor the installation progress through VNC from server provider, while ARM architectures can use the serial console.\n\u003e\n\u003e When installing other systems, can monitor the progress through various methods (SSH, HTTP 80 port, VNC from server provider, serial console).\n\u003e \u003cbr /\u003eEven if errors occur during the installation process, you can still install to Alpine via SSH by running `/trans.sh alpine`\n\n\u003cdetails\u003e\n\n\u003csummary\u003eExperimental Features\u003c/summary\u003e\n\nInstall Debian using a cloud image\n\n- Suitable for machines with slower CPUs\n\n```bash\nbash reinstall.sh debian --ci\n```\n\nInstall CentOS, AlmaLinux, Rocky, Fedora using ISO\n\n- Only supports machines with more than 2G of memory and dynamic IP.\n- Password is `123@@@`, and the SSH port is `22`; modifying them using parameters is not supported.\n\n```bash\nbash reinstall.sh centos --installer\n```\n\nInstall Ubuntu using ISO\n\n- Only supports machines with more than 1G of memory and dynamic IP.\n- Password is `123@@@`, and the SSH port is `22`; modifying them using parameters is not supported.\n\n```bash\nbash reinstall.sh ubuntu --installer\n```\n\n\u003c/details\u003e\n\n### Feature 2: DD\n\n- Supports `raw` and `vhd` image formats (either uncompressed or compressed as `.gz`, `.xz`, `.zst`, `.tar`, `.tar.gz`, `.tar.xz`, `.tar.zst`).\n- When deploy a Windows image, the system disk will be automatically expanded, and machines with a static IP will have their IP configured, and may take a few minutes after the first boot for the configuration to take effect.\n- When deploy a Linux image, will **NOT** modify any contents of the image.\n\n```bash\nbash reinstall.sh dd --img \"https://example.com/xxx.xz\"\n```\n\n#### Optional parameters\n\n- `--allow-ping` Configure Windows Firewall to Allow Ping Responses (DD Windows only)\n- `--rdp-port PORT` Change RDP port (DD Windows only)\n- `--ssh-port PORT` Change SSH port (for log observation during installation)\n- `--web-port PORT` Change Web port (for log observation during installation)\n- `--frpc-toml /path/to/frpc.toml` Add frpc for intranet tunneling (DD Windows only)\n- `--hold 2` Prevent reboot after the DD process finishes, allowing SSH login to modify system content. The Windows system will be mounted at `/os`, but Linux systems will **NOT** be automatically mounted.\n\n\u003e [!TIP]\n\u003e Can monitor the progress through various methods (SSH, HTTP 80 port, VNC from server provider, serial console).\n\u003e \u003cbr /\u003eEven if errors occur during the installation process, you can still install to Alpine via SSH by running `/trans.sh alpine`\n\n### Feature 3: Reboot to \u003cimg width=\"16\" height=\"16\" src=\"https://www.alpinelinux.org/alpine-logo.ico\" /\u003e Alpine Live OS (RAM OS)\n\n- You can use SSH to backup/restore disk, manually perform DD operations, modify partitions, and manually install Alpine, Arch, Gentoo, and other systems.\n- Username `root`, Default password `123@@@`\n- If manual operations do not damage the original system, rebooting will return to the original system.\n\n```bash\nbash reinstall.sh alpine --hold=1\n```\n\n#### Optional parameters\n\n- `--password PASSWORD` Set password\n- `--ssh-port PORT` Change SSH port\n- `--ssh-key KEY` Set up SSH login public key, supports these formats. When using public key, password is empty.\n  - `--ssh-key \"ssh-rsa ...\"`\n  - `--ssh-key \"ssh-ed25519 ...\"`\n  - `--ssh-key \"ecdsa-sha2-nistp256/384/521 ...\"`\n  - `--ssh-key http://path/to/public_key`\n  - `--ssh-key github:your_username`\n  - `--ssh-key gitlab:your_username`\n  - `--ssh-key /path/to/public_key`\n  - `--ssh-key C:\\path\\to\\public_key`\n- `--frpc-toml /path/to/frpc.toml` Add frpc for intranet tunneling\n\n### Feature 4: Reboot to \u003cimg width=\"16\" height=\"16\" src=\"https://netboot.xyz/img/favicon.ico\" /\u003e netboot.xyz\n\n- Can manually install [more systems](https://github.com/netbootxyz/netboot.xyz?tab=readme-ov-file#what-operating-systems-are-currently-available-on-netbootxyz) using vendor backend VNC.\n- If manual operations do not damage the original system, rebooting will return to the original system.\n\n```bash\nbash reinstall.sh netboot.xyz\n```\n\n![netboot.xyz](https://netboot.xyz/images/netboot.xyz.gif)\n\n### Feature 5: Install \u003cimg width=\"16\" height=\"16\" src=\"https://blogs.windows.com/wp-content/uploads/prod/2022/09/cropped-Windows11IconTransparent512-32x32.png\" /\u003e Windows ISO\n\n![Windows Installation](https://github.com/bin456789/reinstall/assets/7548515/07c1aea2-1ce3-4967-904f-aaf9d6eec3f7)\n\n- Username `administrator`, Default password `123@@@`\n- If remote login fails, try using the username `.\\administrator`.\n- The machine with a static IP will automatically configure the IP. It may take a few minutes to take effect on the first boot.\n- Supports all languages.\n\n#### Supported Systems\n\n- Windows (Vista ~ 11)\n- Windows Server (2008 ~ 2025)\n  - Windows Server Essentials \\*\n  - Windows Server (Semi) Annual Channel \\*\n  - Hyper-V Server \\*\n  - Azure Stack HCI \\*\n\n#### ~~Method 1: Let the Script Automatically Search for ISO~~\n\n\u003e [!CAUTION]\n\u003e The ISO repository currently prohibits direct link downloads, so this method is no longer effective.\n\n- The script will search for ISOs from \u003chttps://massgrave.dev/genuine-installation-media\u003e, a site that collects official ISOs.\n- Systems marked with \\* do not support automatic ISO searching.\n\n```bash\nbash reinstall.sh windows \\\n     --image-name \"Windows 11 Enterprise LTSC 2024\" \\\n     --lang zh-cn\n```\n\n\u003cdetails\u003e\n\u003csummary\u003eSupported languages\u003c/summary\u003e\n\n```text\nar-sa\nbg-bg\ncs-cz\nda-dk\nde-de\nel-gr\nen-gb\nen-us\nes-es\nes-mx\net-ee\nfi-fi\nfr-ca\nfr-fr\nhe-il\nhr-hr\nhu-hu\nit-it\nja-jp\nko-kr\nlt-lt\nlv-lv\nnb-no\nnl-nl\npl-pl\npt-pt\npt-br\nro-ro\nru-ru\nsk-sk\nsl-si\nsr-latn-rs\nsv-se\nth-th\ntr-tr\nuk-ua\nzh-cn\nzh-hk\nzh-tw\n```\n\n\u003c/details\u003e\n\n#### Method 2: Specify the ISO link manually\n\n- If you don't know the `--image-name`, you can enter any value. After rebooting, connect via SSH and re-enter the correct value based on the error messages.\n\n```bash\nbash reinstall.sh windows \\\n     --image-name \"Windows 11 Enterprise LTSC 2024 Evaluation\" \\\n     --iso \"https://go.microsoft.com/fwlink/?linkid=2289029\"\n```\n\nor Magnet Link\n\n```bash\nbash reinstall.sh windows \\\n     --image-name \"Windows 11 Enterprise LTSC 2024\" \\\n     --iso \"magnet:?xt=urn:btih:7352bd2db48c3381dffa783763dc75aa4a6f1cff\"\n```\n\n\u003cdetails\u003e\n\n\u003csummary\u003eThe following website provides ISO links.\u003c/summary\u003e\n\n- General\n  - \u003chttps://msdl.gravesoft.dev\u003e\n  - \u003chttps://massgrave.dev/genuine-installation-media\u003e\n  - \u003chttps://next.itellyou.cn\u003e\n  - \u003chttps://www.xitongku.com\u003e\n  - \u003chttps://www.microsoft.com/software-download/windows10\u003e (Need to open it with a non-Windows User-Agent)\n  - \u003chttps://www.microsoft.com/software-download/windows11\u003e\n  - \u003chttps://www.microsoft.com/software-download/windows11arm64\u003e\n- Evaluation\n  - \u003chttps://www.microsoft.com/evalcenter/download-windows-10-enterprise\u003e\n  - \u003chttps://www.microsoft.com/evalcenter/download-windows-11-enterprise\u003e\n  - \u003chttps://www.microsoft.com/evalcenter/download-windows-11-iot-enterprise-ltsc-eval\u003e\n  - \u003chttps://www.microsoft.com/evalcenter/download-windows-server-2012-r2\u003e\n  - \u003chttps://www.microsoft.com/evalcenter/download-windows-server-2016\u003e\n  - \u003chttps://www.microsoft.com/evalcenter/download-windows-server-2019\u003e\n  - \u003chttps://www.microsoft.com/evalcenter/download-windows-server-2022\u003e\n  - \u003chttps://www.microsoft.com/evalcenter/download-windows-server-2025\u003e\n- Insider Preview\n  - \u003chttps://www.microsoft.com/en-us/software-download/windowsinsiderpreviewiso\u003e\n  - \u003chttps://www.microsoft.com/en-us/software-download/windowsinsiderpreviewserver\u003e\n\n\u003c/details\u003e\n\n#### Optional parameters\n\n- `--password PASSWORD` Set Password\n- `--allow-ping` Configure Windows Firewall to Allow Ping Responses\n- `--rdp-port PORT` Change RDP port\n- `--ssh-port PORT` Change SSH port (for log observation during installation)\n- `--web-port PORT` Change Web port (for log observation during installation)\n- `--add-driver INF_OR_DIR` Add additional driver, specifying .inf path, or the folder contains .inf file.\n  - The driver must be downloaded locally first.\n  - This parameter can be set multiple times to add different driver.\n- `--frpc-toml /path/to/frpc.toml` Add frpc for intranet tunneling\n- `--hold 2` Allow SSH connections for modifying the disk content before rebooting into the official Windows installation program, with the disk mounted at `/os`.\n\n#### The following drivers will automatic download and install as needed, without the need for manual addition\n\n- Virtio ([Virtio][virtio-virtio], [Alibaba Cloud][virtio-aliyun], [Tencent Cloud][virtio-qcloud], [GCP][virtio-gcp])\n- XEN ([~~XEN~~][xen-xen] (unsigned), [Citrix][xen-citrix], [AWS][xen-aws])\n- AWS ([ENA Network Adapter][aws-ena], [NVME Storage Controller][aws-nvme])\n- GCP ([gVNIC Network Adapter][gcp-gvnic], [GGA Display Adapter][gcp-gga])\n- Azure ([MANA Network Adapter][azure-mana])\n- Intel ([VMD Storage Controller][intel-vmd], Network Adapter: [7][intel-nic-7], [8][intel-nic-8], [8.1][intel-nic-8.1], [10][intel-nic-10], [11][intel-nic-11], [2008 R2][intel-nic-2008-r2], [2012][intel-nic-2012], [2012 R2][intel-nic-2012-r2], [2016][intel-nic-2016], [2019][intel-nic-2019], [2022][intel-nic-2022], [2025][intel-nic-2025])\n\n[virtio-virtio]: https://fedorapeople.org/groups/virt/virtio-win/direct-downloads/\n[virtio-aliyun]: https://www.alibabacloud.com/help/ecs/user-guide/install-the-virtio-driver-1\n[virtio-qcloud]: https://cloud.tencent.com/document/product/213/17815#b84b2032-752c-43c4-a509-73530b8f82ff\n[virtio-gcp]: https://console.cloud.google.com/storage/browser/gce-windows-drivers-public\n[xen-xen]: https://xenproject.org/resources/downloads/\n[xen-aws]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/xen-drivers-overview.html\n[xen-citrix]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Upgrading_PV_drivers.html#win2008-citrix-upgrade\n[aws-ena]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ena-driver-releases-windows.html\n[aws-nvme]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/nvme-driver-version-history.html\n[gcp-gvnic]: https://cloud.google.com/compute/docs/networking/using-gvnic\n[gcp-gga]: https://cloud.google.com/compute/docs/instances/enable-instance-virtual-display\n[azure-mana]: https://learn.microsoft.com/azure/virtual-network/accelerated-networking-mana-windows\n[intel-vmd]: https://www.intel.com/content/www/us/en/download/849936/intel-rapid-storage-technology-driver-installation-software-with-intel-optane-memory-12th-to-15th-gen-platforms.html\n[intel-nic-7]: https://www.intel.com/content/www/us/en/download/15590/intel-network-adapter-driver-for-windows-7-final-release.html\n[intel-nic-8]: https://www.intel.com/content/www/us/en/download/16765/intel-network-adapter-driver-for-windows-8-final-release.html\n[intel-nic-8.1]: https://www.intel.com/content/www/us/en/download/17479/intel-network-adapter-driver-for-windows-8-1.html\n[intel-nic-10]: https://www.intel.com/content/www/us/en/download/18293/intel-network-adapter-driver-for-windows-10.html\n[intel-nic-11]: https://www.intel.com/content/www/us/en/download/727998/intel-network-adapter-driver-for-microsoft-windows-11.html\n[intel-nic-2008-r2]: https://www.intel.com/content/www/us/en/download/15591/intel-network-adapter-driver-for-windows-server-2008-r2-final-release.html\n[intel-nic-2012]: https://www.intel.com/content/www/us/en/download/16789/intel-network-adapter-driver-for-windows-server-2012.html\n[intel-nic-2012-r2]: https://www.intel.com/content/www/us/en/download/17480/intel-network-adapter-driver-for-windows-server-2012-r2.html\n[intel-nic-2016]: https://www.intel.com/content/www/us/en/download/18737/intel-network-adapter-driver-for-windows-server-2016.html\n[intel-nic-2019]: https://www.intel.com/content/www/us/en/download/19372/intel-network-adapter-driver-for-windows-server-2019.html\n[intel-nic-2022]: https://www.intel.com/content/www/us/en/download/706171/intel-network-adapter-driver-for-windows-server-2022.html\n[intel-nic-2025]: https://www.intel.com/content/www/us/en/download/838943/intel-network-adapter-driver-for-windows-server-2025.html\n\n#### How to Specify the Image Name `--image-name`\n\nTypically, an ISO will contain multiple system versions, such as Home Edition and Professional Edition. The image name `--image-name` is used to specify the version to be installed, and it is case-insensitive when entered.\n\nYou can use tools like DISM, DISM++, or Wimlib to query the image names included in the ISO.\n\nCommonly used image names include:\n\n```text\nWindows 7 Ultimate\nWindows 11 Pro\nWindows 11 Enterprise LTSC 2024\nWindows Server 2025 SERVERDATACENTER\n```\n\n#### How to Use [DISM++](https://github.com/Chuyu-Team/Dism-Multi-language/releases) to Query the Image Names Included in the ISO\n\nOpen File menu \u003e Open Image File, select the iso to be installed to get the image name (full system name), and all available image names are installable.\n\n![image-name](https://github.com/bin456789/reinstall/assets/7548515/5aae0a9b-61e2-4f66-bb98-d470a6beaac2)\n\n\u003e [!WARNING]\n\u003e Vista (Server 2008) and 32-bit systems may lack drivers.\n\n\u003e [!WARNING]\n\u003e For EFI machines without CSM enabled, Windows 7 (Server 2008 R2) cannot be installed.\n\u003e\n\u003e Hyper-V (Azure) requires selecting the appropriate VM generation: \u003chttps://learn.microsoft.com/windows-server/virtualization/hyper-v/plan/should-i-create-a-generation-1-or-2-virtual-machine-in-hyper-v\u003e\n\n\u003e [!WARNING]\n\u003e In the Chinese version of Windows 10 LTSC 2021 ISO `zh-cn_windows_10_enterprise_ltsc_2021_x64_dvd_033b7312.iso`, the `wsappx` process may indefinitely consume CPU resources.\n\u003e\n\u003e The solution is to update the system patches or manually install the `VCLibs` library \u003chttps://www.google.com/search?q=ltsc+wsappx\u003e.\n\n#### Considerations for Installing Windows on ARM\n\nMost ARM machines support installing latest Windows 11.\n\nDuring the installation process, you might encounter a black screen, and the serial console may display `ConvertPages: failed to find range`, but neither issue affects the installation.\n\n| Compatibility | Cloud Provider | Instance Type | Issues                                                                                                                                                 |\n| ------------- | -------------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------ |\n| ✔️            | Azure          | B2pts_v2      |                                                                                                                                                        |\n| ✔️            | Alibaba Cloud  | g6r, c6r      |                                                                                                                                                        |\n| ✔️            | Alibaba Cloud  | g8y, c8y, r8y | There is a chance of hanging at the boot logo during restart; forced reboot will resolve it.                                                           |\n| ✔️            | AWS            | T4g           |                                                                                                                                                        |\n| ✔️            | Scaleway       | COPARM1       |                                                                                                                                                        |\n| ✔️            | Gcore          |               |                                                                                                                                                        |\n| ❔            | Oracle Cloud   | A1.Flex       | Installation success is not guaranteed; newer instances are more likely to succeed.\u003cbr /\u003eManual loading of GPU drivers is required after installation. |\n| ❌            | Google Cloud   | t2a           | Missing network card drivers                                                                                                                           |\n\n\u003cdetails\u003e\n\n\u003csummary\u003eLoading Graphics Driver on Oracle Cloud\u003c/summary\u003e\n\nLog in to the server using Remote Desktop, open Device Manager, locate the graphics card, select \"Update Driver,\" and choose `Red Hat VirtIO GPU DOD controller` from the list. There's no need to download the drivers in advance.\n\n![virtio-gpu-1](https://github.com/user-attachments/assets/503e1d82-4fa9-4486-917e-73326ad7c988)\n![virtio-gpu-2](https://github.com/user-attachments/assets/bf3a9af6-13d8-4f93-9d6c-d3b2dbddb37d)\n![virtio-gpu-3](https://github.com/user-attachments/assets/a9006a78-838f-45bf-a556-2dba193d3c03)\n\n\u003c/details\u003e\n\n## Discussion\n\n[![GitHub Issues](https://img.shields.io/badge/github-%23121011.svg?style=for-the-badge\u0026logo=github\u0026logoColor=white)](https://github.com/bin456789/reinstall/issues)\n[![Telegram Group](https://img.shields.io/badge/Telegram-2CA5E0?style=for-the-badge\u0026logo=telegram\u0026logoColor=white)](https://t.me/reinstall_os)\n\n## How to Modify the Script for Your Own\n\n1. Fork this repository.\n2. Modify the `confhome` and `confhome_cn` at the beginning of `reinstall.sh` and `reinstall.bat`.\n3. Make changes to the other code.\n\n## Thanks\n\n[![Github Sponsors](https://img.shields.io/badge/sponsor-30363D?style=for-the-badge\u0026logo=GitHub-Sponsors\u0026logoColor=#EA4AAA)](https://github.com/sponsors/bin456789)\n\nThanks to the following businesses for providing free servers.\n\n[![Oracle Cloud](https://github.com/bin456789/reinstall/assets/7548515/8b430ed4-8344-4f96-b4da-c2bda031cc90)](https://www.oracle.com/cloud/)\n[![DartNode](https://github.com/bin456789/reinstall/assets/7548515/435d6740-bcdd-4f3a-a196-2f60ae397f17)](https://dartnode.com/)\n","funding_links":["https://github.com/sponsors/bin456789"],"categories":["Shell","终端"],"sub_categories":["资源传输下载"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbin456789%2Freinstall","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbin456789%2Freinstall","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbin456789%2Freinstall/lists"}