简体   繁体   English

Android 设备策略同步在手动完成之前不起作用

[英]Android Device Policy sync does not work until done manually

We have some android devices attached to Android Management API as fully managed work devices.我们有一些 Android 设备作为完全托管的工作设备连接到 Android Management API。

Now when we push out some changes to the device policy such as Factory Reset Disabled , Adjust Volume Button Disabled or any other such controls, the devices don't sync it immediately.现在,当我们对设备策略进行一些更改时,例如Factory Reset Disabled Adjust Volume Button Disabled或任何其他此类控件,设备不会立即同步它。

In fact we have to manually open up Android Device Policy and click on Sync for it actually get the changes.事实上,我们必须手动打开 Android Device Policy 并点击Sync才能真正获得更改。

This is really troublesome because at times the policy doesn't sync for hours together and the devices don't get the updates.这真的很麻烦,因为有时策略不会同步几个小时并且设备没有获得更新。

Also we load up the whole policy of the device for every control change because if not the other controls go back to null , can Patch or UpdateMask be used to avoid this?此外,我们为每个控件更改加载设备的整个policy ,因为如果其他控件没有返回nullUpdateMask可以使用PatchUpdateMask来避免这种情况?

Can someone please suggest me of what can be done to make sure the device gets the policy changes immediately ?有人可以建议我如何确保设备立即获得策略更改吗?

I've run into the same issue, despite the documentation assuring that policy updates are applied to all devices that utilize the updated policy.我遇到了同样的问题,尽管文档确保策略更新应用于所有使用更新策略的设备。

The best workaround I have found is to issue a REBOOT command to any device that I specifically want to update.我发现的最佳解决方法是向我特别想要更新的任何设备发出 REBOOT 命令。 While this usually leads to the device rebooting twice, it does immediately happen, and after the second reboot the device seems to pickup policy updates.虽然这通常会导致设备重新启动两次,但它确实会立即发生,并且在第二次重新启动后,设备似乎会获取策略更新。

Try with the settings: "appAutoUpdatePolicy": "ALWAYS",尝试设置:“appAutoUpdatePolicy”:“ALWAYS”,

"systemUpdate": { "type": "AUTOMATIC" } “系统更新”:{“类型”:“自动”}

I have my device update in a few seconds.我的设备会在几秒钟内更新。

Since I tried with new version, this issue is not resolved.由于我尝试了新版本,因此未解决此问题。 Someone guide me to solve it.有人指导我解决它。

<project>
  <dependencies>
    <dependency>
      <groupId>com.google.apis</groupId>
      <artifactId>google-api-services-androidmanagement</artifactId>
      <version>v1-rev20201209-1.31.0</version>
    </dependency>
  </dependencies>
</project>

@Fred @sudhu @Fred @sudhu

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM