Skip to content
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

Documentation Enhacement - Upgrade ORDS v3.0.9 via OXAR installation to v18.3 up to v19.4 #265

Open
GasparYYC opened this issue Apr 26, 2019 · 1 comment

Comments

@GasparYYC
Copy link

GasparYYC commented Apr 26, 2019

I propose a new document/section on the github page of OXAR that has specific information about upgrading to Oracle ORDS (release 18.3 in this example)
This is not using patches that requires any kind of support, this is by downloading the current version available for download.

These are the steps I followed and have upgraded my ORDS installation from version v3.0.9 to v18.3
No issues whatsover.

Note: All commands must be run as root

pm2 stop node4ords
systemctl stop tomcat@oxar
cd ~
mkdir ords183
cd ords183
wget https://www.dropbox.com/s/9rqvkqaclfe8mpv/ords-18.3.0.270.1456.zip
unzip ords-18.3.0.270.1456.zip
cd /var/lib/tomcat/webapps
mv ords.war ords.war.309
rm -rf /var/lib/tomcat/webapps/ords/*
cp /root/ords183/ords.war /var/lib/tomcat/webapps
unzip ords.war -d ords   
chown -R tomcat:tomcat ords

Run the install of ORDS and answer the prompts, with a vanilla OXAR you should only be prompted for the config directory and SYS password:

java -jar ords.war install advanced

This Oracle REST Data Services instance has not yet been configured.
Please complete the following prompts

Enter the location to store configuration data:/etc

Verify ORDS schema in Database Configuration apex with connection host: localhost port: 1521 sid: xe


Retrieving information.
Requires SYS AS SYSDBA to verify Oracle REST Data Services schema.

Enter the database password for SYS AS SYSDBA:
Confirm password:

Retrieving information.
Upgrading Oracle REST Data Services schema 3.0.9.348.07.16 to version 18.3.0.r2701456
... Log file written to /root/ords_upgrade_2019-04-26_152715_00068.log
... Upgrading ORDS schema to 18.3.0.r2701456
Completed upgrade for Oracle REST Data Services version 18.3.0.r2701456.  Elapsed time: 00:00:19.461

Enter 1 if you wish to start in standalone mode or 2 to exit [1]:2

Now start tomcat and while its running configure the configdir. (for some weird reason it only worked while running, maybe a bug?).
Then start node4ords and you're done!

systemctl start tomcat@oxar
java -jar ords.war configdir /etc
pm2 start node4ords 

Last step is to cleanup:

cd ~
rm -rf ords183

Note:
Seems ORDS leaves some views with errors or at least on a weird state, the log shows errors like this:

WARNING: ORA-04063: view "ORDS_METADATA.UNIFIED_POOL_CONFIG" has errors
java.sql.SQLException: ORA-04063: view "ORDS_METADATA.UNIFIED_POOL_CONFIG" has errors

Check the views owned by ORDS_METADATA schema and if there are some views with errors, validate to have them fixed.
For me I just run the following and works/fix the issue always:

cd /var/lib/tomcat/webapps
java -jar ords.war validate --database apex

Requires SYS AS SYSDBA to verify Oracle REST Data Services schema.

Enter the database password for SYS AS SYSDBA:
Confirm password:

Retrieving information.

Oracle REST Data Services will be validated.
Validating Oracle REST Data Services schema version 18.3.0.r2701456
... Log file written to /root/ords_validate_core_2019-04-26_203740_00175.log
Completed validating Oracle REST Data Services version 18.3.0.r2701456.  Elapsed time: 00:00:08.26
@GasparYYC
Copy link
Author

GasparYYC commented Jul 4, 2020

Update 2020-07-03:
I just want to share with everyone I just used the same steps for upgrading ORDS 18.3 to 19.4
All views were valid and life was perfect.
Update 2020-08-02:
Upgrade of ORDS with servers with just 1 GB of RAM fails with this error " java.lang.OutOfMemoryError: Java heap space". The solution with Digital Ocean (the cloud provider I use) I resized the server to a 2GB of RAM, upgraded then reduced back to 1 GB of RAM to prevent unecessary charges. As a workaround (untested) would be to reduce the memory used by XE to the lowest possible value.

Note: I had to validate ORDS views after I installed APEX 20.1, for some reason the installation of APEX 20.1 invalidated the views. The validation worked flawless.

@GasparYYC GasparYYC changed the title Documentation Enhacement - Upgrade ORDS v3.0.9 via OXAR installation to v18.3 Documentation Enhacement - Upgrade ORDS v3.0.9 via OXAR installation to v18.3 up to v19.4 Jul 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant