imthenachoman / unraid-templates

NordLynx Docker template for unRAID
MIT License
3 stars 1 forks source link

Error 500 while creating a new mount #2

Open RodriMora opened 2 years ago

RodriMora commented 2 years ago

I have created a new path to have access but I still have the error while mounting

image

image

Paradox8 commented 2 years ago

I'm getting this error prior to mounting, I'm actually getting it whilst creating a Google Drive remote. Occurs on the 2nd screen whilst creating the config, all I have entered is the Google Application Client ID and OAuth Secret.

I currently have this exact same remote configured on Windows without issue.

Error 500 is something to do with FUSE I do believe.

imthenachoman commented 2 years ago

I am checking. I wasn't able to create a config either. Interesting.

imthenachoman commented 2 years ago

The error 500 is something else here. It is supposed to open a new window when creating the config but it didn't. I am digging.

RodriMora commented 2 years ago

For the config I created a random one and copied from another rsync.conf file into the container's one

maxgill commented 2 years ago

It try to open a tab on a localhost address. I tried to map the port (53682) and access it manually but it not working. Probably need to allows access from other IP instead of only localhost.

Here the log: NOTICE: If your browser doesn't open automatically go to the following link: http://127.0.0.1:53682/auth?state=xxxxxx 2022/03/20 09:43:48 NOTICE: Log in and authorize rclone for access 2022/03/20 09:43:48 NOTICE: Waiting for code...

imthenachoman commented 2 years ago

@maxgill You access the GUI from your unRAID server's IP.

maxgill commented 2 years ago

Yes, I know but when you try to create new config, it will try to open a new tab / window to 127.0.0.1 on port 53682 instead of the unRAID ip with port 5572. Rclone will wait for the user to continue to the new tab that does not appear and it will hang. If you try to do a new config again, you will get a error 500 with this in the log:

2022/03/20 15:13:36 ERROR : rc: "config/update": error: config failed to refresh token: failed to start auth webserver: listen tcp 127.0.0.1:53682: bind: address already in use

that may be the solution: https://rclone.org/remote_setup/

But I might also be in the left field...

SirShaw commented 2 years ago

also having the same issue. My log output is:

2022/03/20 18:38:22 mount helper error: fusermount: fuse device not found, try 'modprobe fuse' first 2022/03/20 18:38:22 mount FAILED: fusermount: exit status 1 2022/03/20 18:38:22 ERROR : rc: "mount/mount": error: fusermount: exit status 1

chansearrington commented 2 years ago

I'm having the same problem

DuzAwe commented 2 years ago

Same issue here. its trying to open a login prompt window but it cant as its mapped to inside a docker.

2022/04/04 12:51:08 NOTICE: Config file "/config/rclone/rclone.conf" not found - using defaults
2022/04/04 12:56:37 NOTICE: If your browser doesn't open automatically go to the following link: http://127.0.0.1:53682/auth?state=DJRxXHSjRjyKQ4SbDOnTCw
graschbaten commented 2 years ago

I have created a new path to have access but I still have the error while mounting

image

image

hi, do you solved that issue?

most of these posts has nothing to do with this issue :D

gabcraftia commented 2 years ago

i can add myself to the list of people with this problem. Having searched all over google the only useful thing i could find is that i need to install fuse? What is fuse? and how do i install it or do i already have it installed but isn't working. I am out of idea's the only thing i want to do is just backup my 4 tb nas to google cloud!

graschbaten commented 2 years ago

Do it the old way in the console. rclone mount Google: mnt/user/download/Google.

gabcraftia commented 2 years ago

@graschbaten when i try that i get a fuse error. /data # rclone mount Googledrive: /mnt/Google 2022/07/05 15:13:10 mount helper error: fusermount: fuse device not found, try 'modprobe fuse' first 2022/07/05 15:13:10 Fatal error: failed to mount FUSE fs: fusermount: exit status 1 /data #

idk what the problem is now. can't use apt install to try and install it. because that is non existent in this docker apparently.

/data # apt install fuse sh: apt: not found /data #

I am at the end of my knowledge now.

SailorMaya commented 2 years ago

The only way I got this to work was to add --device /dev/fuse to Extra Parameters and run the container with elevated privilege's.

gabcraftia commented 2 years ago

That is it. Thanks! Now I need to find out how I can acces it from other PC's on my network.

AnonStoormTrooper commented 2 years ago

I have created a new path to have access but I still have the error while mounting

image

