Closed zner0L closed 1 year ago
I ran into a similar problem with libimobiledevice both on macOS and on Linux. On Linux, I ran into:
libimobiledevice
ERROR: Could not connect to lockdownd: Missing HostID (-20)
This seemed to be related to https://github.com/libimobiledevice/libimobiledevice/issues/36, where the problem is wrong permissions on the /var/lib/lockdown folder. And sure enough, they were:
/var/lib/lockdown
❯ stat /var/lib/lockdown File: /var/lib/lockdown Size: 0 Blocks: 0 IO Block: 4096 directory Device: 0,33 Inode: 901451 Links: 1 Access: (2775/drwxrwsr-x) Uid: ( 0/ root) Gid: ( 0/ root) Context: unconfined_u:object_r:var_lib_t:s0
I fixed it but giving the folder to usbmuxd:
usbmuxd
❯ sudo chown usbmuxd:usbmuxd /var/lib/lockdown
On macOS the problem was similar, but slightly different. Here I ran into:
ERROR: Could not connect to lockdownd: Missing HostID (-21)
Note the different error number! This time, a different issue was relevant: https://github.com/libimobiledevice/libimobiledevice/issues/922 It mentioned repairing the device:
❯ idevicepair unpair && idevicepair pair
This fixed it as well.
I am not sure if we want to implement this in appstraction. Maybe the pairing procedure is a sensible thing to do in ensureDevice if encounter this error?
ensureDevice
Is this still relevant with pymobiledevice3?
No, I don’t think so.
I ran into a similar problem with
libimobiledevice
both on macOS and on Linux. On Linux, I ran into:This seemed to be related to https://github.com/libimobiledevice/libimobiledevice/issues/36, where the problem is wrong permissions on the
/var/lib/lockdown
folder. And sure enough, they were:I fixed it but giving the folder to
usbmuxd
:On macOS the problem was similar, but slightly different. Here I ran into:
Note the different error number! This time, a different issue was relevant: https://github.com/libimobiledevice/libimobiledevice/issues/922 It mentioned repairing the device:
This fixed it as well.
I am not sure if we want to implement this in appstraction. Maybe the pairing procedure is a sensible thing to do in
ensureDevice
if encounter this error?