No one able to login to confluence server!

Princely Benedict August 16, 2018

Hi there,

Thanks in advance. We have one Jira server and Confluence 6.6 server on different Ubuntu box. As well we use Mysql database on defferent Ubuntu box. Now now one cannot log in to confluence server. need some help.

2018-08-16 14_38_51-Log In - AMF Confluence.png

14 answers

0 votes
Princely Benedict August 17, 2018

Here is the setenv.sh, do not understand why when i add to recovery admin, i coud not log in


# Set the JVM arguments used to start Confluence. For a description of the options, see
# http://www.oracle.com/technetwork/java/javase/tech/vmoptions-jsp-140102.html
CATALINA_OPTS="-XX:-PrintGCDetails -XX:+PrintGCDateStamps -XX:-PrintTenuringDistribution ${CATALINA_OPTS}"
CATALINA_OPTS="-Xloggc:$LOGBASEABS/logs/gc-`date +%F_%H-%M-%S`.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=2M ${CATALINA_OPTS}"
CATALINA_OPTS="-XX:G1ReservePercent=20 ${CATALINA_OPTS}"
CATALINA_OPTS="-Djava.awt.headless=true ${CATALINA_OPTS}"
CATALINA_OPTS="-Datlassian.plugins.enable.wait=300 ${CATALINA_OPTS}"
CATALINA_OPTS="-Xms1024m -Xmx1024m -XX:+UseG1GC ${CATALINA_OPTS}"
CATALINA_OPTS="-Dsynchrony.enable.xhr.fallback=true ${CATALINA_OPTS}"
CATALINA_OPTS="-Dorg.apache.tomcat.websocket.DEFAULT_BUFFER_SIZE=32768 ${CATALINA_OPTS}"
CATALINA_OPTS="${START_CONFLUENCE_JAVA_OPTS} ${CATALINA_OPTS}"
CATALINA_OPTS="-Dconfluence.context.path=${CONFLUENCE_CONTEXT_PATH} ${CATALINA_OPTS}"

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 17, 2018

In case you want to directly modify the Jira URL in the database, I was able to achieve it with this query:

UPDATE cwd_directory_attribute
SET attribute_value = 'Your_Jira_Base_URL'
WHERE attribute_name = 'crowd.server.url'

However, unless you know you changed the Jira URL it may be worth considering other circumstances which could have impacted the connection, such as changes on the network. (note: The Jira attribute is called crowd.server.url because Crowd and Jira User directories are stored the same way in that table.)

Do please back up the database before running any queries against it.

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 17, 2018

I agree that Confluence is likely not talking to Jira.

The recovery process bypasses the Jira connection and uses a user directory local to Confluence.

The Jira URL is not in a configuration file, it is stored in the database. The safest way to change it is through the UI.

Please attach the catalina opts from your setenv.sh with the recovery property included so I can check it with a second pair of eyes

Please check what error is in the log when the login fails:
<confluence_home>/logs/atlassian-confluence.log

Thanks,

Ann

0 votes
Princely Benedict August 17, 2018

Thanks Ann,

I tried start the service manually. No luck. Password is correct, Tried different users and password. Did not work.

I think the confluence server is not talking to Jira server. I you assist me where is the configuration parameter on confluence server which is point to jira server to authenticate. I mean which file in confluence then it will fix the problem.

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 16, 2018

