What is the problem you are having with rclone?
I have Windows boxes with existing OneDrive access to personal storage space. I am
trying, on Fedora Linux, to 'rclone config' access to the same MSFT OneDrive personal storage space. At the config step where a local browser window comes up, the incorrect Microsoft account is chosen for me to try to connect to my OneDrive. "Success!" is claimed, but rclone emits error message
"Failed to query available drives: HTTP error 403 ....
... "You do not have access to create this personal site ...
I have 2 "Microsoft accounts"
1.) jhoward@alumni.caltech.edu for normal personal Windows login
2.) jhoward@alumni.caltech.onmicrosoft.com for the sole use to access MSFT Exchange e-mail
The browser brought up by 'rclone config' pre-fills-in my login ID to 2.) which is NOT the owner of any OneDrive space. Attempts to change login ID "Use another account" to 1.) are not successful.
Run the command 'rclone version' and share the full output of the command.
rclone v1.69.1
- os/version: fedora 41 (64 bit)
- os/kernel: 6.13.9-200.fc41.x86_64 (x86_64)
- os/type: linux
- os/arch: amd64
- go/version: go1.24.0
- go/linking: static
- go/tags: none
This is latest as of 11-Apr-2025
Which cloud storage system are you using? (eg Google Drive)
Microsoft OneDrive
The command you were trying to run (eg rclone copy /tmp remote:tmp
)
$ rclone config # with the following interactive entries
e/n/d/r/c/s/q> n
name> JamesDavidHoward-MSFT-OneDrive
Storage> 36 (Microsoft OneDrive)
client_id> (empty)
client_secret> (empty)
region> 1 (MSFT Cloud Global)
tenant> (empty)
edit advanced> n (NOT advanced config)
local web browser> y (local default is Google Chrome)
... local browser window starts, quickly shows WRONG account login, but
claims "Success!"
... rclone continues, stating:
2025/04/11 18:01:40 NOTICE: Waiting for code...
2025/04/11 18:01:41 NOTICE: Got code
config_type> 1 (OneDrive Personal ...)
Failed to query available drives: HTTP error 403 (403 Forbidden)
returned body: "{\"error\":{\"code\":\"notAllowed\",\"message\":\"You do not have access to create this personal site or you do not have a valid license\",\"innerError\":{\"code\":\"provisioningNotAllowed\",\"date\":\"2025-04-12T01:04:38\",\"request-id\":\"999f2f21-b409-4e75-abe5-848cdb1fe917\",\"client-request-id\":\"999f2f21-b409-4e75-abe5-848cdb1fe917\"}}}"
config_type> ^C [SIGINT]
$ # Oops.
The rclone config contents with secrets removed.
rclone.conf shows only the existing (working) Google Drive setup, since I'm trying to create a NEW entry for MSFT OneDrive
[Documentation]
# ~/.config/rclone.conf
# $Id: rclone.conf,v 1.4 2023/04/02 23:33:19 jdhoward Exp $
# This file is read by the rclone mount command line within ~/.config/systemd/user/rclone-GDriveMount.service
[JamesDavidHowardGoogleDrive]
type = drive
client_id = 621986495259-538f1nfr6an3he4pt5m7mpgphknskb5m.apps.googleusercontent.com
client_secret = R*****************U
scope = drive
token = {"access_token":"ya29.a0AZYkNZiLdP3lpHExipm-OwkTLboN11CTegVVsG********************PSnltbKGlob4DrPqgFbMuOb-FIVL2bwQ2nBGLpCO0PLlonSEcMpVzeFh7fN8IN6RVwHK8vJwAg772VPH2xJdJymcFHVHp_y0foALeS-XthTuzAaCgYKAQQSAR**************SmnfQf6QOnIjW94prbFQ0178","token_type":"Bearer","refresh_token":"1//06AD3WEOhwVO_CgYIARAAGAYSNwF-L9IrqNcu0MTC************GdBzY_uZrYRRNHBxGHVpy8LRhEu-BJg1zScXXRpcrTjvnJ1c","expiry":"2025-04-11T18:27:03.003052047-07:00"}
root_folder_id = 0ACjc*********k9PVA
A log from the command with the -vv
flag
No log messages were produced
2025/04/11 19:07:13 DEBUG : rclone: Version "v1.69.1" starting with parameters ["rclone" "-vv" "config"]
2025/04/11 19:07:13 DEBUG : Using config file from "/home/jdhoward/.config/rclone/rclone.conf"
Current remotes:
Name Type
==== ====
Documentation
JamesDavidHowardGoogleDrive drive
e) Edit existing remote
n) New remote
d) Delete remote
r) Rename remote
c) Copy remote
s) Set configuration password
q) Quit config
e/n/d/r/c/s/q> n
Enter name for new remote.
name> test-1drive
Option Storage.
Type of storage to configure.
Choose a number from below, or type in your own value.
... list abbreviated
36 / Microsoft OneDrive
\ (onedrive)
... list abbreviated
Storage> 36
2025/04/11 19:07:57 DEBUG : test-1drive: config in: state="*all", result=""
2025/04/11 19:07:57 DEBUG : test-1drive: config out: out=&{State:*all-set,0,false Option: OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:07:57 DEBUG : test-1drive: config: reading config parameter "client_id"
Option client_id.
OAuth Client Id.
Leave blank normally.
Enter a value. Press Enter to leave empty.
client_id>
2025/04/11 19:08:21 DEBUG : test-1drive: config in: state="*all-set,0,false", result=""
2025/04/11 19:08:21 DEBUG : test-1drive: config out: out=&{State:*all,1,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:21 DEBUG : test-1drive: config in: state="*all,1,false", result=""
2025/04/11 19:08:21 DEBUG : test-1drive: config out: out=&{State:*all-set,1,false Option: OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:21 DEBUG : test-1drive: config: reading config parameter "client_secret"
Option client_secret.
OAuth Client Secret.
Leave blank normally.
Enter a value. Press Enter to leave empty.
client_secret>
2025/04/11 19:08:24 DEBUG : test-1drive: config in: state="*all-set,1,false", result=""
2025/04/11 19:08:24 DEBUG : test-1drive: config out: out=&{State:*all,2,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:24 DEBUG : test-1drive: config in: state="*all,2,false", result=""
2025/04/11 19:08:24 DEBUG : test-1drive: config out: out=&{State:*all,3,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:24 DEBUG : test-1drive: config in: state="*all,3,false", result=""
2025/04/11 19:08:24 DEBUG : test-1drive: config out: out=&{State:*all,4,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:24 DEBUG : test-1drive: config in: state="*all,4,false", result=""
2025/04/11 19:08:24 DEBUG : test-1drive: config out: out=&{State:*all,5,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:24 DEBUG : test-1drive: config in: state="*all,5,false", result=""
2025/04/11 19:08:24 DEBUG : test-1drive: config out: out=&{State:*all,6,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:24 DEBUG : test-1drive: config in: state="*all,6,false", result=""
2025/04/11 19:08:24 DEBUG : test-1drive: config out: out=&{State:*all-set,6,false Option:global OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:24 DEBUG : test-1drive: config: reading config parameter "region"
Option region.
Choose national cloud region for OneDrive.
Choose a number from below, or type in your own value of type string.
Press Enter for the default (global).
1 / Microsoft Cloud Global
\ (global)
2 / Microsoft Cloud for US Government
\ (us)
3 / Microsoft Cloud Germany (deprecated - try global region first).
\ (de)
4 / Azure and Office 365 operated by Vnet Group in China
\ (cn)
region> 1
2025/04/11 19:08:26 DEBUG : test-1drive: config in: state="*all-set,6,false", result="global"
2025/04/11 19:08:26 DEBUG : test-1drive: config out: out=&{State:*all,7,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:26 DEBUG : test-1drive: config in: state="*all,7,false", result=""
2025/04/11 19:08:26 DEBUG : test-1drive: config out: out=&{State:*all,8,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:26 DEBUG : test-1drive: config in: state="*all,8,false", result=""
2025/04/11 19:08:26 DEBUG : test-1drive: config out: out=&{State:*all,9,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:26 DEBUG : test-1drive: config in: state="*all,9,false", result=""
2025/04/11 19:08:26 DEBUG : test-1drive: config out: out=&{State:*all,10,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:26 DEBUG : test-1drive: config in: state="*all,10,false", result=""
2025/04/11 19:08:26 DEBUG : test-1drive: config out: out=&{State:*all,11,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:26 DEBUG : test-1drive: config in: state="*all,11,false", result=""
2025/04/11 19:08:26 DEBUG : test-1drive: config out: out=&{State:*all,12,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:26 DEBUG : test-1drive: config in: state="*all,12,false", result=""
2025/04/11 19:08:26 DEBUG : test-1drive: config out: out=&{State:*all-set,12,false Option: OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:26 DEBUG : test-1drive: config: reading config parameter "tenant"
Option tenant.
ID of the service principal's tenant. Also called its directory ID.
Set this if using
- Client Credential flow
Enter a value. Press Enter to leave empty.
tenant>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all-set,12,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,13,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,13,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,14,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,14,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,15,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,15,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,16,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,16,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,17,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,17,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,18,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,18,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,19,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,19,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,20,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,20,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,21,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,21,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,22,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,22,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,23,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,23,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,24,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,24,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,25,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,25,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,26,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,26,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,27,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,27,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all,28,false Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config in: state="*all,28,false", result=""
2025/04/11 19:08:40 DEBUG : test-1drive: config out: out=&{State:*all-advanced Option:false OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:40 DEBUG : test-1drive: config: reading config parameter "config_fs_advanced"
Edit advanced config?
y) Yes
n) No (default)
y/n>
2025/04/11 19:08:47 DEBUG : test-1drive: config in: state="*all-advanced", result="false"
2025/04/11 19:08:47 DEBUG : test-1drive: config out: out=&{State:*postconfig Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:47 DEBUG : test-1drive: config in: state="*postconfig", result=""
2025/04/11 19:08:47 DEBUG : test-1drive: config in: state="", result=""
2025/04/11 19:08:47 DEBUG : test-1drive: config out: out=&{State:*oauth,choose_type,, Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:47 DEBUG : test-1drive: config out: out=&{State:*oauth,choose_type,, Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:47 DEBUG : test-1drive: config in: state="*oauth,choose_type,,", result=""
2025/04/11 19:08:47 DEBUG : test-1drive: config out: out=&{State:*oauth-confirm,choose_type,, Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:47 DEBUG : test-1drive: config in: state="*oauth-confirm,choose_type,,", result=""
2025/04/11 19:08:47 DEBUG : test-1drive: config out: out=&{State:*oauth-islocal,choose_type,, Option:true OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:47 DEBUG : test-1drive: config: reading config parameter "config_is_local"
Use web browser to automatically authenticate rclone with remote?
* Say Y if the machine running rclone has a web browser you can use
* Say N if running rclone on a (remote) machine without web browser access
If not sure try Y. If Y failed, try N.
y) Yes (default)
n) No
y/n>
2025/04/11 19:08:50 DEBUG : test-1drive: config in: state="*oauth-islocal,choose_type,,", result="true"
2025/04/11 19:08:50 DEBUG : test-1drive: config out: out=&{State:*oauth-do,choose_type,, Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:50 DEBUG : test-1drive: config in: state="*oauth-do,choose_type,,", result=""
2025/04/11 19:08:50 NOTICE: Make sure your Redirect URL is set to "http://localhost:53682/" in your custom config.
2025/04/11 19:08:50 DEBUG : Starting auth server on 127.0.0.1:53682
2025/04/11 19:08:50 NOTICE: If your browser doesn't open automatically go to the following link: http://127.0.0.1:53682/auth?state=9F-JpKskNHq79IeWyOPq4A
2025/04/11 19:08:50 NOTICE: Log in and authorize rclone for access
2025/04/11 19:08:50 NOTICE: Waiting for code...
2025/04/11 19:08:50 DEBUG : Redirecting browser to: https://login.microsoftonline.com/common/oauth2/v2.0/authorize?access_type=offline&client_id=b15665d9-eda6-4092-8539-0eec376afd59&redirect_uri=http%3A%2F%2Flocalhost%3A53682%2F&response_type=code&scope=Files.Read+Files.ReadWrite+Files.Read.All+Files.ReadWrite.All+Sites.Read.All+offline_access&state=9F-JpKskNHq79IeWyOPq4A
2025/04/11 19:08:52 DEBUG : Received GET request on auth server to "/"
2025/04/11 19:08:52 NOTICE: Got code
2025/04/11 19:08:52 DEBUG : Closing auth server
2025/04/11 19:08:52 DEBUG : Closed auth server with error: accept tcp 127.0.0.1:53682: use of closed network connection
2025/04/11 19:08:52 DEBUG : Saving config "token" in section "test-1drive" of the config file
2025/04/11 19:08:52 DEBUG : Keeping previous permissions for config file: -rw--w----
2025/04/11 19:08:52 DEBUG : test-1drive: Saved new token in config file
2025/04/11 19:08:52 DEBUG : test-1drive: config out: out=&{State:*oauth-done,choose_type,, Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:52 DEBUG : test-1drive: config in: state="*oauth-done,choose_type,,", result=""
2025/04/11 19:08:52 DEBUG : test-1drive: config out: out=&{State:choose_type Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:52 DEBUG : test-1drive: config in: state="choose_type", result=""
2025/04/11 19:08:52 DEBUG : test-1drive: config out: out=&{State:choose_type_done Option:onedrive OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:08:52 DEBUG : test-1drive: config: reading config parameter "config_type"
Option config_type.
Type of connection
Choose a number from below, or type in an existing value of type string.
Press Enter for the default (onedrive).
1 / OneDrive Personal or Business
\ (onedrive)
2 / Root Sharepoint site
\ (sharepoint)
/ Sharepoint site name or URL
3 | E.g. mysite or https://contoso.sharepoint.com/sites/mysite
\ (url)
4 / Search for a Sharepoint site
\ (search)
5 / Type in driveID (advanced)
\ (driveid)
6 / Type in SiteID (advanced)
\ (siteid)
/ Sharepoint server-relative path (advanced)
7 | E.g. /teams/hr
\ (path)
config_type> 1
2025/04/11 19:09:08 DEBUG : test-1drive: config in: state="choose_type_done", result="onedrive"
2025/04/11 19:09:08 DEBUG : test-1drive: config out: out=&{State:onedrive Option:<nil> OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:09:08 DEBUG : test-1drive: config in: state="onedrive", result=""
2025/04/11 19:09:09 DEBUG : test-1drive: config out: out=&{State:choose_type Option:<nil> OAuth:<nil> Error:Failed to query available drives: HTTP error 403 (403 Forbidden) returned body: "{\"error\":{\"code\":\"notAllowed\",\"message\":\"You do not have access to create this personal site or you do not have a valid license\",\"innerError\":{\"code\":\"provisioningNotAllowed\",\"date\":\"2025-04-12T02:09:09\",\"request-id\":\"2ac754ca-1164-4642-b8bf-1854b5c7c7f8\",\"client-request-id\":\"2ac754ca-1164-4642-b8bf-1854b5c7c7f8\"}}}" Result:}, err=<nil>
Failed to query available drives: HTTP error 403 (403 Forbidden) returned body: "{\"error\":{\"code\":\"notAllowed\",\"message\":\"You do not have access to create this personal site or you do not have a valid license\",\"innerError\":{\"code\":\"provisioningNotAllowed\",\"date\":\"2025-04-12T02:09:09\",\"request-id\":\"2ac754ca-1164-4642-b8bf-1854b5c7c7f8\",\"client-request-id\":\"2ac754ca-1164-4642-b8bf-1854b5c7c7f8\"}}}"
2025/04/11 19:09:09 DEBUG : test-1drive: config in: state="choose_type", result=""
2025/04/11 19:09:09 DEBUG : test-1drive: config out: out=&{State:choose_type_done Option:onedrive OAuth:<nil> Error: Result:}, err=<nil>
2025/04/11 19:09:09 DEBUG : test-1drive: config: reading config parameter "config_type"
Option config_type.
Type of connection
Choose a number from below, or type in an existing value of type string.
Press Enter for the default (onedrive).
1 / OneDrive Personal or Business
\ (onedrive)
2 / Root Sharepoint site
\ (sharepoint)
/ Sharepoint site name or URL
3 | E.g. mysite or https://contoso.sharepoint.com/sites/mysite
\ (url)
4 / Search for a Sharepoint site
\ (search)
5 / Type in driveID (advanced)
\ (driveid)
6 / Type in SiteID (advanced)
\ (siteid)
/ Sharepoint server-relative path (advanced)
7 | E.g. /teams/hr
\ (path)
config_type> ^C [SIGINT]
Workaround
Run this configure sequence on my Windows 11 box, produced working, mountable config lines. Used current Windows 11 login credentials for the popped-up browser window, "Success!", no errors. Crossed my fingers and manually copied the config section for OneDrive back into the Linux Fedora ~/.config/rclone/rclone.conf. Then the "rclone mount" worked on Linux.