-
Notifications
You must be signed in to change notification settings - Fork 10.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upload is not working #4432
Comments
@geekgonecrazy Was this resolved in the #ubuntu-snap channel or is this still ongoing? |
Ongoing. Couple other reports in non snap installs. Trying to get to the bottom of it still |
I am experimenting the same problem using the latest #ubuntu-snap |
@rodripf experimenting or experiencing ? For former, thank you :) and for the latter, kudos for validating my case 👍 |
I am on snap 0.41 and I am experiencing this too. |
I’m experiencing this issue too. Here are some details about the behaviour on my side: I’m also running the latest snap. Avatar images and file uploads are both set to GridFS. In both cases, I get an empty file after upload (just like OP) and no warning or error message. However, both file upload and avatar images work if I start the server directly in Node JS (without running it through Snap), e.g. like this:
So the issue seems very snap specific. I noted that for me, uploading files only doesn’t work for image files (e.g. pdf is okay). Furthermore, Avatar images work if I disable resizing them. Does Rocket.Chat try to resize uploaded images? (Or run them through If the issue is really because of To summarize, the situation on my server is like this:
|
@jGleitz It looks like it uses $SNAP/usr/bin/convert. vim stable/snapcraft.yaml
|
Good hint. But if it’s using its own binary, then why is there a difference between running inside the snap and “outside”? I thought Rocket.Chat would use gm because that’s mentioned in this bug:
Is that outdated info? |
Both imagemagick and graphicsmagick provide the convert command. Rocket.Chat works with either one of them. We install imagemagick and include it in the snap. Snaps are a isolated environment. Its packaged up with all of its dependencies. Also its restricted on which files and folders it can access. It can just access any file or folder it wishes. They are tightly controlled by the snap platform. This is one of the big benefits to using snaps. So it appears for some reason its trying to use a file or folder it doesn't have access to on file upload. |
I can confirm @jGleitz's findings. Exact same symptoms for me. |
In the latest snap it should be fixed. We used to work with imagemagick or graphicsmagick. Something changed and if using imagemagick it seems to screw things up. So Graphicsmagick is required. |
And so it is. Thanks for your efforts. |
I encountered that exact same issue. Can't it be due to file system access restriction inherent to snaps? |
@maxlath if you have it setup to point to a filesystem path. Then yes absolutely. What path do you have specified? |
@geekgonecrazy I let the path field unaltered |
@maxlath could you grab the value and paste it here? Its possible this value got messed up and maybe something we need to address. |
Step to reproduce:
|
@maxlath what is the value of the filesystem path? Snaps are only allowed to write to certain places. So this is an important piece to verify |
@geekgonecrazy the |
That's the value. It should be something like: |
yep, it works when setting the path to |
@maxlath I'll take a look at prepopulating the setting 👍 |
I have the same issue :( using the latest ubuntu lts, rocketchat version and snap version
|
@rrepolona it looks like from that you are trying to set the path to /var/rocketchat. Snaps are isolated environments with restricted access to the filesystem for security. That folder is not accessible by the snap |
i see, actually had the transition from the manual installation to snap (by restoring mongo db to parties) currently running it like this (as mention by @jGleitz )
but i will check this, and remove the setting. ill give you feedback. thanks |
I am still getting this error, with the latest build of RocketChat, this isnt a snap but a manual install. Any help?
|
@oliver-bowman you are using multiple instances right? If so please follow #6926 |
@maxlath Perfect!!!!!!! |
-- Logs begin at Mon 2019-04-01 21:08:19 UTC. -- |
worked for me with "FileSystem" storage type in admin interface. (Ubuntu 18.04, Snap latest version) |
Hey @Meloman-zz, thanks for the help but I am using rocket chat with docker now. Could you please help me with the same in docker? as my primary disk is full & I am adding a new one for media storage. |
Worked for me with "FileSystem" storage type in admin interface. (Ubuntu 22.04, Snap latest stable version 5.0.2) |
We are on latest snap package and 🚀 chat is at
Version: 0.40.1
Here's the background:
It was working previously in 0.38 version. It stopped working after the upgrade of a snap package. Actually, I was fiddling with settings on AVATAR upload path and I remember setting to FILESYSTEM with /opt/avatar and I broke it. Since server itself was not starting up, I had to change things from backend through MongoDB console in rocketchat.settings collection ( reverted to GridFS).
We started experiencing this as well. Symptoms are almost the same but the scenarios are different.
When "upload" settings are tied to "Filesystem", the progress bar would freeze at 100% and nothing happens at all no matter the time. We get following in the log
As for GridFS case, upload shows it worked fine but we get the blank placeholder of zero-byte / an empty file. However, nothing gets vomited in logs in this case.
The text was updated successfully, but these errors were encountered: