Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Limiting Dropbox cache size [closed]

I am having an issue with the Dropbox cache, whereby periodically I find that a particular machine I am syncing to with Dropbox has run out of disk space and the Dropbox cache is the culprit. This is a problem because the machine Dropbox is installed on is headless (or nearly so) and therefore the only indication that something is wrong is suddenly data that should be available on the machine isn't.

I have read that it is possible to clear the cache, but this is a pain as this machine is running OS X and there is no command line interface, meaning that I have to VNC into the machine simply to restart Dropbox. This also seems to limit my options for automatically clearing the cache, although having to create a periodic task to clean the Dropbox folder seems kludgy and error prone. (For instance, the disk could fill up before the script runs.)

(Update: It appears that deleting the files in a low disk condition results in Dropbox starting to sync again without restarting, but I am not sure if there are any undesirable side-effects to this, everywhere I have read about the cache says to stop Dropbox during the delete and restart it afterwards.)

In addition, it appears that the reason Dropbox is running out of space so fast is that I have a single large log file (on the order of half a gigabyte) which is append-only, but Dropbox is creating a new cached copy of the entire old version every time a change is made. So from the standpoint of performance, it is kinda undesirable that it keep creating duplicates of this large file for every tiny addition of a few bytes to the file.

Disk space is rather tight on this machine, so I would rather simply have Dropbox limit how much caching it does. Is there some way to do this? My searches so far have turned up empty.

Update: I tried opening a Dropbox support request, only to get an e-mail reply stating: "Thanks for writing in. While we'd love to answer every question we get, we unfortunately can't respond to your inquiry due to a large volume of support requests." ಠ_ಠ

like image 621
Michael Avatar asked Jun 01 '26 17:06

Michael


1 Answers

I just have a command file that I run now and then on my MacBook Air to clear space, which contains also these lines:

rm -rf /Users/MYUSERNAME/Dropbox/".dropbox.cache"/old_files/{*,.*}

osascript -e 'tell application "Terminal" to quit' & exit

Should be easy enough to automate, no?

like image 53
Per Christian Frankplads Avatar answered Jun 04 '26 13:06

Per Christian Frankplads



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!