OneDrive Sync fails due to "unauthenticated" -Error

Hi,
OneDrive Sync worked for ~1 year, now it keeps failing with the Error: “failed to open source object: unauthenticated: Unauthenticated”.
Dry run always comes back successful. It sees the files, but is unable to copy them. The credential is also verified as valid.

Using TrueNas Core version: 13.0-U6.2

Does anyone have an idea?

1 Like

I have the same problem. Any news here?

I have the same problem. Someone can help with this?

Disclaimer: I am no expert in TrueNAS, FreeBSD, Unix or rclone so all below is probably a bad advice, do not follow.

Got same problem on Oct 23rd.
Appears to be this: Onedrive “Unauthenticated” issue - Suspected Bug - rclone forum
Why it starts now on our boxes? Who knows, mine was also working fine for months.

What I tried: updating to 13.0U6.2 - did not help. Updating credentials - did not help.

I do not know if rclone update is included in TrueNAS 13.3, this could be a viable path if it is.

But I decided to do it hard way.

  1. Follow this: SOLVED - enable pkg on 11.3 | TrueNAS Community
    1. make backup of /usr/local/etc/pkg/repos/FreeBSD.conf
    2. rename /usr/local/etc/pkg/repos/local.conf to local.conf.bak
    3. edit /usr/local/etc/pkg/repos/FreeBSD.conf as provided
  2. From shell
    1. pkg update. Ignore the library version warning.
    2. pkg upgrade rclone
    3. you’ll need to upgrade both PKG and RCLONE. Thankfully rclone is updated to 1.68 which has the fix in.
  3. Optional - you can restore the backups.

Proofs:
image
image

Thanks, but I can´t even find how to access the /usr… data files.
No idea how I even got so far lol…

Ah sure. No problem. You could use commands like cd to change directory, cp to copy and mv to rename.

BUT! You can also use something like WinScp and use a convenient Windows UI, it even has a built-in text editor :smiley: All you need to do is to connect to your server from a Windows machine and login as root.
If you are worried about providing credentials to a third-party app - just look at the number of downloads on the official site WinSCP :: Official Site :: Download

Had the same issue, its a rclone bug. ran sudo rclone selfupdate --beta from command, rebooted and it is now appears to be working as intended.

I had tried the stable release, but it didn’t fully work. It worked better than the error, but still failed on something… beta worked.

Version: beta: 1.69.0-beta.8384.b9207e572 (released 2024-10-29)

I can now say with 100%

Can confirm that @AgentMC’s solution worked for me. I tried @Aipoc76’s solution, but TrueNAS Core was refusing to allow the root account to update the binary complaining that it was write protected.

1 Like

Just adding a little something here as I too have discovered that one of my OneDrive Syncs started failing in October last year. I was able to update the rclone binary by outputting it to a new file to get around the issue of rclone writing to itself:

# rclone selfupdate --output /usr/local/bin/rclone.new
# mv /usr/local/bin/rclone /usr/local/bin/rclone.bak
# mv /usr/local/bin/rclone.new /usr/local/bin/rclone

Now rclone is on v1.69.0 my sync works again

Thanks. That did it for me. I have no idea how I even got so far to set up my own NAS, I dont even know what 90% of the words here mean. Just typing that in was the most I could manage. OneDrive Sync works again. Thanks!

Well, it’s thanks to your posts that I eventually landed on this solution. So thanks to you! Glad you got it sorted.

ry re-authenticating by removing and re-adding the OneDrive credentials in TrueNAS. Also, check if Microsoft made any API changes that might require updating your TrueNAS configuration. If the issue persists, try generating a new app password or access token for OneDrive. Let me know if you need further troubleshooting!

Anyone have any idea how I can get rclone updated to the latest version on truenas scale Electric Eel 24.10? none of my rclone syncs work due to the unathenticated bug on v1.67 :frowning_face:

Keep getting this error, even thought I am running as root in shell. I check the perms and root is the owner and can make read write and execute

2025/03/27 01:33:32 Error: /usr/local/bin: directory is not writable, please run self-update as root

Edit: command I am entering is sudo rclone selfupdate