Page 1 of 1
Move files from one guest to another
Posted: 15. Sep 2016, 01:31
by rickyoswaldiow
I've got two different Linux guests on a Windows 10 host and I want to transfer a large selection of files from one guest to the other. Is there a direct way to do this, without copying the files into the host first?
Re: Move files from one guest to another
Posted: 15. Sep 2016, 02:21
by socratis
To begin with, the files are already in your host, just in a different format, inside the virtual HD of your VM. If you are asking this because you don't want to allocate extra space in your host, I have to ask you a very important question first: are the HDs of your VMs dynamic? Because if they are, by moving them from a VM to the other, you're going to make matters worse. So are they dynamic or fixed?
Re: Move files from one guest to another
Posted: 15. Sep 2016, 03:39
by rickyoswaldiow
socratis wrote:To begin with, the files are already in your host, just in a different format, inside the virtual HD of your VM. If you are asking this because you don't want to allocate extra space in your host, I have to ask you a very important question first: are the HDs of your VMs dynamic? Because if they are, by moving them from a VM to the other, you're going to make matters worse. So are they dynamic or fixed?
No, I am changing to a different Linux OS. I suppose I can just launch my new guest and then mount the virtual HD of the old guest?
EDIT I just tried to add the old virtual HD as a 2nd storage attachment to the SATA controller. The virtual HD is encrypted with cryptsetup, it appears as a drive but when I enter the (correct) password it fails and the drive disappears... The home folder on the old guest is also encrypted, but I guess I'll cross that hurdle when I get to it.
Re: Move files from one guest to another
Posted: 15. Sep 2016, 04:06
by rickyoswaldiow
After the old drive disappears from the file manager, it is still listed correctly with fdisk -l
Code: Select all
Disk /dev/sdb: 350 GiB, 375809638400 bytes, 734003200 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x***
Device Boot Start End Sectors Size Id Type
/dev/sdb1 * 2048 999423 997376 487M 83 Linux
/dev/sdb2 1001470 734001151 732999682 349.5G 5 Extended
/dev/sdb5 1001472 734001151 732999680 349.5G 83 Linux
Re: Move files from one guest to another
Posted: 15. Sep 2016, 04:22
by rickyoswaldiow
In the end I've just created a temporary virtual drive without encryption. I mount it on the old VM first and copy my files onto it, then mount it on the new VM and pull them back off.