EricTheMagician / DriveFS

A google drive fuse filesystem implemented in C++
Mozilla Public License 2.0
63 stars 7 forks source link

Initializing FUSE filesystem fails on non-english google accounts #4

Closed BerriJ closed 6 years ago

BerriJ commented 6 years ago

Hi @All i just build DriveFS for the first time and after realizing that MongoDB isn't running if finally got it to "work" (i guess). Since 30 Minutes the Terminal says "Getting updated list of files and folders" (See screenshot).

Is this normal behaviour? I wonder how long this will take. Furthermore i don't see any files in the Folder where i wanted to mount my DriveFS. I just ran: ./DriveFS /home/jonathan/DFS In my console.

Thanks in advance bildschirmfoto vom 2018-08-15 21-39-47

BerriJ commented 6 years ago

It's done now but still doesn't work. Here is my terminal output:

[jonathan@Jonathans build]$ ./DriveFS /home/jonathan/DFS 2018-08-15 21:56:37,753 [T] [Account.cpp:108] Getting Account 2018-08-15 21:56:37,754 [I] [Account.cpp:121] Access tokens founds 2018-08-15 21:56:37,757 [I] [Account.cpp:54] Previous change tokens founds 2018-08-15 21:56:37,757 [I] [BaseAccount.cpp:158] Refreshing access tokens 2018-08-15 21:56:37,938 [I] [Account.cpp:546] Getting updated list of files and folders 2018-08-15 21:56:37,938 [D] [Account.cpp:547] teamDriveId root and token 2018-08-15 21:56:38,481 [T] [Account.cpp:414] Filling GDrive file information from cache 2018-08-15 21:56:40,018 [T] [Account.cpp:538] idToObject has 54879 items. 2018-08-15 21:56:40,018 [T] [Account.cpp:539] inodeToObject has 54879 items. 2018-08-15 21:56:40,019 [T] [Account.cpp:386] Linking parent and children 2018-08-15 21:56:40,332 [I] [main.cpp:171] Maximum cache disk size is 0.5 GB 2018-08-15 21:56:40,332 [I] [main.cpp:173] Current size of cache is 0 GB fuse: unknown option `noautocache' Done.

EricTheMagician commented 6 years ago

in DriveFS/src/main.cpp, can you edit line 223 to have "noauto_cache" instead of "noautocache", compile and run it again?

BerriJ commented 6 years ago

Still doesn't work. Here is my config file and the terminal output:

text on the line after # is a comment. It won't affect the configuration

mount=/home/jonathan/.mnt/drivefs cache-location=/home/jonathan/.cache/drivefs cache-chunk-size=33554432 #32 MB cache-disk-size=294304 #4TB download-chunks=4 max-concurrent-downloads=24 move-to-download=1 fuse-foreground=1 # Was not set at my first try fuse-allow-other=1 # Was not set at my first try cache-size=2048 # RAM: 2GB

[jonathan@JonathanPC build]$ ./DriveFS -c /home/jonathan/DriveFS/config 2018-08-16 23:20:16,287 [T] [Account.cpp:108] Getting Account 2018-08-16 23:20:16,288 [I] [Account.cpp:121] Access tokens founds 2018-08-16 23:20:16,290 [I] [Account.cpp:54] Previous change tokens founds 2018-08-16 23:20:16,290 [I] [BaseAccount.cpp:158] Refreshing access tokens 2018-08-16 23:20:16,491 [I] [Account.cpp:546] Getting updated list of files and folders 2018-08-16 23:20:16,491 [D] [Account.cpp:547] teamDriveId root and token 2018-08-16 23:20:17,184 [T] [Account.cpp:414] Filling GDrive file information from cache 2018-08-16 23:20:18,878 [T] [Account.cpp:538] idToObject has 55311 items. 2018-08-16 23:20:18,878 [T] [Account.cpp:539] inodeToObject has 55311 items. 2018-08-16 23:20:18,878 [T] [Account.cpp:386] Linking parent and children 2018-08-16 23:20:19,185 [T] [main.cpp:193] will run fuse in foreground 2018-08-16 23:20:19,185 [T] [main.cpp:201] will run fuse with allow_other 2018-08-16 23:20:19,193 [I] [main.cpp:171] Maximum cache disk size is 287.406 GB 2018-08-16 23:20:19,193 [I] [main.cpp:173] Current size of cache is 0 GB fusermount: option allow_other only allowed if 'user_allow_other' is set in /etc/fuse.conf 2018-08-16 23:20:19,202 [E] [main.cpp:271] Unable to mount filesystem: Operation not permitted [jonathan@JonathanPC build]$ sudo ./DriveFS -c /home/jonathan/DriveFS/config [sudo] Passwort für jonathan: 2018-08-16 23:20:53,497 [T] [Account.cpp:108] Getting Account 2018-08-16 23:20:53,497 [I] [Account.cpp:121] Access tokens founds 2018-08-16 23:20:53,499 [I] [Account.cpp:54] Previous change tokens founds 2018-08-16 23:20:53,499 [I] [BaseAccount.cpp:158] Refreshing access tokens 2018-08-16 23:20:53,715 [I] [Account.cpp:546] Getting updated list of files and folders 2018-08-16 23:20:53,715 [D] [Account.cpp:547] teamDriveId root and token 2018-08-16 23:20:54,828 [T] [Account.cpp:414] Filling GDrive file information from cache 2018-08-16 23:20:56,472 [T] [Account.cpp:538] idToObject has 55311 items. 2018-08-16 23:20:56,472 [T] [Account.cpp:539] inodeToObject has 55311 items. 2018-08-16 23:20:56,472 [T] [Account.cpp:386] Linking parent and children 2018-08-16 23:20:56,773 [T] [main.cpp:193] will run fuse in foreground 2018-08-16 23:20:56,773 [T] [main.cpp:201] will run fuse with allow_other fuse: unknown option `noauto_cache' 2018-08-16 23:20:56,773 [I] [main.cpp:171] Maximum cache disk size is 287.406 GB 2018-08-16 23:20:56,774 [I] [main.cpp:173] Current size of cache is 0 GB Done.

