VMware 上的 macOS 无法识别 iOS 设备

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/36139020/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-31 08:44:09  来源:igfitidea点击:

macOS on VMware doesn't recognize iOS device

iosmacosvmware

提问by Ken W.

I am using Mac OS in VMWare for iOS app development.

我在 VMWare 中使用 Mac OS 进行 iOS 应用程序开发。

After updating the OS and Xcode, the iOS device isn't available so I cannot test it.

更新操作系统和 Xcode 后,iOS 设备不可用,因此我无法对其进行测试。

When the device is plugged in to the PC, the device appears as connected in VMware and marked with green point. But, it does not appear in Xcode's devices.

当设备插入 PC 时,设备在 VMware 中显示为已连接并标有绿点。但是,它不会出现在 Xcode 的设备中。

I am using Mac OS 10.11. Does anybody have ideas?

我使用的是 Mac OS 10.11。有人有想法吗?

回答by PerracoLabs

I had the same issue, but was quite easy to solve. Follow the next steps:

我有同样的问题,但很容易解决。请按照以下步骤操作:

1) In the Virtual Machine (VMWare) settings:

1) 在虚拟机 (VMWare) 设置中:

  • Set the USB compatibility to be 2.0 instead of 3.0
  • Check the setting "Show all USB input devices"
  • 将 USB 兼容性设置为 2.0 而不是 3.0
  • 检查设置“显示所有USB输入设备”

2) Add the device into the list of allowed development devices in your Apple Developer's account. Without that step there is no way to use your device in Xcode.

2) 将该设备添加到您的 Apple Developer 帐户中允许的开发设备列表中。如果没有这一步,就无法在 Xcode 中使用您的设备。

Next some instructions: Register a single device

接下来的一些说明:注册单个设备

回答by Lenor

The other answer is lacking some additional information also in the following post. For example, when the iPhone keep Connect / Disconnect in loop. So here is a better solution:

另一个答案在以下帖子中也缺少一些附加信息。例如,当 iPhone 保持连接/断开连接时。所以这里有一个更好的解决方案:

  1. In vmware.logsearch the vid & pid of your iphone USB:
    Example:

    vmx | USB: Found device [name:Apple\ IR\ Receiver vid:05ac pid:12a8
    
  2. Close vmware (to unlock .vmx)

  3. In the .vmx, add:

    usb.quirks.device0 = "0xvid:0xpid skip-reset, skip-refresh, skip-setconfig"  
    

    Replace 0xvid:0xpidby the vid & pid found in vmware.log. Example:

    usb.quirks.device0 = "0x05ac:0x12a8 skip-reset, skip-refresh, skip-setconfig"
    
  4. In vmware > Edit virtual machine > USB Controller : USB compatibility : USB 2.0
    Active : Automatically connect new USB Devices
    Active : Show all USB input devices
    Active : Share Bluetooth devices with the virtual Machine

  5. Launch Mac OS and make sure that the mouse is Focus on vmware (or just use the login prompt if it appear)

  1. vmware.log搜索您的 iphone USB 的 vid 和 pid 时:
    例如:

    vmx | USB: Found device [name:Apple\ IR\ Receiver vid:05ac pid:12a8
    
  2. 关闭 vmware(解锁.vmx

  3. 在 中.vmx,添加:

    usb.quirks.device0 = "0xvid:0xpid skip-reset, skip-refresh, skip-setconfig"  
    

    替换0xvid:0xpidvmware.log. 例子:

    usb.quirks.device0 = "0x05ac:0x12a8 skip-reset, skip-refresh, skip-setconfig"
    
  4. 在 vmware > 编辑虚拟机 > USB 控制器:USB 兼容性:USB 2.0
    活动:自动连接新的 USB 设备
    活动:显示所有 USB 输入设备
    活动:与虚拟机共享蓝牙设备

  5. 启动 Mac OS 并确保鼠标是 Focus on vmware(或者如果出现登录提示就使用它)

回答by Yash Shah

I had same issue with VMWare 12.5.2 and OS: Mac OS Sierra.
These are few steps to solve this issue:(which worked for me.)

我在 VMWare 12.5.2 和 OS: Mac OS Sierra 上遇到了同样的问题。
这些是解决这个问题的几个步骤:(这对我有用。)

  1. Open VMWare.
  2. select your OS. (Mine is MacOS Sierra)
  3. Then In left hand side, Select option "Edit virtual machine settings"
  4. There will be one popup of setting. In that you need to select "Hardware" Tab.
  5. In that, there is option "USB Controller". Select that. You will find option right hand side.
  6. In that, Set USB compatibility as "USB 2.0" and check all 3 options as selected. options must be as following: i) Automatically connect new USB devices, ii) Show all USB input devices, iii) Share Bluetooth devices with the virtual machine
  7. Press OK.
  1. 打开 VMWare。
  2. 选择您的操作系统。(我的是 MacOS Sierra)
  3. 然后在左侧,选择选项“编辑虚拟机设置”
  4. 会弹出一个设置。您需要选择“硬件”选项卡。
  5. 其中,有选项“USB 控制器”。选择那个。您会在右侧找到选项。
  6. 其中,将 USB 兼容性设置为“USB 2.0”并选中所有 3 个选项。选项必须如下:i) 自动连接新的 USB 设备,ii) 显示所有 USB 输入设备,iii) 与虚拟机共享蓝牙设备
  7. 按确定。