image

Any news, this with the problem of error 500 when mounting? Everything else satisfactory with the web GUI

PracticalChip commented 2 years ago

Bump, I have the same issue as above.

imthenachoman commented 2 years ago

This is a bug/issue with rclone. I don't know how to fix. I need rclone team to help me debug but they aren't responding. :/

https://github.com/rclone/rclone-webui-react/issues/145

pedromdav commented 2 years ago

@imthenachoman I'm having a similar issue. I've managed to create a Dropbox config via the console but when trying to mount I get the error mentioned by other users

mount helper error: fusermount: fuse device not found, try 'modprobe fuse' first

I've tried the fix mentioned by @SailorMaya

The only way I got this to work was to add --device /dev/fuse to Extra Parameters and run the container with elevated privilege's.

but when running the mount command it just hangs there forever. Any clues on what can cause this or how it can be fixed?

mavec1999 commented 2 years ago

Just adding myself to the list here. Understand it's an issue with rclone itself; looking forward to the fix. Thanks!

drpoutine commented 1 year ago

also having the same issue. My log output is:

2022/03/20 18:38:22 mount helper error: fusermount: fuse device not found, try 'modprobe fuse' first 2022/03/20 18:38:22 mount FAILED: fusermount: exit status 1 2022/03/20 18:38:22 ERROR : rc: "mount/mount": error: fusermount: exit status 1

the fix for this is the use the post argument of --cap-add SYS_ADMIN --device /dev/fuse --security-opt apparmor:unconfined to allow access to the fuse driver.

Screenshot 2022-10-13 at 10 44 19 AM

For making the mount show outside the container. the mode must be set to Read/Write - Shared inside the webui you set the AllowNonEmpty setting to YES and it should just work. once you mount it the folder will populate on the other end inside the unraid file browser

shedman214 commented 1 year ago

--cap-add SYS_ADMIN --device /dev/fuse --security-opt apparmor:unconfined

where do I put the code. I tried putting it here but it would not start after? is there a specific way to add the command? image

lbouriez commented 1 year ago

Same issue here. its trying to open a login prompt window but it cant as its mapped to inside a docker.

2022/04/04 12:51:08 NOTICE: Config file "/config/rclone/rclone.conf" not found - using defaults
2022/04/04 12:56:37 NOTICE: If your browser doesn't open automatically go to the following link: http://127.0.0.1:53682/auth?state=DJRxXHSjRjyKQ4SbDOnTCw

Did you find a solution ? I get the same issue and have no idea how to solve it

TheManchineel commented 1 year ago

@lbouriez IDK if you still need this, but did you toggle the AllowNonEmpty option on in the Rclone WebGUI?

lbouriez commented 1 year ago

Ho thanks, i kind of stopped trying, if i have the time to jump back to this subject i will give it a try.

misterjtc commented 11 months ago

Has there been any progress on this? This kind of makes this container useless if you cannot mount the actual drives you configure?

There should be notes on this in CA since this container doesn't really do what its supposed to. I wasted a lot of time trying to get this to work...

imthenachoman commented 11 months ago

It's an issue with rclone. The container works fine for browsing. You just can't create. I spoke to rclone devs but I don't know if they have a plan to fix. :/

misterjtc commented 11 months ago

I appreciate your work obviously, however that is not the function of rclone and makes this container not able to provide the function that its supposed to... I would request that you put a note in CA or something to let people know that its broken.... OR remove it from CA until a fix is found. This is just causing pain, suffering and wasted time...

imthenachoman commented 11 months ago

I'm confused. What is not the function of rclone? rclone has a cool web GUI. While this container doesn't let you create a config, it does still let you browse using the rclone GUI.

And good poitn on the note. I need to see how to do that.

misterjtc commented 11 months ago

Well I assume that the majority of people using this are trying to mount cloud storage on their unraid server for backups, etc, which this container cannot do...

I was able to get the config setup using the rclone/remote/headless documentation but I cannot mount any of these cloud drives on my server...

imthenachoman commented 11 months ago

Ah. I didn't think about that. I created the container with the web UI in mind. I only wanted a way to browse my mounts using the rclone UI.

misterjtc commented 11 months ago

So, @imthenachoman I read your issue on the rclone github page and I was trying to do the same thing. Fortunately I had a raspberry pi running rclone (non-containerized) which I used to generate the required access key (or whatever its called). I'll put the link below incase it might help anyone.

https://rclone.org/remote_setup/

