google-drive-ocamlfuse icon indicating copy to clipboard operation
google-drive-ocamlfuse copied to clipboard

insufficientFilePermissions","message":"The user does not have sufficient permissions for this file."

Open flagellatedcucumber opened this issue 3 years ago • 1 comments

A file in Google Drive is owned by user A. User B is an editor of the file.

User A uses Google Backup & Sync on Windows 10. User B runs google-drive-ocamlfuse in Linux Mint 20 Cinnamon.

User B can open the file in its related app (Google Earth as it turns out) and can read it fine. But when user B edits the file, then attempts to save the file, the save fails.

In debug mode, google-drive-ocamlfuse reports in its log:

[858.725819] TID=9538: getattr /PUB [858.725940] TID=9538: BEGIN: Getting metadata from context [858.725979] TID=9538: END: Getting metadata: Valid [858.726009] TID=9538: BEGIN: Loading resource /PUB (trashed=false) from db [858.726180] TID=9538: END: Loading resource /PUB (trashed=false) from db: Found (id=12, state=Synchronized) [858.726553] TID=9539: getattr /PUB/AAA BBB GOC Shared library [858.726621] TID=9539: BEGIN: Getting metadata from context [858.726644] TID=9539: END: Getting metadata: Valid [858.726662] TID=9539: BEGIN: Loading resource /PUB/AAA BBB GOC Shared library (trashed=false) from db [858.726695] TID=9539: END: Loading resource /PUB/AAA BBB GOC Shared library (trashed=false) from db: Found (id=44, state=Synchronized) [858.727090] TID=9540: getattr /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz [858.727159] TID=9540: BEGIN: Getting metadata from context [858.727181] TID=9540: END: Getting metadata: Valid [858.727199] TID=9540: BEGIN: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db [858.727290] TID=9540: END: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db: Found (id=597, state=Synchronized) [858.727685] TID=9541: fopen /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz O_WRONLY,O_APPEND [858.727756] TID=9541: BEGIN: Getting metadata from context [858.727779] TID=9541: END: Getting metadata: Valid [858.727797] TID=9541: BEGIN: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db [858.727876] TID=9541: END: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db: Found (id=597, state=Synchronized) [858.728288] TID=9542: flush /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz 0 [858.728374] TID=9542: BEGIN: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db [858.728459] TID=9542: END: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db: Found (id=597, state=Synchronized) [858.728834] TID=9543: release /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz O_WRONLY,O_APPEND [858.728896] TID=9543: BEGIN: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db [858.728980] TID=9543: END: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db: Found (id=597, state=Synchronized) [858.766116] TID=9544: unlink /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz [858.766148] TID=9544: BEGIN: Getting metadata from context [858.766155] TID=9544: END: Getting metadata: Valid [858.766161] TID=9544: BEGIN: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db [858.766207] TID=9544: END: Loading resource /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz (trashed=false) from db: Found (id=597, state=Synchronized) [858.766230] TID=9544: BEGIN: Trashing file (remote id=1wK3NAu3liaKXSgL7MX8a5IrwKX4OU4IF) [859.171996] TID=9544: Service error: {"error":{"errors":[{"domain":"global","reason":"insufficientFilePermissions","message":"The user does not have sufficient permissions for this file."}],"code":403,"message":"The user does not have sufficient permissions for this file."}}. [859.174685] TID=9544: Permission denied: unlink /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz [881.416144] TID=2: Flushing DB...done

What's happening here? What is the next test?

flagellatedcucumber avatar May 03 '21 12:05 flagellatedcucumber

[859.174685] TID=9544: Permission denied: unlink /PUB/AAA BBB GOC Shared library/wkp- Great Offley Preston Kings Walden (o AAA 202105031236).kmz

Something is trying to delete (unlink) that file and the Drive API reports that the operation is not permetted.

astrada avatar May 03 '21 15:05 astrada