There you go. It will work. Now you can power on your virtual machine.And try to connect your device with proper USB cable. Sometimes there can be issue with USB cable which are not authorized. Still if you have doubt, you can ask me here.

你去吧。它会起作用。现在您可以打开您的虚拟机。并尝试使用适当的 USB 电缆连接您的设备。有时可能会出现未经授权的 USB 电缆问题。如果你还有疑问,你可以在这里问我。

回答by Mike H

I am running an Iphone 8+ and VMWare macOS High Sierra on a Windows 10 machine.

我在 Windows 10 机器上运行 Iphone 8+ 和 VMWare macOS High Sierra。

I went through dozens of troubleshooting posts, and the none of them, excluding setting your VMs USBs to 2.0, helped. Through trial and error, and a decent amount of liquor, I have figured it out.

我浏览了数十篇故障排除帖子,除了将您的虚拟机 USB 设置为 2.0 之外,没有一个有帮助。通过反复试验和相当数量的酒,我已经弄清楚了。

SOLUTION:

解决方案:

Do these things, in this order:

按以下顺序做这些事情:

  1. With the VM off, go to your settings for whichever machine you're using, and change the USBs to 2.0. You can find this in the same menu that you allocated your ram and cores

  2. Make sure your phone is plugged in, and turned off.

  3. Boot up the VM, macOS.

  4. Turn Phone on when mac is booted

  5. Open Xcode

  1. 在 VM 关闭的情况下,转到您正在使用的任何机器的设置,并将 USB 更改为 2.0。您可以在分配内存和内核的同一菜单中找到它

  2. 确保您的手机已接通电源并已关闭。

  3. 启动虚拟机,macOS。

  4. mac 启动时打开手机

  5. 打开 Xcode

回答by Christian Rizov

Here is another thing to try (I'm using Windows 10):

这是另一件事要尝试(我使用的是 Windows 10):

  1. Stop the VM.
  2. Open Start.
  3. Type "Services".
  4. Find VMWare USB Arbitration Service and start it.
  5. Connect your device and hopefully, it will be detected.
  1. 停止虚拟机。
  2. 打开开始。
  3. 输入“服务”。
  4. 找到 VMWare USB 仲裁服务并启动它。
  5. 连接您的设备,希望它会被检测到。

This is what worked for me. I have no idea why the service wasn't started in the first place and it used to work fine with my IPhone 7. Good luck.

这对我有用。我不知道为什么最初没有启动该服务,它曾经在我的 iPhone 7 上运行良好。祝你好运。

回答by Ian Vink

Do what is suggested in the answer, but make sure you also click inside the VMso that OSX has the focus before you plug in the phone. In my case, I had to do that to make it work.

按照答案中的建议进行操作,但请确保click inside the VM在插入手机之前让 OSX 成为焦点。就我而言,我必须这样做才能使其发挥作用。

回答by Chris

I would like to add something.

我想补充一点。

For the devices to work in your Mac you have to make sure that they are connected to it. I don't know how this is handled in other versions but I am using VMware Workstation 12 Player

要使设备在 Mac 中工作,您必须确保它们已连接到 Mac。我不知道在其他版本中是如何处理的,但我使用的是 VMware Workstation 12 Player

If you go to Player (Top left corner) > Removable Devices > Enable the deviceyou want

如果你去Player (Top left corner) > Removable Devices > Enable the device你想去

Thats what i had to do.

这就是我必须做的。

回答by WarriorPoet

I have 2 computers with VMWare Workstation and Mac OS Sierra installed as the guest OS. First machine could recognize my iOS device whereas my second machine could notrecognize it. The second machine was exhibiting the same behavior as others reported where it would reconnect and disconnect with the iPhone endlessly.

我有 2 台安装了 VMWare Workstation 和 Mac OS Sierra 的计算机作为来宾操作系统。第一台机器可以识别我的 iOS 设备,而我的第二台机器无法识别它。第二台机器表现出与其他人报告的相同的行为,它会无休止地重新连接和断开与 iPhone 的连接。

Thankfully, my second machine had network connectivity problems with my VM. So I stumbled upon the solution when I reset my network settings for the VM.

谢天谢地,我的第二台机器在我的虚拟机上出现了网络连接问题。因此,当我为 VM 重置网络设置时,我偶然发现了解决方案。

You can try the following steps and see if it works for you. It worked for me.

您可以尝试以下步骤,看看它是否适合您。它对我有用。

  1. Go to Start Menu.
  2. Open VMWare folder.
  3. Start VMWare Network Editor.
  4. Click Change Settings button to assign Administrator privileges.
  5. Click Restore Defaults button.
  6. Open Virtual Machine.
  7. Verify internet connectivity on Mac OS.
  8. Connect iOS device. If iTunes launches on Mac, this means that the Mac has correctly identified your iOS device.
  1. 转到开始菜单。
  2. 打开 VMWare 文件夹。
  3. 启动 VMWare 网络编辑器。
  4. 单击更改设置按钮以分配管理员权限。
  5. 单击恢复默认值按钮。
  6. 打开虚拟机。
  7. 验证 Mac OS 上的互联网连接。
  8. 连接 iOS 设备。如果 iTunes 在 Mac 上启动,这意味着 Mac 已正确识别您的 iOS 设备。