I'm on a fresh installed Manjaro with Gnome GUI and kernel 4.14.60-1.

[jonathan@JonathanPC build]$ fusermount -V fusermount version: 2.9.7

Anything else i could provide?

You would save my whole Linux experience if you could get this to work cause i use DFS a lot...

Thanks so much!

EricTheMagician commented 6 years ago

You could just remove line 222 and 223. If you still have issues, you could remove the next few ones as well.

What version of fuse are you using?

BerriJ commented 6 years ago

Unfortunately it still doesn't work. See the Screenshot...

Every ~ 5 Minutes it says "Getting updated list of files[...]". I can see the DriveFS fuse.D Filesystem in the task manager but i can't find it in my file manager :/

I've also tried to delete the line 222-226 but still the same result.

How can i check my fuse version? The output of fusermount -V is fusermount version: 2.9.7.

bildschirmfoto vom 2018-08-17 01-30-58 bildschirmfoto vom 2018-08-17 01-05-07

EricTheMagician commented 6 years ago

Alright for your fuse verison. Not sure why those options aren't working for you.

It looks like it should be working for you. You mounted it in ~/.mnt/drivefs The ".mnt" folder is by default hidden in most file browsers. You should either show hidden files and folders or mount it at a different location.

You can change it in the config file.

BerriJ commented 6 years ago

I tried that, but it had no effect. Maybe it's just a problem on ARCH (Manjaro is ARCH based). Eventually another user could try this on Manjaro / Arch and tell me if it's working.

Anyway thanks for your help. I'll keep an eye on this repo :)

EricTheMagician commented 6 years ago

I am using it on arch daily, and it was working on my laptop when I had it installed with manjaro. Im the command line, can you go to the mounted folder and list it's content?

BerriJ commented 6 years ago

Shure thing.

