# Getting around pathname length limitations (eg: Onedrive)

**URL:** <https://forum.rclone.org/t/getting-around-pathname-length-limitations-eg-onedrive/17333>\
**Category:** Feature\
**Created:** [June 21, 2020, 4:14am UTC](https://forum.rclone.org/t/getting-around-pathname-length-limitations-eg-onedrive/17333 "2020-06-21T04:14:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bandwidth](https://forum.rclone.org/letter_avatar_proxy/v4/letter/b/bc8723/32.png) [@bandwidth](https://forum.rclone.org/u/bandwidth)\
**Post date:** [June 21, 2020, 4:14am UTC](https://forum.rclone.org/t/getting-around-pathname-length-limitations-eg-onedrive/17333/1 "2020-06-21T04:14:37Z")

</div>

Onedrive for Business limits maximum path (not file) length to 400 chars. When used with the crypt backend, the max length is further reduced to the point where I can't upload a large number of files.

I'm wondering if others have run into this and thought about solutions. One approach would to write a "shortening" backend that would convert back and forth between pathnames and files shortened to say, 8 chars. Like URL shorteners, a database could be maintained, say, in a clear text file stored in the remote's root. The remote would consist solely of a single flat directory with all pathnames shortened to files and stored on the root.

Has this been thought about or discussed? I'd be glad to make a more formal proposal and a contribution a few months down the line if there's interest.

---

<div class="post-metadata">

**Author:** ![ncw](https://forum.rclone.org/user_avatar/forum.rclone.org/ncw/32/18_2.png) [@ncw](https://forum.rclone.org/u/ncw)\
**Post date:** [June 22, 2020, 10:33am UTC](https://forum.rclone.org/t/getting-around-pathname-length-limitations-eg-onedrive/17333/2 "2020-06-22T10:33:58Z")

</div>

There have been quite a few discussions of this kind of thing in the issues - the discussions are a bit disorganized so it will need a bit of searching!

This could potentially be part of the crypt backend itself as a new filename encryption mode. Managing files with metadata in separate from the files themselves gets quite tricky quite quickly though.

---

<div class="post-metadata">

**Author:** ![system](https://forum.rclone.org/uploads/default/original/2X/3/39ad3235f6ffec76ccd0c81616bd55697b4c300d.png) [@system](https://forum.rclone.org/u/system)\
**Post date:** [August 22, 2020, 6:33am UTC](https://forum.rclone.org/t/getting-around-pathname-length-limitations-eg-onedrive/17333/3 "2020-08-22T06:33:59Z")

</div>

Closed on August 22, 2020, 6:33am UTC

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
