Create a Windows 7 installation USB flash drive in linux

Source: Internet
Author: User

Create a Windows 7 installation USB flash drive in linux

Http://blog.csdn.net/pipisorry/article/details/41369821

Linux is installed, and win7 is installed with a USB flash drive (network installation should be acceptable ),

First, you must create a win7 installation USB flash drive in linux (ultraiso can be used in windows). It is not possible to directly use the dd command, and the boot information is missing. [In fact, you can also ref]

Fdisk, mkfs. ntfs, ms-sys, win7. ISO, and> 4GU disks are required.


1. Use fdisk to create an ntfs partition on the USB disk, edit the flag, and check the boot option.

Fdisk/dev/sdc

M (anual)

P (arted)

D (elete) deletes an existing Partition

P

N (ew) creates a partition (3.8 GB)

P (rimary)

+ 3800 M

N (ew) create a partition (about 4 GB)

P (rimary)

P

W (rite & save)

1) You can also use gparted to create an ntfs partition on the USB flash drive. For graphic interfaces, install the partition (not recommended)

2) This 4G partition is used to store win7iso content, so the size must be large enough (about 3.2 GB for windows7)

3) The boot option is set to active partition.
2. Format mkfs. ntfs

Attach a USB flash disk before formatting

Mkfs. ntfs/dev/sdbX

3. mount win7iso and the new ntfs partition, and copy all contents to the ntfs partition.

Attach a USB flash disk and re-insert it to mount the two new ntfs partitions.

Df (/dev/sdb1 and/dev/sdb2 are mounted)

1) only the first partition/dev/sdb1 can be displayed in windows, while the two formatted ntfs partitions can be displayed in linux.

Mkdir/mnt/win7_iso

Mount-o loop/.../Win7.ios/Mnt/win7_iso

Cp-r/mnt/win7_iso/*/media/Pi /...#(/Dev/sdb2)

4. Compile and install ms-sys
Ms-sys is a mbr writing tool. It is vital to let the system know that it can guide win7 installation.

Ms-sys.sourceforge.netdownload ms-sys.tar.gz

Decompress and enter the Directory

Make

Then there is a ms-sys directly in the bin.

Or

Make install

5. Run:

// Home/pi/Downloads/ms-sys-2.4.0 # bin/ms-sys-f-7/Dev/sdb2

Write mbr
1) The-7 parameter indicates win7, and sdX indicates the drive letter corresponding to the USB flash drive (I chose sdb2 because sdb1 can only be displayed in windows)
2) winXP should use the-m option directly.

Windows 7 master boot record successfully written to/dev/sdb2 !!!

Ps:

1. It is easy to create a linux boot disk in linux. For more information, see

How to Create a USB flash drive in Linux

Selection of tools for making a USB boot disk

From: http://blog.csdn.net/pipisorry/article/details/41369821

Ref: Create a Windows 7 installation USB flash drive in linux

Create a Windows 7 installation USB flash drive in linux

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.