Android:LicenseValidator(31668) 联系许可服务器时出错
我们目前正在尝试解决此问题,该问题仅在我们用户的某些设备上发生。
我们的应用程序是一个报告系统,允许用户收集信息并拍照,然后将其导出到我们的服务器。成功导出后,他们可以从其在线帐户下载各种报告。
我们在某些 Android 设备(使用 froyo 运行)上遇到的症状如下
- 我们的应用程序变得迟缓且缓慢(所有列表和按钮响应都有延迟)
- 如果用户拍照,则需要 10-15 秒才能完成要保存的照片
- 用户所做的所有更改(向报告添加新项目)不会保存到磁盘,并且如果应用程序(甚至整个设备)崩溃,用户将丢失他/她拥有的所有数据迄今为止收集的。
仔细检查这些有问题的平板电脑(所有这些都是三星 Galaxy 7" 平板电脑),我们发现后台不断调用 LicensingServer,这使得一切都变得繁忙。我们的应用程序不使用许可证,并且此后台请求许可证检查与我们的应用程序无关。您可以从 logcat 的以下部分注意到,设备每秒
02-03 次 调用许可服务器。 14:38:47.976 LicenseValidator(31668)联系许可服务器时出错。 02-03 14:38:47.823 LicenseValidator(31668)联系许可服务器时出错。 02-03 14:38:47.710 LicenseValidator(31668)联系许可服务器时出错。 02-03 14:38:47.577 LicenseValidator(31668)联系许可服务器时出错。 02-03 14:38:47.347 LicenseValidator(31668)联系许可服务器时出错。 02-03 14:38:47.218 LicenseValidator(31668)联系许可服务器时出错。 02-03 14:38:47.108 LicenseValidator(31668)联系许可服务器时出错。
这种持续的打击对一切都会产生不利的影响。
我的问题是,为什么它会多次尝试联系许可服务器,以及是否有办法阻止它这样做。作为我们设置的一部分,我们总是关闭“后台数据”和“自动同步”(位于“设置”->“帐户和同步”下)。我们这样做的原因是我们不希望我们的用户访问 Android Market(它是作为本合同的一部分提供给我们的管理规则手册的一部分)。
即使我们打开后台数据,主 Gmail 帐户也是我们设置的帐户,并且用户没有密码。在这种情况下,有时设备会进入非同步状态(在顶部通知栏上显示为橙色三角形图标)。在这种情况下,设备也会陷入每秒调用许可服务器 8-9 次的疯狂状态。
有没有办法让设备完全停止联系许可服务器。我们花了一周的时间搜索在线论坛和 Android 文档的每一个可能的角落。我们还没有遇到任何人面临这个问题。任何有关解决方案的帮助或提示将不胜感激。
乌斯曼·查马德
We are currently trying to solve this issue which is occurring only on some devices among our users.
Our application a reporting system which lets the user to collect information and take pictures which they can then export to our server. Once exported successfully they can download various reports from their on-line account.
The symptoms that we are getting on some of the android devices (running with froyo) are as following
- Our app becomes sluggish and slow (all the lists and buttons respond with a lag)
- If user takes a photograph it takes 10-15 seconds to for that photo to get saved
- All the changes that user is making (adding new items to their report) does not get saved to disk and in the event of app (or even the whole device) crashing user looses all the data that he/she has so far collected.
On close inspection of these problematic tablets (all of these are Samsung Galaxy 7" tablets), we have found that there is a constant call to LicensingServer going in the background which is keeping everything busy. Our app does not use license and this background request for licence check has nothing to do with our app. Still the effect is very negative on our app. As you can notice from following section of logcat, the device is making 8-9 calls to the licensing server every seconds.
02-03 14:38:47.976 LicenseValidator(31668)Error contacting licensing server.
02-03 14:38:47.823 LicenseValidator(31668)Error contacting licensing server.
02-03 14:38:47.710 LicenseValidator(31668)Error contacting licensing server.
02-03 14:38:47.577 LicenseValidator(31668)Error contacting licensing server.
02-03 14:38:47.347 LicenseValidator(31668)Error contacting licensing server.
02-03 14:38:47.218 LicenseValidator(31668)Error contacting licensing server.
02-03 14:38:47.108 LicenseValidator(31668)Error contacting licensing server.
This constant hit has adverse effect on everything.
My question is, why does it try to contact licensing server so many times and if there is a way to stop it from doing so. As a part of our set-up we always turn off the "Background data" and "Auto sync" (which is under Settings - > Accounts and sync). The reason we do this because we don't want our users to access Android Market (its a part of management rulebook given to us as a part of this contract).
Even if we turn on the Background data the master Gmail account is the one that is set by us and the user does not have password for it. In this case sometimes the device goes into non-sync state (which is shown as an orange triangle icon at the notification bar at top). In this case also the device goes into this madness calling the licensing server 8-9 times every second.
Is there a way to make the device stop contacting the licensing server completely. We have spend last one week searching every possible corner of on-line forums and Android documentation. We have not yet come across anyone out there facing this problem. Any help or hint towards a solution will be hugely appreciated.
Usman Chamad
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我收到一条消息,内容为“市场许可错误......为了验证您的许可证,您需要互联网连接并登录到您的 Google 帐户。”单击“验证许可证”按钮后,会返回一条消息“许可证验证失败”。
许多人,像我一样,关闭“后台同步”和“同步”。他们的 Droids/Evo 上的“自动同步”(设置/帐户和同步/后台数据),因为它使用大量电池电量。我疯狂地想弄清楚如何让那条烦人的消息不再每 30 秒出现一次。
因此,我登录了我的 Google G-mail,进入“设置/帐户和”。同步/后台同步。选中“后台同步”旁边的复选框,然后单击按钮以验证许可证。它起作用了,甚至在我不知道它是否起作用大约 5 分钟后返回一条消息“许可证验证成功”。当然,然后我取消选中“后台同步”旁边的框,也取消选中“自动同步”旁边的框。
我必须每周查看一次这些设置,因为它似乎偶尔会神奇地自我检查一次,可能是在更新之后,我不知道。但是,当我注意到我的电池寿命用得太快时,我检查以确保“后台同步”和“自动同步”旁边的框未被选中。
I was receiving a message that read "Market Licensing Error ... In order to validate your license, you need an Internet connection and to be logged into your Google Account." After clicking on the "validate license" button, it would come back with a message "License Validation Failed".
Many people, like me, turn off "Background Sync" & "Auto Sync" (Settings/Accounts & Sync/Background Data) on their Droids/Evo because it uses a great deal of battery power. I was going crazy trying to figure out how to get that annoying message to stop appearing every 30 seconds.
So, I logged into my Google G-mail, went into Settings/Accounts & Sync/Background Sync. Checked the box next to "Background Sync" and clicked the button to validate license. It worked, and even came back with a message "License Validation Successful" after about 5 minutes of me not knowing if it would even work. I then, of course, un-checked the box next to "Background Sync" and also un-checked the box next to “Auto Sync”.
I have to look at these settings about once a week because it seems to magically check itself once in a while, probably after an up-date, I don't know. But, when I notice my battery life is getting used too quickly, I check to make sure the box next to "Background Sync" and "Auto Sync" are un-checked.