{"id":25284327,"url":"https://github.com/elastos/elastos.hive.demo.fuseapp","last_synced_at":"2025-04-06T14:35:56.783Z","repository":{"id":96720954,"uuid":"173712120","full_name":"elastos/Elastos.Hive.Demo.FuseApp","owner":"elastos","description":null,"archived":false,"fork":false,"pushed_at":"2019-03-17T14:02:07.000Z","size":21,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":28,"default_branch":"master","last_synced_at":"2025-02-12T20:39:06.684Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/elastos.png","metadata":{"files":{"readme":"README.md","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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-03-04T09:15:24.000Z","updated_at":"2021-11-12T03:21:39.000Z","dependencies_parsed_at":null,"dependency_job_id":"b5b0aa7e-04e3-4168-8c48-d3c02ff2d75b","html_url":"https://github.com/elastos/Elastos.Hive.Demo.FuseApp","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/elastos%2FElastos.Hive.Demo.FuseApp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastos%2FElastos.Hive.Demo.FuseApp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastos%2FElastos.Hive.Demo.FuseApp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastos%2FElastos.Hive.Demo.FuseApp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elastos","download_url":"https://codeload.github.com/elastos/Elastos.Hive.Demo.FuseApp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247496584,"owners_count":20948261,"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":"2025-02-12T20:38:02.810Z","updated_at":"2025-04-06T14:35:56.777Z","avatar_url":"https://github.com/elastos.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# hivefs - Demo fuse client for Elastos Hive Cluster\n\n[![img](https://camo.githubusercontent.com/9ff0f4b787066b705774659143d8b88f485119ff/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6d61646525323062792d456c6173746f732532306f72672d626c75652e7376673f7374796c653d666c61742d737175617265)](http://elastos.org)\n[![img](https://camo.githubusercontent.com/85d19725dcd92c6f77a1d72a2e9b2b49c36489ab/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f70726f6a6563742d486976652d626c75652e7376673f7374796c653d666c61742d737175617265)](http://elastos.org/)\n[![standard-readme compliant](https://camo.githubusercontent.com/a7e665f337914171fa0b60a110690af78fc5d943/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7374616e646172642d2d726561646d652d4f4b2d677265656e2e7376673f7374796c653d666c61742d737175617265)](https://github.com/RichardLitt/standard-readme)\n[![Build Status](https://camo.githubusercontent.com/d95d2cf5f0f2c8ebf5697026daaa4cbfaab6521e/68747470733a2f2f7472617669732d63692e6f72672f656c6173746f732f456c6173746f732e4e45542e486976652e495046532e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/elastos/Elastos.NET.Hive.Cluster)\n\n## Introduction\n\nIn a nutshell:\n**hivefs** implements a fuse client for hive cluster.\n\n**hivefs** is a fuse client that allows users to connect hive cluster servers using typical POSIX API.\n\nfor instance:\n* You can use it to mount hive.cluster as a local disk driver or directory.\n* You can read/write on the mounted like as on local file system.\n\n### Background\n- [FUSE](https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/Documentation/filesystems/fuse.txt)\n(Filesystem In Userpace) is a Linux kernel filesystem that sends the\nincoming requests over a file descriptor to userspace. Historically,\nthese have been served with a\n[C library of the same name](http://fuse.sourceforge.net/), but\nultimately FUSE is just a protocol. Since then, the protocol has been\nimplemented for other platforms such as OS X, FreeBSD and OpenBSD.\n\n- hivefs is fuse app/client, it uses the library [bazil.org/fuse](http://bazil.org/fuse), which is a reimplementation of that\nprotocol in pure Go.\n\n## Pre-Requirements\n\nIn order to run this app, FUSE installation is needed.\n\nUbuntu Linux:\n```sh\nsudo apt-get update\nsudo apt-get install fuse\n```\n\nmacOS:  \nPlease download the installer package from:\n[https://github.com/osxfuse/osxfuse/releases](https://github.com/osxfuse/osxfuse/releases)\n\n## Compiling\nhivefs is written in Go, so here’s how to get going:\n```sh\ngit clone https://github.com/elastos/Elastos.NET.Hive.Demo.FuseApp.git  $GOPATH/src/github.com/elastos/Elastos.NET.Hive.Demo.FuseApp\n\ncd $GOPATH/src/github.com/elastos/Elastos.NET.Hive.Demo.FuseApp\ngo get\nmake\n```\n## Usage\n\n**hivefs** is a command line program that need to run in background. The usage is below:\n\n```sh\n./hivefs -host \u003chost\u003e -port \u003cport number\u003e -uid \u003cuid\u003e MOUNTPOINT\n```\n- host - hive cluster address. The default value is 127.0.0.1.\n- port - hive cluster port. The default value is 9095.\n- uid - uid string. The default value is generated by \"uid/new\" http API. \n- MOUNTPOINT - mount target directory.\n\nFor example:\n```sh\n./hivefs -host 127.0.0.1 -port 9095 -uid uid-ee978fa7-18b6-43d4-9f3e-3e6562131036 /mnt\n```\n\nWhile the hivefs daemon is running, please open a new terminal window and go to the mounted directory for your testing.\n\nIf you want to run hivefs in the background even after you close the terminal, then you can use *nohup* to run it. For example:\n```sh\nnohup ./hivefs -host 127.0.0.1 -port 9095 -uid uid-ee978fa7-18b6-43d4-9f3e-3e6562131036 /mnt \u0026\n```\n\n\n## Troubleshooting\n\n\n#### Mount errors\n\nAt first, make sure the mount target directory has been created and you have the write permission.\n\nDuring starting the daemon, you may see mount errors below.\n\nIn Linux:\n```\nmount helper error: fusermount: failed to access mountpoint /mnt: Transport endpoint is not connected\n```\nIn macOS:\n```\nmount helper error: mount_osxfuse: mount point /mnt is itself on a OSXFUSE volume\n```\nPlease use the command *mount* to check whether the mount point is being used. If used, then umount it or choose another mount point.\n\nIf you ran hivefs before but didn't unload it with the *umount* command, then the previous mount point is still used by the system although hivefs is not running. Please umount it manually before using hivefs again.\n\n#### Umount errors\n\nPlease use *umount* to unload hivefs if you don't use it. If you directly quit the hivefs daemon, the mount point will not be released automatically, and you may not mount it again with the same mount point.\n\nThese are errors for unsuccessful umount operations.\n\nIn Linux:\n```sh\n$ umount /mnt\numount: /mnt: target is busy.\n```\nIn macOS:\n```sh\n$ umount /mnt\numount(/mnt): Resource busy -- try 'diskutil unmount'\n```\n\nPlease do the following steps to solve this problem:\n* Check whether one of the shell stays at the directory inside the mount point. Maybe your running shells have been left the mount point, but other people still use it.\n* Check whether somes files or directories are opened by some applications.\nIt's recommended to use *lsof* to see which users and which processes still open files or directories inside hivefs volume.\n\n#### Access errors\n\nSometimes you can't access the mounted directory even the hivefs daemon runs corrrectly. You may see the below errors. \n\nIn Linux:\n```sh\n$ cd /mnt\nbash: cd: /mnt: Permission denied\n$ ls /mnt\nls: cannot access '/mnt': Permission denied\n```\nIn macOS:\n```sh\n$ cd /mnt\ncd: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory\n$ ls /mnt\nls: /mnt: No such file or directory\n```\nProbably it's related to the access right. Make sure the current user has the permission to access the mounted path. For example, if hivefs is running with *root* user, other users are difficult to access the corresponding directories. If possible, don't use *root* to run hivefs.\n\n\n## Contribution\n\nWe welcome contributions to the Elastos Hive Project.\n\n## Acknowledgments\n\nA sincere thank you to all teams and projects that we rely on directly or indirectly.\n\n## License\nThis project is licensed under the terms of the [MIT license](https://github.com/elastos/Elastos.Hive.Demo.FuseApp/blob/master/LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felastos%2Felastos.hive.demo.fuseapp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felastos%2Felastos.hive.demo.fuseapp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felastos%2Felastos.hive.demo.fuseapp/lists"}