[jonathan@JonathanPC ~]$ systemctl start mongodb.service [jonathan@JonathanPC ~]$ cd DriveFS [jonathan@JonathanPC DriveFS]$ cd build [jonathan@JonathanPC build]$ sudo /home/jonathan/DriveFS/build/DriveFS -c /home/jonathan/DriveFS/config [sudo] Passwort für jonathan: 2018-08-17 19:14:14,041 [T] [Account.cpp:108] Getting Account 2018-08-17 19:14:14,043 [I] [Account.cpp:121] Access tokens founds 2018-08-17 19:14:14,049 [I] [Account.cpp:54] Previous change tokens founds 2018-08-17 19:14:14,049 [I] [BaseAccount.cpp:158] Refreshing access tokens 2018-08-17 19:14:14,277 [I] [Account.cpp:546] Getting updated list of files and folders 2018-08-17 19:14:14,277 [D] [Account.cpp:547] teamDriveId root and token 2018-08-17 19:14:16,341 [T] [Account.cpp:414] Filling GDrive file information from cache 2018-08-17 19:14:17,939 [T] [Account.cpp:538] idToObject has 55317 items. 2018-08-17 19:14:17,939 [T] [Account.cpp:539] inodeToObject has 55317 items. 2018-08-17 19:14:17,939 [T] [Account.cpp:386] Linking parent and children 2018-08-17 19:14:18,248 [T] [main.cpp:193] will run fuse in foreground 2018-08-17 19:14:18,248 [T] [main.cpp:201] will run fuse with allow_other 2018-08-17 19:14:18,258 [I] [main.cpp:171] Maximum cache disk size is 287.406 GB 2018-08-17 19:14:18,263 [I] [main.cpp:173] Current size of cache is 0 GB 2018-08-17 19:14:18,267 [T] [Filesystem.cpp:978] Initializing fuse filesystem 2018-08-17 19:14:18,270 [F] [easylogging++.cc:2868] CRASH HANDLED; Application has crashed due to [SIGSEGV] signal ======= Backtrace: ========= [1] /home/jonathan/DriveFS/build/DriveFS(+0x7437a) [0x55c184a1f37a] [2] /home/jonathan/DriveFS/build/DriveFS(+0x7455b) [0x55c184a1f55b] [3] /usr/lib/libc.so.6(+0x368f0) [0x7f1a565eb8f0] [4] /home/jonathan/DriveFS/build/DriveFS(+0xe2de6) [0x55c184a8dde6] [5] /home/jonathan/DriveFS/build/DriveFS(+0xdd6f4) [0x55c184a886f4] [6] /usr/lib/libfuse3.so.3(+0x15524) [0x7f1a5989c524] [7] /usr/lib/libfuse3.so.3(+0x16139) [0x7f1a5989d139] [8] /usr/lib/libfuse3.so.3(+0x11bcc) [0x7f1a59898bcc] [9] /usr/lib/libpthread.so.0(+0x7075) [0x7f1a59670075] [10] /usr/lib/libc.so.6(clone+0x3f) [0x7f1a566ad53f]

2018-08-17 19:14:18,270 [W] [easylogging++.cc:2868] Aborting application. Reason: Fatal log at [/home/jonathan/DriveFS/external/easyloggingpp/src/easylogging++.cc:2868] Abgebrochen

This time it crashed directly :/

EricTheMagician commented 6 years ago

Can you try to unmount it first with: fusermount -uz ~/.mnt/drivefs

On Aug 17 2018, at 1:17 pm, Jonathan notifications@github.com wrote:

