Transferring files between guests

Discussions about using Linux guests in VirtualBox.
Post Reply
wgw
Posts: 2
Joined: 19. Dec 2020, 01:24

Transferring files between guests

Post by wgw »

I am planning to upgrade my Ubuntu 18LTS guest to Ubuntu 20LTS. I thought one way to do that would be to create a new 20LTS guest, run both the new 20LTS and the old 18LTS, and then copy my document and desktop folders to the new 20LTS system. (oof!)

Should 20LTS be set up as a network drive for 18LTS to write to? For the moment, the Host-only network seems to be the best way to transfer files.

In general, the online doc is a bit confusing, since folder "sharing" can have several meanings: 1) a folder shared between users on the same guest; 2) a folder shared between host and guest and 3) a network share between...well, the world.)

I could go the simple way by copying 18LTS to the Windows host and then back to 20LTS. I would prefer a linux to linux copy, however. Perhaps that's not really important?

Any pointers?
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Transferring files between guests

Post by mpack »

I wouldn't overcomplicate things. If both have access to a common shared folder I expect that will be enough.

And I don't recognize your complaint that a folder share can means multiple things. It can't. It means a folder marked as shareable, period. The only thing that can make it different is what you use it for, and what network the share is made available on, which surely shouldn't be hard aspects to grasp.

If you share using the "Guest Additions Shared Folder" (see VM settings | Shared Folders) feature then the share will only be visible to the VM the share is configured for, which means it's very secure. Multiple VMs can access the same host folder as individually configured shares, thus files can be made available to other VMs.

Of course a VM is just a PC, so another option is a standard (physical) network share. You configure true network shares using the host OS but bear in mind that access permissions is then a matter for you and the host OS. Potentially the Internet could have access, though if you have a home LAN behind a router then an Internet share would be unlikely to be done by accident IMO: try doing it deliberately sometime to see how many hoops you need to jump though!

I suggest that you go with GA shared folders, but be aware that the feature is not fully fledged. It works ok for copying files in and out, it works less well if you try to apply complicated permissions to each file, have files open for writing in guest or host apps, etc.
wgw
Posts: 2
Joined: 19. Dec 2020, 01:24

Re: Transferring files between guests

Post by wgw »

Thanks Mpak for the solid advice. I will go simple, and then, just out of curiosity, will explore a network share between guests. I'm a bit fascinated by the idea, which shows I'm not a very sophisticated user!
ghr
Volunteer
Posts: 376
Joined: 25. May 2007, 22:46
Primary OS: MS Windows 7
VBox Version: PUEL
Guest OSses: DOS, Win3x, Win95, WinXP, Ubuntu, OS/2

Re: Transferring files between guests

Post by ghr »

Typically... I 'd expect you to loose your executable bits when copying via windows....
Post Reply