Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Setup: Tomcat is misconfigured

I'm getting this error when starting Jira that Tomcat is misconfigured and that the server.xml file is missing parameters needed by Jira to handle requests that contain special characters.

It pops us a message that includes the following URL on how to troubleshoot the issue: https://confluence.atlassian.com/jirakb/changing-server-xml-to-handle-requests-with-special-characters-958453799.html

 

I'm supposed to follow these steps to fix the issue:

Solution

  1. Go to <Jira-installation-directory>/conf, and edit the server.xml file.
  2. Find all connectors your application is using. Just search for Connector in the file, or look at the example below. You're interested only in connectors whose protocol is set to HTTP and HTTPS (not AJP).
  3. Add relaxedPathChars="[]|" relaxedQueryChars="[]|{}^&#x5c;&#x60;&quot;&lt;&gt;" to the connector properties in server.xml. For example:

    <Connector port="8080" relaxedPathChars="[]|" rela

I used the config.bat to change the settings to use only https and this is how my connector looks like:

<Connector SSLEnabled="true" acceptCount="100" clientAuth="false" connectionTimeout="20000" disableUploadTimeout="true" enableLookups="false" keyAlias="te-50a7704f-9b69-4627-b12a-0c2c87a6c70f" keystoreFile="C:\Program Files\Java\jre1.8.0_221\lib\security\cacerts" keystorePass="changeit" keystoreType="JKS" maxHttpHeaderSize="8192" maxSpareThreads="75" maxThreads="150" minSpareThreads="25" port="8443" protocol="org.apache.coyote.http11.Http11NioProtocol" scheme="https" secure="true" sslProtocol="TLS" relaxedPathChars="[]|" relaxedQueryChars="[]|{}^&#x5c;&#x60;&quot;&lt;&gt;" useBodyEncodingForURI="true"/></Service>

 

What am I missing?

2 answers

1 accepted

3 votes
Answer accepted

We got it to work using the following connector:

<Connector SSLEnabled="true" acceptCount="100" clientAuth="false" connectionTimeout="20000" disableUploadTimeout="true" enableLookups="false" keyAlias="te-50a7704f-9b69-4627-b12a-0c2c87a6c70f" keystoreFile="C:\Program Files\Java\jre1.8.0_221\lib\security\cacerts" keystorePass="changeit" keystoreType="JKS" maxHttpHeaderSize="8192" maxSpareThreads="75" maxThreads="150" minSpareThreads="25" port="8443" protocol="org.apache.coyote.http11.Http11NioProtocol" scheme="https" secure="true" sslProtocol="TLS" useBodyEncodingForURI="true" relaxedPathChars="[]|" relaxedQueryChars="[]|{}^&#x5c;&#x60;&quot;&lt;&gt;"/>

Muhammad Ramzan Community Leader Sep 20, 2020

Thank you , you saved my life :) 

Like # people like this

This helped, thank you.

Further, if you have configured SSL (with redirect), you'll need to locate both (or all) connector tags in config.xml and ensure that they have these attributes:

relaxedPathChars="[]|" relaxedQueryChars="[]|{}^&#x5c;&#x60;&quot;&lt;&gt;" 

 I reiterate this because I found one of the two tucked waaay at the end of the file.

0 votes

I suspect it's the characters in the relaxedQueryChars string - try shortening it to just "|" to start with, then adding the others back in one or two at a time to work out which ones fail.  My Tomcat fails on the {} pair, as it's reading that as a non-existent variable (but I don't see this too often as I don't like punctuation in urls and usually actively disable it)

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Jira

⏰ Day in the life of a Jira Admin!

Hello Community! We thoroughly enjoyed this just-for-fun conversation in the Jira Admin Group about what it's like to be a Jira Admin. For #JiraJuly, our talented designers created these graphics t...

909 views 2 22
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you