When companies use OneDrive, they usually want to control its use via Group Policy to prevent data loss or excessive resource consumption. However, the required administrative templates (ADMX templates) must first be localized under Windows and copied to the correct directory.

If you use the Windows 10 or 11 administrative templates on a local workstation or in the Central Store, you will find several settings in the GPO editor under Computer Configuration > Policies > Administrative Templates > Windows Components > OneDrive.

Settings for OneDrive included in Windows 1011 are largely outdated

Settings for OneDrive included in Windows 1011 are largely outdated

These settings, from skydrive.admx, are largely outdated, and some require an old Windows version. However, the option to disable OneDrive ("Prevent the usage of OneDrive for file storage") still works with newer versions of the operating system.

To get the current settings for OneDrive, you must either copy OneDrive.admx, including the required language files locally, to %systemroot%\PolicyDefinitions or transfer them to the Central Store.

Find current templates

Microsoft does not offer the templates for download, but they are located in a directory below the installation location of the sync app. The path depends on how the app was installed.

The easiest way to find the required files is to run this short PowerShell script:

$OnePath = ("$env:LOCALAPPDATA\Microsoft\OneDrive", `
"$env:ProgramFiles(x86)\Microsoft\OneDrive", `
"$env:ProgramFiles\Microsoft OneDrive")
$OnePath | foreach{
    Get-ChildItem "$_\*\adm\onedrive.adm?" -ErrorAction SilentlyContinue
} 
Finding the location of the ADMX files using a PowerShell script

Finding the location of the ADMX files using a PowerShell script

As you can see from the output, the path contains the build number of the sync client. This is continually updated, and you can usually find the administrative templates only under the latest version. Therefore, you should check here regularly and use the latest ADMX file.

The ADMX and ADML files can be found under the directory of the latest OneDrive build

The ADMX and ADML files can be found under the directory of the latest OneDrive build

Transfer language files to the correct directory

The adm directory contains not only OneDrive.admx but also OneDrive.adml. This is the English language file, which should actually be in the en-US subdirectory.

Other language files can be found in their respective subdirectory, but Microsoft deviates from the usual naming convention. For example, the German language file is located in adm\de instead of in the de-DE directory. When transferring the ADML files to %systemroot%\PolicyDefinitions or to the central store, it is important to specify the correct target directories for the language files.

Use the new settings

After installing the current ADMX, the settings for OneDrive can be found under Policies > Administrative Templates > OneDrive, for both the computer and the user configuration. It also gives you many more group policies than the old SkyDrive template.

The group policies are included in the current ADMX template

The group policies are included in the current ADMX template

Summary

Windows 10 and 11 contain largely outdated OneDrive settings for group policies. The current ADMX and ADML files can be found under the installation location of the latest sync client.

Since this is subject to shorter update intervals than Windows, Microsoft does not include the associated administrative templates in the ADMX Download or in the PolicyDefinitions directory.

Subscribe to 4sysops newsletter!

Admins should therefore regularly check the OneDrive templates for updates and update them in the Central Store.

0 Comments

Leave a reply

Your email address will not be published.

*

© 4sysops 2006 - 2023

CONTACT US

Please ask IT administration questions in the forums. Any other messages are welcome.

Sending

Log in with your credentials

or    

Forgot your details?

Create Account