-
Notifications
You must be signed in to change notification settings - Fork 476
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
add Glassfish4-to-Payara5 upgrade instructions to Dataverse 5 release notes #7125
Merged
Merged
Changes from 2 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
01463d5
#6961 add Glassfish4-to-Payara5 upgrade instructions
donsizemore be7251e
couple of small additions to the instruction #6961
landreev 13fd3c8
#6961 use dataverse as service account instead of payara
donsizemore 7a4a63d
#6961 The Installation Guide recommends a service account of dataverse.
donsizemore File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
Upgrade Dataverse from Glassfish 4.1 to Payara 5 | ||
================================================ | ||
|
||
The instruction below describes the upgrade procedure based on moving an existing glassfish4 domain directory under Payara. We recommend this method, instead of setting up a brand-new Payara domain using the installer because it appears to be the easiset way to recreate your current configuration and preserve all your data. | ||
|
||
Download Payara, v5.2020.2 as of this writing: | ||
|
||
# curl -L -O https://github.com/payara/Payara/releases/download/payara-server-5.2020.2/payara-5.2020.2.zip | ||
# sha256sum payara-5.2020.2.zip | ||
1f5f7ea30901b1b4c7bcdfa5591881a700c9b7e2022ae3894192ba97eb83cc3e | ||
|
||
Unzip it somewhere (/usr/local is a safe bet) | ||
|
||
# sudo unzip payara-5.2020.2.zip -d /usr/local/ | ||
|
||
Copy the Postgres driver to /usr/local/payara5/glassfish/lib | ||
|
||
# sudo cp /usr/local/glassfish4/glassfish/lib/postgresql-42.2.9.jar /usr/local/payara5/glassfish/lib/ | ||
|
||
Move payara5/glassfish/domains/domain1 out of the way | ||
|
||
# sudo mv /usr/local/payara5/glassfish/domains/domain1 /usr/local/payara5/glassfish/domains/domain1.orig | ||
|
||
Undeploy the Dataverse web application (if deployed; version 4.20 is assumed in the example below) | ||
|
||
# sudo /usr/local/glassfish4/bin/asadmin list-applications | ||
# sudo /usr/local/glassfish4/bin/asadmin undeploy dataverse-4.20 | ||
|
||
Stop Glassfish; copy domain1 to Payara | ||
|
||
# sudo /usr/local/glassfish4/bin/asadmin stop-domain | ||
# sudo cp -ar /usr/local/glassfish4/glassfish/domains/domain1 /usr/local/payara5/glassfish/domains/ | ||
|
||
Remove the Glassfish cache directories | ||
|
||
# sudo rm -rf /usr/local/payara5/glassfish/domains/domain1/generated/ | ||
# sudo rm -rf /usr/local/payara5/glassfish/domains/domain1/osgi-cache/ | ||
|
||
In domain.xml: | ||
============= | ||
|
||
Replace the -XX:PermSize and -XX:MaxPermSize JVM options with -XX:MetaspaceSize and -XX:MaxMetaspaceSize. | ||
|
||
<jvm-options>-XX:MetaspaceSize=256m</jvm-options> | ||
<jvm-options>-XX:MaxMetaspaceSize=512m</jvm-options> | ||
|
||
Set both Xmx and Xms at startup to avoid runtime re-allocation. Your Xmx value should likely be higher: | ||
|
||
<jvm-options>-Xmx2048m</jvm-options> | ||
<jvm-options>-Xms2048m</jvm-options> | ||
|
||
Add the below JVM options beneath the -Ddataverse settings: | ||
|
||
<jvm-options>-Dfish.payara.classloading.delegate=false</jvm-options> | ||
<jvm-options>-XX:+UseG1GC</jvm-options> | ||
<jvm-options>-XX:+UseStringDeduplication</jvm-options> | ||
<jvm-options>-XX:+DisableExplicitGC</jvm-options> | ||
|
||
Change any full pathnames /usr/local/glassfish4/... to /usr/local/payara5/... or whatever it is in your case. (Specifically check the -Ddataverse.files.directory and -Ddataverse.files.file.directory JVM options) | ||
|
||
In domain1/config/jhove.conf, change the hard-coded /usr/local/glassfish4 path, as above. | ||
|
||
(Optional): If you renamed your service account from glassfish to payara or appserver, update the ownership permissions: | ||
|
||
# sudo chown -R payara /usr/local/payara5/glassfish/domains/domain1 | ||
# sudo chown -R payara /usr/local/payara5/glassfish/lib | ||
|
||
You will also need to check that the new user has write permission on the files directory, if they are located outside the old Glassfish domain. And/or make sure the new user account has the correct AWS credentials, if you are using S3 for storage. | ||
|
||
Finally, start Payara: | ||
|
||
# sudo -u payara /usr/local/payara5/bin/asadmin start-domain | ||
|
||
Deploy the Dataverse 5 warfile: | ||
|
||
# sudo -u payara /usr/local/payara5/bin/asadmin deploy /path/to/dataverse-5.0.war | ||
|
||
Then restart Payara: | ||
|
||
# sudo -u payara /usr/local/payara5/bin/asadmin stop-domain | ||
# sudo -u payara /usr/local/payara5/bin/asadmin start-domain | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@landreev here you change to a
payara
user, as I had, but per @pdurbin I understand the 5.0 guides will useappserver
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, no, sorry. The Dataverse 5 guides run Payara under a Unix user called "dataverse". Screnshot below.