The only thing I can think of off the top of my head is maybe you restarted Confluence as a service?

  1. Start Confluence manually using  <installation-directory>/bin/start-confluence.sh or start-confluence.bat (don't start Confluence as a service).

I notice you are getting a bad password error now instead of the "Sorry an error occurred..." So also please double check the password.

0 votes
Princely Benedict August 16, 2018

I have tried the recovery_admin login: i got the same login error

2018-08-16 16_27_46-Log In - AMF Confluence.png

0 votes
Princely Benedict August 16, 2018

Hi there,

I have set the temp admin access like this before the export CATALINA_OPTS in setenv.sh

CATALINA_OPTS="-Datlassian.recovery.password=temppassword"

 

here is the my setenv.sh. don't know what i am doing wrong?

cd $LOGBASE
cd $LOGTAIL
LOGBASEABS=`pwd`
cd $PUSHED_DIR

echo ""
echo "Server startup logs are located in $LOGBASEABS/logs/catalina.out"
# IMPORTANT NOTE: Only set JAVA_HOME or JRE_HOME above this line
# Get standard Java environment variables
if $os400; then
  # -r will Only work on the os400 if the files are:
  # 1. owned by the user
  # 2. owned by the PRIMARY group of the user
  # this will not work if the user belongs in secondary groups
  . "$CATALINA_HOME"/bin/setjre.sh
else
  if [ -r "$CATALINA_HOME"/bin/setjre.sh ]; then
    . "$CATALINA_HOME"/bin/setjre.sh
  else
    echo "Cannot find $CATALINA_HOME/bin/setjre.sh"
    echo "This file is needed to run this program"
    exit 1
  fi
fi

echo "---------------------------------------------------------------------------"
echo "Using Java: $JRE_HOME/bin/java"
CONFLUENCE_CONTEXT_PATH=`$JRE_HOME/bin/java -jar $CATALINA_HOME/bin/confluence-context-path-extractor.jar $CATALINA_HOME`
export CONFLUENCE_CONTEXT_PATH
$JRE_HOME/bin/java -jar $CATALINA_HOME/bin/synchrony-proxy-watchdog.jar $CATALINA_HOME
echo "---------------------------------------------------------------------------"

# Set the JVM arguments used to start Confluence. For a description of the options, see
# http://www.oracle.com/technetwork/java/javase/tech/vmoptions-jsp-140102.html
CATALINA_OPTS="-XX:-PrintGCDetails -XX:+PrintGCDateStamps -XX:-PrintTenuringDistribution ${CATALINA_OPTS}"
CATALINA_OPTS="-Xloggc:$LOGBASEABS/logs/gc-`date +%F_%H-%M-%S`.log -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=2M ${CATALINA_OPTS}"
CATALINA_OPTS="-XX:G1ReservePercent=20 ${CATALINA_OPTS}"
CATALINA_OPTS="-Djava.awt.headless=true ${CATALINA_OPTS}"
CATALINA_OPTS="-Datlassian.plugins.enable.wait=300 ${CATALINA_OPTS}"
CATALINA_OPTS="-Xms1024m -Xmx1024m -XX:+UseG1GC ${CATALINA_OPTS}"
CATALINA_OPTS="-Dsynchrony.enable.xhr.fallback=true ${CATALINA_OPTS}"
CATALINA_OPTS="-Dorg.apache.tomcat.websocket.DEFAULT_BUFFER_SIZE=32768 ${CATALINA_OPTS}"
CATALINA_OPTS="${START_CONFLUENCE_JAVA_OPTS} ${CATALINA_OPTS}"
CATALINA_OPTS="-Dconfluence.context.path=${CONFLUENCE_CONTEXT_PATH} ${CATALINA_OPTS}"


export CATALINA_OPTS

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 16, 2018

Please consult the atlassian-confluence.log for better insights.

The atlassian-synchrony log is concerned with collaborative editing.

0 votes
Princely Benedict August 16, 2018

Thanks again, I have tried the temp admin password recovery, but it did not work.

I am suspecting that confluence server looking for it self as remote address from this log. Need to know where to change the remote IP on confluence server.

root@confluence:/var/atlassian/application-data/confluence/logs# tail atlassian-synchrony.log
2018-08-16 15:36:41,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:37:11,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:37:41,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:38:11,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:38:41,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:39:11,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:39:41,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:40:11,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:40:41,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 15:41:11,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
root@confluence:/var/atlassian/application-data/confluence/logs# cd /opt/atlassian/confluence/bin

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 16, 2018

The URL Confluence uses to reach Jira for user management is stored in the database rather than the file system.

To update the configuration:

  1. Follow this article to regain access to the Confluence instance: Restore Passwords To Recover Admin User Rights
  2. Go to Confluence Admin>User Directories and edit the Jira User directory
  3. Update the Jira URL, save changes.

Test logging in via an account managed by Jira.

0 votes
Princely Benedict August 16, 2018

Thanks again,

Our confluence and jira servers are on separate ubuntu boxes. which file on confluence server contain the configuration to the remote jira authentication.

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 16, 2018

Please look for entries in the atlassian-confluence.log as the atlassian-synchrony.log pertains to collaborative editing and not authentication.

The catalina.out logs Tomcat webserver events.

The most likely cause of the login issue is a URL change in JIra or Confluence, or network connectivity loss between the applications.

0 votes
Princely Benedict August 16, 2018

Thanks for quick replay,

Yes Jira server manage users for confluence.

here is the log.

root@confluence:/var/atlassian/application-data/confluence/logs# tail atlassian-synchrony.log
2018-08-16 14:53:11,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:53:41,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:54:11,973 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:54:41,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:55:11,975 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:55:41,974 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:56:11,973 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:56:41,973 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:57:11,976 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}
2018-08-16 14:57:41,973 DEBUG [130:StdOutHandler [/opt/atlassian/confluence/jre/bin/java]] {"synchrony":{"request":{"remote-addr":"127.0.0.1","uri":"/synchrony/heartbeat","request-method":"get","query-string":null},"response":{"status":200},"ns":"synchrony.middleware.logging","level":"info","message":"synchrony.middleware.logging [info] null"}}

 

