Error while starting fusionauth-app v1.1 post upgrade
preetamchanda opened this issue · 12 comments
INFO: An exception was caught and reported. Message: java.lang.ClassNotFoundException: org.primeframework.jwt.Signer
java.lang.TypeNotPresentException: Type org.primeframework.jwt.Signer not present
I previously did upgrades 1.0.15 -> 1.0.18, was working perfectly alright.
Hi @preetamchanda sorry you're having this issue.
Can you attach a larger portion of the log? I think that exception may be a side effect of an earlier exception.
Did you have any Identity Providers configured prior to upgrading to version 1.1.0
? If so, try running the following following SQL command against the fusionauth
database:
UPDATE identity_providers
SET type = 'ExternalJWT', enabled = TRUE;
Then ensure FusionAuth is stopped, and then restart FusionAuth.
One other possibility, are you running on Windows, or using the zip files to install? If so, can you attach the output of your lib
directory?
fusionauth-app/web/WEB-INF/lib
Thanks @robotdan please find attached the log
FusionAuth-App.log
I will update you with the results post SQL execution
Thanks. Ok, so it doesn't look like it has anything to do with the identity_providers
table.
It seems as though you have an old jar in your classpath. The output of the lib directory should help us with that.
This are the JVM args -
/usr/local/fusionauth/java/current/bin/java -classpath /usr/local/fusionauth/fusionauth-app/apache-tomcat/bin/bootstrap.jar:/usr/local/fusionauth/fusionauth-app/apache-tomcat/bin/tomcat-juli.jar -Dcatalina.base=/usr/local/fusionauth/fusionauth-app/apache-tomcat -Dcatalina.home=/usr/local/fusionauth/fusionauth-app/apache-tomcat -Djava.awt.headless=true -Dfusionauth.http.port=9011 -Dfusionauth.https.port=443 -Dfusionauth.ajp.port=9019 -Dfusionauth.management.port=9010 -Dfusionauth.home.directory=/usr/local/fusionauth/fusionauth-app/apache-tomcat/.. -Dfusionauth.config.directory=/usr/local/fusionauth/fusionauth-app/apache-tomcat/../../config -Dfusionauth.log.directory=/usr/local/fusionauth/fusionauth-app/apache-tomcat/../../logs -Dfusionauth.plugin.directory=/usr/local/fusionauth/fusionauth-app/apache-tomcat/../../plugins -Xms512M -Xmx512M -Djava.awt.headless=true -Djava.security.egd=file:/dev/./urandom -Djava.endorsed.dirs= -Djava.io.tmpdir=/tmp/fusionauth-app -DfusionAuthApp878711B77 -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Djava.util.logging.config.file=/usr/local/fusionauth/fusionauth-app/apache-tomcat/conf/logging.properties org.apache.catalina.startup.Bootstrap start
Do you want me to list the JAVA_HOME/lib? Thanks
Thanks @preetamchanda
I'd actually like to see the list of jars in the fusionauth-app/web/WEB-INF/lib
directory.
Did you install with a debian package or a zip file?
/usr/local/fusionauth/fusionauth-app/web/WEB-INF/lib
FusionAuth-libJar.txt
fusionauth-app_1.1.0-1_all.deb
fusionauth-search_1.1.0-1_all.deb
This is the first time I used .deb, previously used .zip always
Thank you, that is helpful. Ok, as I suspected, you must be installing using the zip files?
It looks like you unzipped on top of the old directory, so it laid all of the new files on top. This means the classpath includes multiple versions of FusionAuth libraries.
fusionauth-api-1.0.15.jar
fusionauth-api-1.1.0.jar
fusionauth-app-1.0.15.jar
fusionauth-app-1.1.0.jar
fusionauth-database-1.0.15.jar
fusionauth-database-1.1.0.jar
fusionauth-java-client-1.0.15.jar
fusionauth-java-client-1.1.0.jar
fusionauth-plugin-api-1.0.15.jar
fusionauth-plugin-api-1.1.0.jar
fusionauth-search-1.0.15.jar
fusionauth-search-1.1.0.jar
inversoft-maintenance-mode-0.12.3.jar
inversoft-maintenance-mode-0.12.5.jar
inversoft-search-engine-1.2.1.jar
inversoft-search-engine-1.2.2.jar
In theory you could just go through that directory and delete any duplicate jars, keeping the more recent version.
However, I think it will be the safest for you to do a clean install, this will not disrupt your configuraiton.
For example you should be able to do something like:
rm -rf /usr/local/fusionauth/fusionauth-app
rm -rf /usr/local/fusionauth/fusionauth-search
cd /usr/local/fusionauth
sh -c "curl -fsSL https://raw.githubusercontent.com/FusionAuth/fusionauth-install/master/install.sh | sh -s - -z"
Where the last step should download the latest app and search bundles and extract them in the current directory. This should preserve your database, and the fusionauth.properties
file in the /usr/local/fusionauth/config
directory.
To be safe, please save a copy of the config file first. You may also download the zips manually here : https://fusionauth.io/downloads
Did you use a particular page in our documentation to upgrade? If so, please provide the link and I will take a look at the guide to see if we can provide a better example of upgrading using the zip file to ensure the old lib dir is not re-used.
Thanks, let me know how this goes.
Will setup a new instance with .zip and check if it can be replicated.
Thanks
@robotdan Thanks a lot for the detailed instruction, much appreciated.
I am referring to https://fusionauth.io/docs/v1/tech/upgrades-patches/overview
Keep you posted.
Hi, I updated the documentation to help anyone trying to do zip upgrades in the future.
Great, thanks for the update @preetamchanda . I'll close out this issue.