Shure thing. [jonathan@JonathanPC ~]$ systemctl start mongodb.service [jonathan@JonathanPC ~]$ cd DriveFS [jonathan@JonathanPC DriveFS]$ cd build [jonathan@JonathanPC build]$ sudo /home/jonathan/DriveFS/build/DriveFS -c /home/jonathan/DriveFS/config [sudo] Passwort für jonathan: 2018-08-17 19:14:14,041 [T] [Account.cpp:108] Getting Account 2018-08-17 19:14:14,043 [I] [Account.cpp:121] Access tokens founds 2018-08-17 19:14:14,049 [I] [Account.cpp:54] Previous change tokens founds 2018-08-17 19:14:14,049 [I] [BaseAccount.cpp:158] Refreshing access tokens 2018-08-17 19:14:14,277 [I] [Account.cpp:546] Getting updated list of files and folders 2018-08-17 19:14:14,277 [D] [Account.cpp:547] teamDriveId root and token 2018-08-17 19:14:16,341 [T] [Account.cpp:414] Filling GDrive file information from cache 2018-08-17 19:14:17,939 [T] [Account.cpp:538] idToObject has 55317 items. 2018-08-17 19:14:17,939 [T] [Account.cpp:539] inodeToObject has 55317 items. 2018-08-17 19:14:17,939 [T] [Account.cpp:386] Linking parent and children 2018-08-17 19:14:18,248 [T] [main.cpp:193] will run fuse in foreground 2018-08-17 19:14:18,248 [T] [main.cpp:201] will run fuse with allow_other 2018-08-17 19:14:18,258 [I] [main.cpp:171] Maximum cache disk size is 287.406 GB 2018-08-17 19:14:18,263 [I] [main.cpp:173] Current size of cache is 0 GB 2018-08-17 19:14:18,267 [T] [Filesystem.cpp:978] Initializing fuse filesystem 2018-08-17 19:14:18,270 [F] [easylogging++.cc:2868] CRASH HANDLED; Application has crashed due to [SIGSEGV] signal ======= Backtrace: ========= [1] /home/jonathan/DriveFS/build/DriveFS(+0x7437a) [0x55c184a1f37a] [2] /home/jonathan/DriveFS/build/DriveFS(+0x7455b) [0x55c184a1f55b] [3] /usr/lib/libc.so.6(+0x368f0) [0x7f1a565eb8f0] [4] /home/jonathan/DriveFS/build/DriveFS(+0xe2de6) [0x55c184a8dde6] [5] /home/jonathan/DriveFS/build/DriveFS(+0xdd6f4) [0x55c184a886f4] [6] /usr/lib/libfuse3.so.3(+0x15524) [0x7f1a5989c524] [7] /usr/lib/libfuse3.so.3(+0x16139) [0x7f1a5989d139] [8] /usr/lib/libfuse3.so.3(+0x11bcc) [0x7f1a59898bcc] [9] /usr/lib/libpthread.so.0(+0x7075) [0x7f1a59670075] [10] /usr/lib/libc.so.6(clone+0x3f) [0x7f1a566ad53f]

2018-08-17 19:14:18,270 [W] [easylogging++.cc:2868] Aborting application. Reason: Fatal log at [/home/jonathan/DriveFS/external/easyloggingpp/src/easylogging++.cc:2868] Abgebrochen

This time it crashed directly :/ — You are receiving this because you commented. Reply to this email directly, view it on GitHub (https://github.com/thejinx0r/DriveFS/issues/4#issuecomment-413931949), or mute the thread (https://github.com/notifications/unsubscribe-auth/AATvbF67bPDNGAZB_yuDZNi7vl-LUjKqks5uRvqZgaJpZM4V-smS).

BerriJ commented 6 years ago

Tried this but hasn't changed the output. Also did a reboot and also tried mounting at /home/jonathan/dfs...

Do you think i could try it on a fresh ARCH / Manjaro booted from a USB?

I really don't know where the problem is. I installed Manjaro just yesterday and the first thing i did was building DriveFS...

Well i'll try at first another account that has only 16 gb of files on it. => Same result.

So i think i'll just setup a fresh manjaro. Maybe you could tell me which AUR packages i need for building DriveFS? That would be awesome. Sometimes i search for the instructions but not shure what package to choose exactly.

EricTheMagician commented 6 years ago

If it's possible, you can always send me login credentials to the computer / server and I can have a look. (eric at_symbol ericyen doot com)

You could try it on a fresh install. Though, you shouldn't need anything from AUR. The packages that DriveFS needs and are in AUR, I compile them already with the build script. The standard packages should be the same as the ones for ubuntu.

EricTheMagician commented 6 years ago

The other thing is, maybe don't use "sudo" when running the program. Or maybe try adding the "--fuse-allow-other" flag,

EricTheMagician commented 6 years ago

It's fixed now.

The most straightforward thing you need to do is delete the DriveFS folder, reclone the repo and rebuild. There's nothing you need to modify in the db, it should handle the case for everyone.

Also, it should run faster now for you. I forgot that I compiled your code in debug, but in release, it should be faster, but not sure how much faster. I always run it in debug so that I can catch some errors, if any.