You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
after a recent Jira Software upgrade from 9.6 to 9.10, users on my Jira instance are unable to upload attachments containing special characters like č, ř, š.
When they try to upload such an attachment, they see the following message:
"File "ÁBCD.DOC" was not uploaded
Could not save attachment to storage: Malformed input or input contains unmappable characters: ÁBCD.DOC"
What could be the reason for this? I already tried searching around and found that one of the solutions is to change the starting parameters to look like -
JVM_SUPPORT_RECOMMENDED_ARGS="-Datlasssian.plugins.enable.wait=300 -Dfile.encoding=utf-8 -Dsun.jnu.encoding=UTF-8"
However I found that newer versions of Java ignore these parameters. What can be done about this?
What error is exactly showing in the logs when uploading the problematic attachment? Is this same behavior no matter which browser? Did you tried upload it via REST API?
I am wondering if there any situation that would allow to upload it.
Are you using any reverse proxy etc? (e.g Apache)
So this is an example of the error message.
SEVERE [http-nio-8080-exec-5] com.sun.jersey.spi.container.ContainerResponse.logException Mapped exception to response: 500 (Internal Server Error)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.base/java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$ResponseOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java :205)
And a huge stack trace following after that.
This has been occuring to multiple users, so it is likely that they have different browsers, too. No, I didn't use REST API, just the regular drag and drop method.
I do use Nginx, although the URIEncoding=UTF-8 is set correctly in server.xml.
Ok, before we think that this is a encoding problem and how to apply UTF-8 to every layer lets try to put few things together and try to look from a little different perspective.
If you recently upgraded then something definitively change in a way how requests are handled from client to server. Would be good first to check if JIRA in Safe Mode if working fine. I mean would be great to eliminate that some of the addon might be causing this.
If we are able to reproduce the problem even if addons are not working (just clean JIRA) then we have to take a look on network layer..
That is also wy I suggested not using UI and browser and try to upload "problematic" attachment using REST API. It would be helpful to know if different method works.
You mentioned that Nginx is used so would be since to bypass it for a moment and check how application behave if we directly access JIRA (without proxy). If we would still have problem that it must be a problem in a application itself or operating system / database.
Then we can only focus on this layer and verify if everything is properly set.
Thanks for the advice. Putting Jira into safe mode didn't change anything, unfortunately.
Adding the attachment via postman does the same; I get this error in the terminal: