简体   繁体   English

如何将文件夹从Ubuntu复制到Mac

[英]How to copy folder from Ubuntu to mac

I have a virtual box installed with Ubuntu on it. 我安装了一个虚拟机,上面装有Ubuntu。 I want to copy a folder from Ubuntu to my local machine ie Macbook. 我想将文件夹从Ubuntu复制到本地计算机,即Macbook。

Is there a way to do so? 有办法吗?

Yes, there is. 就在这里。 I do it to copy files from Windows to my Ubuntu virual machine. 我这样做是为了将文件从Windows复制到我的Ubuntu虚拟机。 To do so, you have to: 为此,您必须:

1) Once you have launched your VM, in the top menu, select "Devices -> Install Guest Additions". 1)启动虚拟机后,在顶部菜单中,选择“设备->安装来宾添加项”。 After that, the Guest Additions .iso will be loaded. 之后,将加载Guest Additions .iso。

2) You will see the .iso loaded as a CD image. 2)您将看到.iso作为CD映像加载。 Run it and it will launch the install process in a Terminal. 运行它,它将在终端中启动安装过程。 Follow the instructions until the end of the install process. 请按照说明进行操作,直到安装过程结束。

3) Reboot your VM. 3)重新启动您的VM。

4) Run you VM, in the top menu, select "Devices -> Shared Folder Settings", click in 4)运行您的VM,在顶部菜单中选择“设备->共享文件夹设置”,单击 在此处输入图片说明 to add a new folder, and select the name and the route of the Shared Folder (for example, a folder with name LINUX created in your Mac). 添加新文件夹,然后选择共享文件夹的名称和路由(例如,在Mac中创建的名称为LINUX的文件夹)。

在此处输入图片说明

5) Now, go back to your Ubuntu VM, open a terminal and write (again, the name of the folder is just an example. In this case, both folders, Mac and Ubuntu shared folders share the same name): 5)现在,回到您的Ubuntu VM,打开一个终端并写(同样,该文件夹的名称只是一个例子。在这种情况下,这两个文件夹,Mac和Ubuntu共享文件夹都使用相同的名称):

$ sudo mkdir /media/LINUX 
$ sudo mount -t vboxsf LINUX /media/LINUX

6) Finally, if you want to mount the shared folder automatically every team you run your VM, do: 6)最后,如果要在运行VM的每个团队中自动安装共享文件夹,请执行以下操作:

$ gksudo gedit /etc/init.d/rc.local

And add the following line: 并添加以下行:

$ sudo mount -t vboxsf LINUX /media/LINUX

Hope it works! 希望它能起作用!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何将文件夹从本地Mac复制到Linux服务器 - How to copy folder from local mac to linux server 如何在Mac OS X上的文件夹复制期间关联文件 - How to associate file during folder copy on Mac OS X 如何将文件夹中的所有文件路径复制到Mac中的.txt - How to copy all file paths within a folder to a .txt in mac 如何将桌面文件夹从“桌面 - 本地”更改为 mac 上的其他文件夹? - How to change the desktop folder from “Desktop - Local” to a different folder on mac? 我可以将docker qcow2文件从ubuntu服务器复制到我的mac吗? - Can I copy the docker qcow2 file from an ubuntu server to my mac? 如何将源文件夹中的权限复制到目标? - How to copy permissions from source folder into destination? 如何使用sshfs autshount从mac到ubuntu的ssh密钥 - How to use ssh keys for sshfs automount from mac to ubuntu 从Ubuntu迁移到Mac上的开发环境是多么容易(或困难) - How easy (or difficult) is it to migrate to a development environment on Mac from Ubuntu 如何设置Ant脚本将文件从Mac复制到Windows? - How to setup Ant script to copy files from mac to windows? 如何制作Mac安装程序只需安装(复制)文件的.pkg文件? - How to make a .pkg that the Mac Installer will simply install (copy) files from?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM