{"id":13560740,"url":"https://github.com/28msec/gridfs-fuse","last_synced_at":"2025-04-03T16:31:03.004Z","repository":{"id":16298033,"uuid":"19046729","full_name":"28msec/gridfs-fuse","owner":"28msec","description":null,"archived":false,"fork":false,"pushed_at":"2015-08-26T11:36:20.000Z","size":967,"stargazers_count":26,"open_issues_count":8,"forks_count":4,"subscribers_count":13,"default_branch":"master","last_synced_at":"2024-11-04T12:39:58.323Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/28msec.png","metadata":{"files":{"readme":"README.txt","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-04-22T21:25:01.000Z","updated_at":"2024-05-24T18:54:12.000Z","dependencies_parsed_at":"2022-09-14T22:03:49.417Z","dependency_job_id":null,"html_url":"https://github.com/28msec/gridfs-fuse","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/28msec%2Fgridfs-fuse","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/28msec%2Fgridfs-fuse/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/28msec%2Fgridfs-fuse/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/28msec%2Fgridfs-fuse/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/28msec","download_url":"https://codeload.github.com/28msec/gridfs-fuse/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247036939,"owners_count":20873054,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T13:00:49.106Z","updated_at":"2025-04-03T16:31:02.483Z","avatar_url":"https://github.com/28msec.png","language":"C++","funding_links":[],"categories":["C++"],"sub_categories":[],"readme":"--------------------------------------------------------------\nGridFS Fuse - A FUSE filesystem for MongoDB's GridFS\n--------------------------------------------------------------\n\nGridFS Fuse is a user-based filesystem based on a FUSE that is based on\nMongoDB's GridFS. Specifically, it allows to mount a MongoDB GridFS\ndatabase enabling filesystem like reads and writes for files stored\nin MongoDB.\n\nIt currently supports files, directories, and symbolic links but not\nall system call are available. For example, get-, set-, and listxattr\nare not implementd.\n\nIn order to provide good performance, the module uses memcached for\ncaching file attributes such that not every getattr call results in\na read in MongoDB.\n\nBuild \u0026 Installation\n--------------------\n\nIn order to build the filesystem module, the following dependencies\nneed to be met:\n- CMake \u003e= 2.6\n- libfuse-dev\n- libmemcached-dev\n- MongoDB Driver \u003e= 2.6.1\n- boost system \u003e= 1.49\n\nTo build the module, you need to configure a build directory using\nCMake and use make to do the actual build.\n\nTo build a Debian package you can call\n\n- cmake -P ppa/PPAGridFS.cmake in your build directory or\n- debuild -S in the ppa/ppaingGridFS/gridfs-0.8.0 directory (version might be different)\n\n\nUsage\n-----\n\nThe module is available in the form of a command-line client. You can get\nits help using: ./bin/gridfs  -h\n\nFor example, to mount a MongoDB gridfs database named foobar into the local directory foobar, you\ncould use\n\n./bin/gridfs foobar -o mongo_db=fuse -f\n\nThe -f option keeps the process running in the foreground\n\nSome MongoDB related options are:\n\n-o mongo_conn_string=STRING        connection string (e.g. \"replica-set/host:port\\,host:port\"; default: localhost:27017)\n-o mongo_user=STRING               user name for mongo db authentication\n-o mongo_password=STRING           password for mongo db authentication\n-o mongo_collection_prefix=STRING  prefix for the gridfs collections (default: fs)\n\n\nTesting\n-------\n\nOnce you have successfully built the module, you can run a simple test using ctest.\nThe output could as follows:\n\nTest project /home/vagrant/sausalito/gridfs/build\n    Start 1: gridfs-fuse-simple\n1/2 Test #1: gridfs-fuse-simple ...............   Passed    6.73 sec\n    Start 2: gridfs-fuse-parallel\n2/2 Test #2: gridfs-fuse-parallel .............   Passed    4.56 sec\n\n100% tests passed, 0 tests failed out of 2\n\nTotal Test time (real) =  11.30 sec\n\n\nGeneral Documentation\n---------------------\n\n  Source Code\n  -----------\n  The most important file is src/filesystem_operations.cpp. It contains the implementation\n  of all the fuse functions (e.g. getattr or readdir). Mostly, those functions dispatch\n  the work to any of the subclasses of FilesystemEntry (e.g. File, Directory, or Symlink).\n  Those subclasses take care of the communication with MongoDB.\n\n  The Fuse class in include/gridfs_fuse.h (implementation in src/gridfs_fuse.cpp) is the\n  main class that configures fuse and syslog as well as creating connection pools for\n  communicating with MongoDB and Memcached.\n\n  Memcached Administration\n  ------------------------\n  A special component of each mounted filesystem is the proc filesystem. It works similar\n  to the Linux proc filesystem and can currently be used to introspect or add available\n  Memcached nodes.\n\n  For example,\n\n  ls foobar/proc/instances\n    may be used to show all of the memcached nodes that are used as a cache for filesystem\n    attributes. They are returned as \"server-or-ip:port\".\n\n  Currently, localhost:11211 is always used as a default memcached server.\n\n  A new memcached node can be added by simply touching a file with the name and port of\n  the new server. For instance,\n\n  touch foobar/proc/instances/192.168.1.50:11211\n    would add the memcached server running at 192.168.1.50:11211 to the cluster.\n\n  The implementation responsible for adding new nodes is located in the Proc::create\n  function (see src/proc.cpp).\n\n  Memcached nodes are automatically removed if nodes become unavailable during runtime.\n\n  In the future, other features might be added to the proc filesystem.\n  \n\n  Memcached Attributes\n  --------------------\n  As already mentioned, Memcached is used as a distributed cache for storing filesystem\n  attributes. The key for each entry in the cache always starts with \"a:\" to indicate\n  that it's a filesystem _a_ttribute. The value of each entry is the binary representation\n  of the stat struct defined by FUSE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F28msec%2Fgridfs-fuse","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F28msec%2Fgridfs-fuse","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F28msec%2Fgridfs-fuse/lists"}