企业版app在iOS8上无法安装的几个问题解决

来源:互联网 发布:数据库分区和分表 编辑:程序博客网 时间:2024/06/05 17:33
首先要吐槽下国内的论坛水分略多,以下问题大多是查询stackoverflow等论坛解决的。
推荐一款软件,Log Guru,用来查看app安装时的系统日志,很多问题要看日志才知道错误点。

1.首先有几个比较基础的问题:
(1)若要在网页上安装app,则iOS7.1及以后的plist文件的下载地址要放在https的网址下,而ipa文件下载地址不一定要https。
(2)ipa文件放到服务器上时,要设置下iis的ipa文件下载支持,否则点击下载后会图标一直停留在“等待中”。
(3)程序下载安装时,快安装完成时,图标的显示突然回退,那就是provisioning profile的问题了,查看日志会看到类似下面的信息,遇到这种情况你得检查下provisioning profile是否正确了
installd?entitlement 'get-task-allow' has value not permitted by provisioning profile 

2.iOS8安装到3分之2左右的时候停止,然后弹出“此时无法安装应用程序”的提示框。
        我遇到这种情况时以为是签名或者provisioning profile的错误,然后各种检查重新发布,但是没有解决。查看日志后发现这样一条错误:
0x1022dc000 -[MIContainer makeContainerLiveReplacingContainer:withError:]: Made container live for com.kmvc.myapp at...

然后在
stackoverflow上找到同样的问题,下面有这么一条回答:(地址:http://stackoverflow.com/questions/25760484/ios8-beta-ad-hoc-app-download-itms-services),主要的答案是这么说的:
Specify a 'display-image' and 'full-size-image' as described here:http://www.informit.com/articles/article.aspx?p=1829415&seqNum=16
iOS8 requires these images
        
也就是说iOS8的下载安装是必须要display-image和full-size-image这两个文件,文件地址要和你的plist文件中写的一致。因为之前iOS7的安装没有这两个图片文件也可以安装,就一直疏忽了,也没想到会是这个导致的无法安装,经过这次事情后得严格按照苹果的规范了,不然真是出了问题都很难发现。

3.之前安装过该app的iOS8系统点击安装后没有反应。
        还是查看日志,只有一条记录:
LoadExternalDownloadManifestOperation: Ignore manifest download, already have bundleID: com.mycom.MyApp
遇到这种情况,我按照论坛上说的(http://stackoverflow.com/questions/25772664/enterprise-app-update-distribution-on-ios-8#)更改plist文件的bundle ID(是下载时用的plist文件不是项目的bundle ID),然后重新点击就可以下载安装了。
<pre name="code" style="word-wrap: break-word; margin-top: 0px; margin-bottom: 0px; padding: 0px; white-space: pre-wrap;"><span style="word-wrap: break-word; font-family: 'sans serif', tahoma, verdana, helvetica;"> </span><div style="word-wrap: break-word;"><span style="word-wrap: break-word; color: rgb(0, 0, 0);"><span style="word-wrap: break-word;"><span style="word-wrap: break-word; font-size: 32px;"><span style="word-wrap: break-word; font-size: 18px;"> </span></span><span style="word-wrap: break-word; font-size: 16px;">这两天就解决了这些问题,以后遇到再补充。 <span style="word-wrap: break-word; font-size: 18px;"><span style="word-wrap: break-word; color: rgb(76, 51, 229);"><span style="word-wrap: break-word; color: rgb(0, 51, 153);">转载请声明出处</span></span></span></span></span></span> :<a target=_blank href="http://blog.chinaunix.net/uid-29439762-id-4830442.html" target="_blank" style="word-wrap: break-word; text-decoration: none; color: rgb(86, 86, 86);">http://blog.chinaunix.net/uid-29439762-id-4830442.html</a></div><div style="word-wrap: break-word;"></div><div style="word-wrap: break-word;"><span style="color: rgb(51, 51, 51); font-family: Arial; line-height: 26px; font-size: 24px;">iOS7可以下载没有任何问题,iOS8发现挂在官网上的企业版的app点击了提示是否安装应用程序,但是确认以后没有反应,找了很久,都没有发现问题。后来查看了的device console发现安装的时候出现</span><span style="color: rgb(51, 51, 51); font-family: Arial; font-size: 14px; line-height: 26px;"></span><pre class="default prettyprint prettyprinted" name="code" style="white-space: pre-wrap; word-wrap: break-word; color: rgb(51, 51, 51); font-size: 14px; line-height: 26px; background-color: rgb(255, 255, 255);"><span style="font-size: 24px;"><code><span style="color: rgb(255, 0, 0);"><span class="typ">LoadExternalDownloadManifestOperation</span><span class="pun">:</span><span class="pln"> </span><span class="typ">Ignore</span><span class="pln"> manifest download</span><span class="pun">,</span><span class="pln"> already have bundleID</span><span class="pun">:</span><span class="pln"> com</span><span class="pun">.</span><span class="pln">mycom</span><span class="pun">.</span><span class="typ">MyApp</span></span></code></span>

后来查资料外国开发者推测是iOS8的一个bug:

The biggest issue for us is that we can not reproduce this onany of our devices. Our suspicion is that iOS 8 has some internalcache with bundle IDs and just doesn't install a build if it thinksthat an app with this bundle ID is already installed. As theinstallation doesn't even start, we think that iOS is matching thebundle identifier from the manifest plist against this cache.

它会寻找是否ios缓存的identifier与bundle identifier在plist文件中匹配,如果匹配,它会认为已经安装了,就不会有反应。 上面解释的很清楚。所以解决办法就是在plist文件中修改bundle Identifier。

比如你的plist文件的BundleID是com.mycom.MyApp,则修改成com.mycom.MyApp.fixios8。(创建一个假的bundleID,可以随便取,这样ios就不会认为你已经安装。记住是修改plist文件的bundleID,不是应用程序的bundleID)

发布以后就发现可以了。只是如果你已经安装了app,则会出现一个新的下载的空白icon,因为这个app的bundleID与你plist的bundleID不一致,当下载完成后,会覆盖原本app,因为它会检测到下载安装的app的bundleID已经存在并且覆盖。

完美解决。


                                             
0 0
原创粉丝点击