rclone/rclone

rclone mount: do not present files when in an errored state

Open

#1,307 创建于 2017年4月3日

在 GitHub 查看
 (5 评论) (1 反应) (0 负责人)Go (57,185 star) (5,090 fork)batch import
enhancementhelp wantedthinking

描述

I'm guessing the behavior is due to caching of files and their metadata but from what users have told me: should a service start returning errors (such as due to data transfer quota exhausted) then the files will continue to shown (readdir + stat) but open's and read's will fail.

MergerFS is following certain policies in order to select which file to open. If the file selected happens to be on the "broken" mount then the user will get that error. If however rclone decided to no longer present the files then mergerfs would pick the file which is still available to it. In effect a "failover".

Under a typical harddrive failure (at least in my experience) the drive will still be mounted but files won't be shown. This allows mergerfs to appear OK even though an underlying drive may have failed. (Say you have files mirrored across two or more drives.) I'm working to make mergerfs look at other drives should a certain command fail on the primary one selected but it may be easier to have rclone present failure states differently to the user. I don't know what the APIs from the services provide but perhaps a quota limit could result in rclone dropping all indication of files/dirs until the service is available again?

贡献者指南