[tor-bugs] #31937 [Core Tor/Tor]: decide and document that stuff in the CacheDirectory can be deleted while Tor is running
Tor Bug Tracker & Wiki
blackhole at torproject.org
Wed Oct 2 20:51:03 UTC 2019
#31937: decide and document that stuff in the CacheDirectory can be deleted while
Tor is running
------------------------------+--------------------
Reporter: arma | Owner: (none)
Type: enhancement | Status: new
Priority: Medium | Milestone:
Component: Core Tor/Tor | Version:
Severity: Normal | Keywords:
Actual Points: | Parent ID:
Points: | Reviewer:
Sponsor: |
------------------------------+--------------------
As of #24272 and #22703 we have a separate CacheDirectory that Tor can use
to put transient things like cached directory info.
_hc asked just now if it's ok to put the CacheDirectory, for Tor on
Android, in a place where it might get blown away periodically.
On #24272 I see an example value being "/var/cache/".
And on https://refspecs.linuxfoundation.org/FHS_3.0/fhs/ch05s05.html it
says that for /var/cache/, "The application must always be able to recover
from manual deletion of these files (generally because of a disk space
shortage)."
So I think the answer is yes, we should support having the files in
CacheDirectory disappear out from under us.
So:
* Step zero is to decide that this is what we want.
* Step one is to learn whether Tor breaks currently in this situation.
Like, we mmap some of those files. If they get deleted, does everything go
smoothly? (For some Linux filesystems, the file can be deleted but Tor
will still hold its copy in existence until it gives up the file
descriptor, which would seem helpful in this situation. But I bet not all
OSes and FSes work that way.)
* And step two would be to change the man page to say what we do or don't
promise here.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/31937>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list