Does iTunes backup and restore works for iOS app deployed via OTA?

落爺英雄遲暮 提交于 2019-12-20 23:56:12

问题


I am deploying an app via OTA (Testflight) to the clients. I have heard that if we use same provisioning profile which is using for Appstore distribution to deploy the OTA app, normal iTunes backup and restore process should work. Is it correct?

But currently I am doing that. I am using same App Store distribution profile to deploy via OTA too. BUT OTA app does not show/sync via iTunes?

Any idea??


回答1:


From the Backup section of this Apple iPad in Business document

"Applications you’ve developed in-house and distributed to your users with enterprise provisioning profiles won’t be backed up or transferred to the user’s computer. However, the device backup will include any data files the enterprise application creates."

I think you can replace "enterprise provisioning profiles" with non-AppStore profiles here.

In other words, iTunes only backs up apps downloaded from the AppStore.




回答2:


I can confirm that the actual .ipa file (bundle) is not backed up to iTunes or iCloud, but the data your app writes (via NSUserDefaults for example) is saved at least to iCloud.

To check it, head over to

  • Settings
  • iCloud
  • Storage and Backup
  • Manage Storage
  • select your device
  • under Backup Options, choose "show all apps"

You'll find your app's data here (make sure it's switched on to backup to iCloud).

Now you can either restore the app from Testflight, deploy it again via Xcode or copy the .ipa file over via iTunes. You should see its data pre-populated.




回答3:


Here are my observations from testing an iCloud restore on iOS 9.2 (backed up from iPhone 6S, restored to iPhone 6):

XCode deployed and Enterprise OTA apps appear along with all your other apps in the grayed out state once the restore completes.

If you tap one of them to start it downloading, it gets half way through, then will fail and then the app is removed from home screen (deleted I guess).

If you re-deploy an XCode app while the app is in the grayed-out state, the app will appear non-grayed out, but all the data will be gone.

If you re-download a beta app from TestFlight, the data is gone.

In my testing re-downloading an OTA Enterprise app had the same effect, though I'm not sure if this is simply because the apps in question don't backup to iCloud. My result is inconclusive.

I did not test apps deployed via iTunes AdHoc builds.

The iCloud restore experience is different to when you restore from an iTunes backup, where the icons of XCode deployed apps don't appear on your home screen after the initial sync, but the data is actually there, and once you re-deploy they will show up in the same place, and have their previous data.

My conclusion is that iTunes backups are superior when you want to preserve the data of non-app store apps. I can't be completely sure if this applies to Enterprise OTA apps, but I suspect it does.



来源:https://stackoverflow.com/questions/20120436/does-itunes-backup-and-restore-works-for-ios-app-deployed-via-ota

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!