Summary:
Add new fields to EdenConfig to control log rotation settings, and update
edenfs_monitor to set up the log rotation strategy using these settings.
Reviewed By: chadaustin
Differential Revision: D20427271
fbshipit-source-id: 9960bdb6f4d077a4e21fb4a6209aa02ab21ad653
Summary:
Update the LogFile class in edenfs_monitor to support log rotation when the
file size exceeds a set limit.
There is a generic API to abstract out the log rotation details. For now
I have only implemented a relatively straightforward implementation that
appends the current timestamp to the log path, and prunes old log files.
Reviewed By: chadaustin
Differential Revision: D20427310
fbshipit-source-id: f6aefc8f2fe604fdd1d6a72c3d30666612912f41
Summary:
Move the `UserInfo` code from `fuse/privhelper` to `utils`, and also unify the
POSIX and Windows implementations of this class.
This code was originally put in the `fuse/privhelper` directory since it was
written at the same time as the privhelper. However, it's really a
lower-level library that doesn't depend on FUSE or any of the other code in
the `fuse/` subdirectory.
Reviewed By: wez
Differential Revision: D21296594
fbshipit-source-id: f58682f6ce86bba0328472c491bb4c0dc3370319
Summary:
Update the EdenFS monitor to restart itself when it receives SIGHUP. This
allows upgrading the monitor daemon to a new version of the software without
disrupting the current running EdenFS daemon.
Reviewed By: wez
Differential Revision: D19588698
fbshipit-source-id: f0303788cee0cc9bf4ce3b7342f10a595c3874b1
Summary:
Update the SpawnedEdenInstance class to wait for EdenFS to become healthy
before signalling the Future returned by `start()`.
This code works by just polling the `getStatus()` call every few hundred
milliseconds, and waiting until it returns `ALIVE`.
Currently the code will poll forever, until EdenFS either becomes healthy or
exits. In practice we will likely configure startup timeouts in systemd,
which means that they probably are not necessary in this code.
Reviewed By: wez
Differential Revision: D19588699
fbshipit-source-id: fef57ca23fcc14da908c2e4f7f715db33b7bf841
Summary:
Add a simple new wrapper daemon to manage the edenfs daemon. This is intended
to provide a few different features:
- Perform log rotation for EdenFS's output and the output of any of its
spawned children processes.
- Help schedule restarts of EdenFS when the system looks idle.
- Provide a single process for the system to manage across graceful EdenFS
restarts, to make management slightly simpler.
This initial commit does not perform graceful restarts yet, but has the basic
daemon management and log rotation present.
Reviewed By: wez
Differential Revision: D19588700
fbshipit-source-id: bba41c9f7efeb4417753c1d48dd72cf6d191f0c3