📜 ⬆️ ⬇️

Install iOS on OSX using ifuse

Recently I ran into the task of mounting an OSX 10.14 iPad as an external disk, with the ability to perform file operations from the console. On the Internet, I found quite a few instructions on how to do this using the ifuse file system. Unfortunately, iOS 12 did not work. The device was unlocked, data access is allowed, but despite this an error occurred:

Failed to connect to lockdownd service on the device. Try again. If it still fails try rebooting your device. 

This article is written to save time for those who have the same task.

On github, there are instructions for building ifuse and basic dependencies directly from the sources in the repository, but this is quite a painstaking way since the basic dependencies have many more dependencies, and they also have a lot more. Therefore, we will use the Homebrew package management system.
')
It is installed using a script on the offsite:

 /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" 

The script itself downloads everything homebrew needs, including the Xcode Command Line Tools. For ifuse, you need OSXFuse , which can be downloaded from the offsite or installed using the command:

 brew cask install osxfuse 

Now you need to install the main dependencies:

 brew uninstall --ignore-dependencies libimobiledevice brew uninstall --ignore-dependencies usbmuxd # libimobiledevice  usbmuxd    #     brew install --HEAD usbmuxd brew unlink usbmuxd brew link usbmuxd brew install --HEAD libimobiledevice 

IMPORTANT: If you already have stable versions of libimobiledevice and usbmuxd installed, you must remove them and install dev versions with the key --HEAD, otherwise an error will occur when connecting devices with iOS 12.

Finally, install iFuse:

 brew install ifuse 

Everything is ready, if one device is connected, then you can mount it with the command:

 ifuse ~/_ifuse_mount_point 

where ~ / _ifuse_mount_point is the path to the mount point.



Ifuse can mount a shared file system (or the whole if there is root), as well as application directories that support the file sharing API.

If several devices are connected, in order to select which of them to mount, you must use the -u switch

 ifuse ~/ifuse_mnt -u <UniqueDeviceID> 

In order to find out the UniqueDeviceID, you can use the command:

 ideviceinfo 



To start from Spotlight, you can create an AppleScript and save it as an application:

 try do shell script "/usr/local/bin/ifuse ~/_ifuse_mount_point" on error errMsg display dialog "ERROR: " & errMsg end try 

Source: https://habr.com/ru/post/459888/


All Articles