4

Here is my environment:

  • Windows 10 (also occurs with 8.1)
  • System partition C: is not encrypted using bitlocker
  • "Data" partition E: is encrypted using bitlocker with manual unlock
  • OneDrive desktop sync location: E:\OneDrive

When Windows starts, I manually unlock E: using my passphrase.

The problem

When my computer starts, OneDrive complains that my OneDrive sync location is not available. This is because the location is within a bitlocker-protected drive that is not yet unlocked.

We couldn't find the location of your OneDrive folder. Click OK to reconfigure your OneDrive folder.

We couldn't find the location of your OneDrive folder. Click OK to reconfigure your OneDrive folder.

[OK] [Close]

Whether I click OK or close, OneDrive deletes its own configuration and starts from scratch. "Hello, this is OneDrive, a place for all your files blah blah blah". I am forced to reconfigure the sync location and a very long sync operation starts.

sync operation

This has been reported on technet and on uservoice [1, 2]. The only answer people get is:

Encrypt your system partition and enable auto-unlock for your secondary partition. This way the partition will be unlocked before OneDrive starts.

OK but I do not want to encrypt the system partition. I want OneDrive to wait for my partition to be unlocked and then do its job.

Question

Do you know a way of delaying the startup of the OneDrive desktop app?
This would avoid the bug.

Do you know any other trick that would prevent the app from deleting its own configuration and state when this occurs?

4

This is how I solved this: So OneDrive in a secondary drive that has BitLocker enabled.

Problem is OneDrive should start and prompt for the drive to be unlocked, rather than crash and assume all needs to be set up again.

To fix you need to 1. Stop OneDrive from starting at boot + 2. Start OneDrive automatically when the drive is ready/unlocked.

  1. In OneDrive settings just untick the "Start OneDrive automatically when I sign in to Windows"

  2. Open "Task Scheduler"

  3. Click "Action" - "Create Task" (not basic)

  4. Change these settings (leaving the rest as defaults):

a) General tab

  • Name: Start OneDrive after BitLocker

b) Triggers tab - New...

  • Begin the task: On an event
  • Log: Microsoft-Windows-BitLocker-API/Management
  • Event ID: 782

c) Actions tab - New...

  • Action: Start a program
  • Program/script: powershell.exe
  • Add arguments: %USERPROFILE%\AppData\Local\Microsoft\OneDrive\OneDrive.exe /background

d) Conditions tab

  • Untick "Start the task only if the computer is on AC power"

    1. Done

So now OneDrive should not start after boot/logon and as soon as you unlock the encrypted drive OneDrive will start automatically.

0

You can prevent OneDrive from starting automatically. Open the task manager and disable OneDrive startup in the Startup tab.

disabled onedrive startup

Then when your drive is ready for use, start the OneDrive application.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.