Hyper-V First-involved hyper-V Virtual Machine file exchange

Source: Internet
Author: User

Thanks for delivery at absolute zero degree 0oWhen using a virtual machine, the common problem is the file exchange between the host and the virtual machine. Unfortunately, hyper-V virtual machines use a remote connection, so they do not support direct drag-and-drop transmission of files. Here, we will introduce two file interconnection Methods: Network-Based Network neighbors and virtual disk-based editing to transfer files.

Hyper-V feature enabling and virtual machine setting: http://www.cnbeta.com/articles/218677.htm

Hyper-V Virtual Machine tips: http://www.cnbeta.com/articles/218887.htm

Hyper-V Virtual Machine network connection: http://www.cnbeta.com/articles/219057.htm

When using virtual machines, file interaction is very important. If file interaction between physical machines and virtual machines can be realized, it will save a lot of time. Unfortunately, the hyper-V virtual machine does not support USB storage devices, so it is a little troublesome to switch files.

Files can be shared with hyper-V virtual machines through network peers or FTP servers. Data is transmitted over the network. The architecture is based on the network communication between hyper-V virtual machines and physical machines. The demonstration will be conducted in the form of network neighbors.

On the physical machine, click "remote settings" in "winkey + pause" and select "allow remote connection to this computer ".

In addition, the name of the VM cannot be the same as that of the host. If they are the same, click "change" under the "computer name" tab to change the computer name.

Next, share folders with files to be shared (only folder sharing is supported, but file sharing is not supported ). Right-click the folder to be shared and choose Properties From the shortcut menu. Then, click Advanced sharing.

In the displayed dialog box, select "share this folder". To modify the file in the virtual machine, click "permission" to modify the permission. Then, click "OK.

Next, click "network" in the resource manager of the Virtual Machine and double-click the computer name of the physical machine.

After entering the username and password of the physical machine, you can find the folder you just shared in the opened folder, open the folder, and copy the file to share the file.

Note that if the network contains other computers, the security and confidentiality of the files should be paid extra attention.

On virtual machines that do not support network connectivity, you can also mount Virtual Disks or virtual discs to achieve file interaction.

Click "new" in the Operation window of hyper-V manager and select "Hard Disk ".

Select the format of the virtual disk as prompted. vhdx supports a larger disk space than vhd, but it is not supported in the system before Windows 8. Select and click "Next ".

Under "disk type", select "fixed size" or "dynamic expansion ". Do not select "differential" (the "differential" type will add a file after the disk is modified, and the number of files will increase with the increase in the number of modifications. If you modify the initial virtual disk, the relationship may be disrupted, so that the disk cannot be properly identified ). Click "Next" after the selection is complete ".

Name and physical location for the new Virtual Disk

Next, specify the content in the virtual disk. Select "create blank virtual hard disk. You can also copy the content of a physical or virtual hard disk. Pay attention to whether the disk capacity is sufficient. Confirm the disk content and click "Next"

After viewing the summary, click "finish" to complete the creation of the virtual disk.

Find the new Virtual Disk in resource manager. Double-click the disk you just created to mount it. An error message is displayed:

In this case, in disk management ("Control Panel"-"system and security"-"Management Tools"-"Computer Management", click "disk management" on the left) initialize the new disk.

In this case, the created virtual disk is equivalent to a new hard disk. Right-click the disk and choose "New simple volume ".

Allocate the size as prompted. Just split all data.

Assign a drive letter.

Format the disk.

Confirm the information and click "finish ".

In this way, after a moment, the new virtual disk can be used. Double-click the disk and copy the file to be shared to the disk.

After the copy is complete, right-click the virtual disk and select "offline" in disk management ".

Or in the resource manager, right-click the drive letter of the Virtual Disk and select "pop-up ".

At this time, the virtual disk has been separated from the physical machine. Go back to the hyper-V manager. If the VM is running, shut down the VM and add the SCSI controller to the VM settings-add hardware ".

Add "disk drive" to the newly added SCSI controller ".

Click Browse, select the virtual hard disk you just set as shared, and click application ".

After you enable the VM, you can view a new disk in the resource manager.

Open the Newly Added Disk and you will see the file you just shared.

When adding a file to a shared virtual disk through a physical machine again, first shut down the virtual machine, find the virtual disk image to mount it, torture the file, and pay attention to taking the Virtual Disk offline, after that, you can enable the virtual machine to share files.

A shared virtual disk can only be attached to one device at a time. That is to say, when a virtual disk is attached to a physical machine, the virtual machine cannot be started normally. If the virtual machine is running, the Virtual Disk cannot be accessed through a physical machine.

 

From: http://www.cnbeta.com/articles/219278.htm

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.