here is the catalina.out

root@confluence:/opt/atlassian/confluence/logs# tail catalina.out
16-Aug-2018 14:32:31.889 INFO [http-nio-8090-exec-3] com.sun.jersey.server.impl.application.WebApplicationImpl._initiate Initiating Jersey application, version 'Jersey: 1.8-atlassian-16 03/23/2015 10:20 PM'
16-Aug-2018 14:32:39.313 INFO [http-nio-8090-exec-6] com.sun.jersey.server.impl.application.WebApplicationImpl._initiate Initiating Jersey application, version 'Jersey: 1.8-atlassian-16 03/23/2015 10:20 PM'
16-Aug-2018 14:32:39.333 INFO [http-nio-8090-exec-9] com.sun.jersey.server.impl.application.WebApplicationImpl._initiate Initiating Jersey application, version 'Jersey: 1.8-atlassian-16 03/23/2015 10:20 PM'
16-Aug-2018 14:32:39.487 INFO [http-nio-8090-exec-4] com.sun.jersey.server.impl.application.WebApplicationImpl._initiate Initiating Jersey application, version 'Jersey: 1.8-atlassian-16 03/23/2015 10:20 PM'
16-Aug-2018 14:32:41.581 INFO [http-nio-8090-exec-2] com.sun.jersey.server.impl.application.WebApplicationImpl._initiate Initiating Jersey application, version 'Jersey: 1.8-atlassian-16 03/23/2015 10:20 PM'
16-Aug-2018 14:32:41.610 INFO [http-nio-8090-exec-2] com.sun.jersey.api.wadl.config.WadlGeneratorLoader.loadWadlGenerator Loading wadlGenerator com.sun.jersey.server.wadl.generators.WadlGeneratorApplicationDoc
16-Aug-2018 14:32:41.611 INFO [http-nio-8090-exec-2] com.sun.jersey.api.wadl.config.WadlGeneratorLoader.loadWadlGenerator Loading wadlGenerator com.sun.jersey.server.wadl.generators.WadlGeneratorGrammarsSupport
16-Aug-2018 14:32:41.611 INFO [http-nio-8090-exec-2] com.sun.jersey.api.wadl.config.WadlGeneratorLoader.loadWadlGenerator Loading wadlGenerator com.atlassian.plugins.rest.doclet.generators.resourcedoc.AtlassianWadlGeneratorResourceDocSupport
16-Aug-2018 14:51:31.109 INFO [http-nio-8090-exec-4] com.sun.jersey.server.impl.application.WebApplicationImpl._initiate Initiating Jersey application, version 'Jersey: 1.8-atlassian-16 03/23/2015 10:20 PM'
16-Aug-2018 14:51:34.735 INFO [http-nio-8090-exec-10] com.sun.jersey.server.impl.application.WebApplicationImpl._initiate Initiating Jersey application, version 'Jersey: 1.8-atlassian-16 03/23/2015 10:20 PM'

 

here is the confluence-init.properties

root@confluence:/opt/atlassian/confluence/confluence/WEB-INF/classes# cat confluence-init.properties
# This file allows you to set the directory for Confluence to store its configuration files.
#
###########################
# Note for Windows Users  #
###########################
#
# Each backslash in your path must be written as a forward slash.
# - For example:
# c:\confluence\data
#
# should be written as:
#
# c:/confluence/data

###########################
# Note for Unix Users     #
###########################
# - For example:
# confluence.home=/var/confluence
#
# NOTE: If the path of your confluence.home directory contains symlinks,
# please set confluence.home to the absolute path, otherwise problems may occur.
# - For example:
# confluence.home=/data/confluence/ (where /data is a symlink to -> /var/data/)
# should be written as:
# confluence.home=/var/data/confluence/

###########################
# Configuration Directory #
###########################

# specify your directory below (don't forget to remove the '#' in front)

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 16, 2018

Hi Princely,

Do you know if Jira has been set up to manage users for Confluence? If so, an inability to reach Jira from Confluence could prevent logging into Confluence.

Your other post linked an article related to Crowd, was that in error?

To learn more about why users cannot log into Confluence, please check the log at:
<confluence_home>/logs/atlassian-confluence.log
Note: The <confluence_home> directory is the path defined in the following file: <confluence_install>/confluence/WEB-INF/classes/confluence-init.properties

Please search for the user name that was used to test the login, and pay attention to entries that start with ERROR. I look forward to hearing what the logs reveal.

Thanks,

Ann

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events