I also wanted to say that you worked pretty hard to try to get them to help you, too bad it fizzled out... Thank you for your efforts regardless.

However it shoudl also be noted that this is for creating an rclone config for google drive and not how to mount it to the host operating machine (which I think this issue is actually about)

misterjtc commented 11 months ago

Additionally, I have gdrive mounted and I have a volume mounted to the container from my unraid server. However when I run the mount command I am getting the below errors in the terminal.

/data/gdrive # rclone mount --max-read-ahead 1024k --allow-other gdrive: /data/gdrive 2023/08/31 20:40:10 mount helper error: fusermount3: fuse device not found, try 'modprobe fuse' first 2023/08/31 20:40:10 Fatal error: failed to mount FUSE fs: fusermount: exit status 1

This makes me think that fuse and libfuse are not installed in the container. Is it possible to have these added!?

imthenachoman commented 11 months ago

I also wanted to say that you worked pretty hard to try to get them to help you, too bad it fizzled out... Thank you for your efforts regardless.

Yeah. When I have time I still poke through the code to see if I can figure it out but I don't know Go so it's a slow burn.

However it shoudl also be noted that this is for creating an rclone config for google drive and not how to mount it to the host operating machine (which I think this issue is actually about

You raise a good point. There are two issues: creating a config, and mounting a config.

This makes me think that fuse and libfuse are not installed in the container. Is it possible to have these added!?

So I didn't actually make a container. I just created an unRAID template for using the official rclone container. I think the only way we can fix these issues is to either create our own container, or I'm wondering if there is some Docker paramater that can be used to tell the host what to do. I think the later is what is needed.

The other issue is my unRAID box died and I won't be able to replace it for a bit. I will see if I can figure something out without needing the unRAID box.

imthenachoman commented 11 months ago

I'm thinking that somehow the container has to have access to the host's fuse library to create mounts on the host.

misterjtc commented 11 months ago

So I was wrong. I actually got everything to work, by reading the DOCUMENTATION. Who would have thunk it....

Here is what i would recommend:

  1. In the rclone documentation, they reference this thread if you want to use rclone mount with containers.

    • https://github.com/moby/moby/issues/9448#issuecomment-65529399
    • Based on this, I needed to add --cap-add SYS_ADMIN --device /dev/fuse to the docker run command which unraid templates refer to as "Extra Parameters".
    • Exerpt from rclone docs at https://rclone.org/install/: "It is possible to use rclone mount inside a userspace Docker container, and expose the resulting fuse mount to the host. The exact docker run options to do that might vary slightly between hosts. See, e.g. the discussion in this thread."
    • Therefore, I recommend we add these as extra parameters as defaults to the template.
  2. In the rclone documentation, they recommend to mount your host system at /data.

    • Therefore I recommend we update the template to add a default volume mount at /data.
    • I used /mnt/disks/cloud_provider based on spaceinvaderone's recommendation in his video here https://www.youtube.com/watch?v=-b9Ow2iX2DQ

Voila. Everything now works and I can mount my cloud storage to my unraid system.

500 error goes away while doing the above which is what the original issue referred to and also why I stumbled upon it.

jamescochran commented 11 months ago

For anyone doing this it is important that the new Path you make is set to Read/Write - Shared. Don't wast hours on it like me.

misterjtc commented 11 months ago

For anyone doing this it is important that the new Path you make is set to Read/Write - Shared. Don't wast hours on it like me.

Damn man, I forgot the put that in my last comment. I am sorry... Thank you for bringing this up.

I also spent an unfortunate amount of time trying to get this to work. When I get some time I will try and submit a pull request to have the template updated.

@imthenachoman do you have any opposition to implementing the changes in my post and @jamescochran's ?

imthenachoman commented 11 months ago

Folks, it looks like it'll be a while before I can make updates cause my unRAID box is DoA and I won't be able to fix it for a while. If anyone wants to take over the add-ons, I'm more than happy to hand it over.

misterjtc commented 11 months ago

Folks, it looks like it'll be a while before I can make updates cause my unRAID box is DoA and I won't be able to fix it for a while. If anyone wants to take over the add-ons, I'm more than happy to hand it over.

When I have some time i'll try and submit and pull request with the updates. I forgot that you mentioned that your unraid box is down.

latel commented 5 months ago

Quick conclusion(from a guy wasted hours):

Ohopwood commented 1 week ago

I get this Error when trying to mount a sub Folder from the remote path