All Projects → pleiszenburg → loggedfs-python

pleiszenburg / loggedfs-python

Licence: Apache-2.0 license
Filesystem monitoring with Fuse and Python

Programming Languages

python
139335 projects - #7 most used programming language
Makefile
30231 projects
shell
77523 projects

Projects that are alternatives of or similar to loggedfs-python

Goofys
a high-performance, POSIX-ish Amazon S3 file system written in Go
Stars: ✭ 3,932 (+18623.81%)
Mutual labels:  fuse, filesystem, fuse-filesystem
Catfs
Cache AnyThing filesystem written in Rust
Stars: ✭ 404 (+1823.81%)
Mutual labels:  fuse, filesystem, fuse-filesystem
fuse xattrs
add xattrs support using sidecar files.
Stars: ✭ 28 (+33.33%)
Mutual labels:  fuse, filesystem, fuse-filesystem
Supertag
A tag-based filesystem
Stars: ✭ 207 (+885.71%)
Mutual labels:  fuse, filesystem, fuse-filesystem
Fuse Ts
Stars: ✭ 6 (-71.43%)
Mutual labels:  fuse, filesystem, fuse-filesystem
Securefs
Filesystem in userspace (FUSE) with transparent authenticated encryption
Stars: ✭ 518 (+2366.67%)
Mutual labels:  fuse, filesystem, fuse-filesystem
GitFS
A FUSE filesystem that stores data on Git
Stars: ✭ 26 (+23.81%)
Mutual labels:  fuse, filesystem, fuse-filesystem
Cryfs
Cryptographic filesystem for the cloud
Stars: ✭ 1,560 (+7328.57%)
Mutual labels:  fuse, filesystem, fuse-filesystem
Distribyted
📂 ➡️ 📺 🎶 🎮 Torrent client with on-demand file downloading as a filesystem.
Stars: ✭ 791 (+3666.67%)
Mutual labels:  fuse, filesystem, fuse-filesystem
S3fs Fuse
FUSE-based file system backed by Amazon S3
Stars: ✭ 5,733 (+27200%)
Mutual labels:  fuse, filesystem, fuse-filesystem
Fusell Seed
FUSE (the low-level interface) file system boilerplate 📂 🔌 💾
Stars: ✭ 9 (-57.14%)
Mutual labels:  fuse, filesystem, fuse-filesystem
fusell-seed
FUSE (the low-level interface) file system boilerplate 📂 🔌 💾
Stars: ✭ 13 (-38.1%)
Mutual labels:  fuse, filesystem, fuse-filesystem
Gcsf
a FUSE file system based on Google Drive
Stars: ✭ 2,251 (+10619.05%)
Mutual labels:  fuse, filesystem
Gotenksfs
A file system on top of your file system
Stars: ✭ 203 (+866.67%)
Mutual labels:  fuse, filesystem
Sparsebundlefs
FUSE filesystem for reading macOS sparse-bundle disk images
Stars: ✭ 238 (+1033.33%)
Mutual labels:  fuse, filesystem
Phoenixfs
🔥 a versioning filesystem inspired by git
Stars: ✭ 191 (+809.52%)
Mutual labels:  fuse, filesystem
Tifs
A distributed POSIX filesystem based on TiKV, with partition tolerance and strict consistency.
Stars: ✭ 209 (+895.24%)
Mutual labels:  fuse, filesystem
Ninfs
FUSE filesystem Python scripts for Nintendo console files
Stars: ✭ 241 (+1047.62%)
Mutual labels:  fuse, fuse-filesystem
UserFileSystemSamples
IT Hit User File System Engine samples in .NET/C#. Samples implement Virtual File System for Windows and Mac with synchronization support, on-demand loading, offline files, and Windows File Manager integration.
Stars: ✭ 60 (+185.71%)
Mutual labels:  fuse, fuse-filesystem
Containerfs
a cluster filesystem for containers
Stars: ✭ 264 (+1157.14%)
Mutual labels:  fuse, filesystem

Build Status: master / release Build Status: development branch Project License: Apache License v2 Project Development Status Available on PyPi - the Python Package Index Available on PyPi - the Python Package Index

LoggedFS-python repository

Synopsis

LoggedFS-python is a FUSE-based filesystem which can log every operation that happens in it. It is a pure Python re-implementation of LoggedFS by Rémi Flament maintaining CLI compatibility. The project is heavily inspired by Stavros Korokithakis' 2013 blog post entitled "Writing a FUSE filesystem in Python" (source code repository). The filesystem is fully POSIX compliant, passing the pjdfstest test-suite, a descendant of FreeBSD's fstest. It furthermore passes stress tests with fsx-linux based on the fsx-flavor released by the Linux Test Project. It is intended to be suitable for production systems.

CAVEATS

  • PROJECT STATUS: BETA
  • THE FILESYSTEM IS CURRENTLY ONLY BEING DEVELOPED FOR AND TESTED ON LINUX. ANYONE INTERESTED IN CONFIRMING MAC OS X AND/OR ADDING BSD SUPPORT?

Installation

From the Python Package Index (PyPI):

pip install loggedfs

From GitHub:

pip install git+https://github.com/pleiszenburg/loggedfs-python.git@master

Supports Python 3.{5,6,7,8}.

Supports Linux. Support for MAC OS X and BSD is implemented but has yet not been tested.

Simple usage example

To start recording access to /tmp/TEST into /root/log.txt, just do:

sudo loggedfs -p -s -l /root/log.txt /tmp/TEST

To stop recording, just unmount as usual:

sudo fusermount -u /tmp/TEST

CLI usage

loggedfs --help
Usage: loggedfs [OPTIONS] DIRECTORY

Options:
  -f                            Do not start as a daemon. Write logs to stdout
                                if no log file is specified.

  -p                            Allow every user to see the new loggedfs.
  -c FILENAME                   Use the "config-file" to filter what you want
                                to log.

  -s                            Deactivate logging to syslog.
  -l FILE                       Use the "log-file" to write logs to.
  -j, --json                    Format output as JSON instead of traditional
                                loggedfs format.

  -b, --buffers                 Include read/write-buffers (compressed,
                                BASE64) in log.

  -m, --only-modify-operations  Exclude logging of all operations that can not
                                cause changes in the filesystem. Convenience
                                flag for accelerated logging.

  --help                        Show this message and exit.

Configuration

LoggedFS-python can use an XML configuration file if you want it to log operations only for certain files, for certain users, or for certain operations. LoggedFS-python is fully compatible with configuration files in LoggedFS' original format. Yet it can also handle additional fields (e.g. the command field).

Here is a sample configuration file :

<?xml version="1.0" encoding="UTF-8"?>

<loggedFS logEnabled="true" printProcessName="true">
        <includes>
                <include extension=".*" uid="*" action=".*" retname=".*" command=".*"/>
        </includes>
        <excludes>
                <exclude extension=".*\.bak$" uid="*" action=".*" retname="SUCCESS" command=".*"/>
                <exclude extension=".*" uid="1000" action=".*" retname="FAILURE" command=".*"/>
                <exclude extension=".*" uid="*" action="getattr" retname=".*" command=".*"/>
        </excludes>
</loggedFS>

This configuration can be used to log everything except if it concerns a *.bak file, or if the uid is 1000, or if the operation is getattr.

Need help?

Feel free to post questions in the GitHub issue tracker of this project.

Bugs & issues

Please report bugs in LoggedFS-python here in its GitHub issue tracker.

Miscellaneous

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].