Table of Contents |
---|
Info |
---|
These instructions are still being updated for the Abiquo 6.2 upgrade |
1. Introduction
This section describes how to upgrade from Abiquo 6.1.x to an Abiquo 6.2.x version.
...
Stop the API on the API server or monolithic server
Code Block systemctl stop abiquo-tomcat
Stop the UI on the API server or monolithic server or dedicated UI server
Code Block systemctl stop httpd
Stop RabbitMQ on the API server or dedicated datanode server
Code Block systemctl stop rabbitmq-server
Stop remote services server
Code Block systemctl stop abiquo-tomcat
V2V Server
You do not need to stop anything because the BPM remote service is run on-demand onlyStop monitoring server
Code Block systemctl stop abiquo-delorean systemctl stop abiquo-emmett systemctl stop kairosdb systemctl stop cassandra
On the monitoring server, check if Cassandra is really dead
Code Block ps auwx | grep cassandra
Get the process number for Cassandra (the first number in the output of the previous command), and kill it. In this example, Cassandra is process 12345.
Code Block kill -9 12345
...
Code Block | ||
---|---|---|
| ||
# On DB server, back up the Abiquo MySQL DBs
mysqldump --routines --triggers kinton > kinton.sql-$(date +%Y%m%d_%H%M%S)
mysqldump --routines --triggers kinton_accounting > kinton_accounting.sql-$(date +%Y%m%d_%H%M%S)
# On the Monitoring server, back up Watchtower DB
mysqldump --routines --triggers watchtower > watchtower.sql-$(date +%Y%m%d_%H%M%S)
# On the Abiquo API Server or UI server, back up the UI
tar cvfz /var/www/html/ui.tgz-$(date +%Y%m%d_%H%M%S) /var/www/html/ui
# If you are using SAML authentication with multiple IdPs, on ALL Abiquo API Servers, back up this file
cp
/opt/abiquo/tomcat/webapps/api/WEB-INF/classes/springresources/security/saml/security-saml-generated-beans.xml /opt/abiquo/tomcat/webapps/api/WEB-INF/classes/springresources/security/saml/security-saml-generated-beans.xml-$(date
+%Y%m%d_%H%M%S)
# Copy the api.xml file to back up the database connection details
cp /opt/abiquo/tomcat/conf/Catalina/localhost/api.xml /opt/abiquo/api.xml-$(date +%Y%m%d_%H%M%S)
# On ALL servers, back up the /opt/abiquo folder
tar cvfz /opt/abiquo.tgz-$(date +%Y%m%d_%H%M%S) /opt/abiquo
# On Abiquo Monolithic or API Server, Remote Services, or Datanode, back up Redis
redis-cli save
cp -a /var/lib/redis /var/lib/redis-$(date +%Y%m%d_%H%M%S)
|
...
To upgrade to a version with a patch number of zero, for example, version 6.2.0
Remove the previous version Abiquo release packages.
Code Block yum remove 'abiquo-release-*'
Find the
abiquo-release-ee
package for your version in the list of available versionsInstall the release package.
For Abiquo 6.2.0, the command would be similar to the following:Code Block yum localinstall http://usr:passwd@mirror.abiquo.com/el7/6.2/os/x86_64/abiquo-release-ee-6.2.0-AAAAAAAAAAAA20240205_155724.el7.noarch.rpm
For Abiquo 6.2.1, the release package would be in the format:
Code Block http://usr:passwd@mirror.abiquo.com/el7/6.2/updates/x86_64/abiquo-release-ee-6.2.1-BBBBBBBBBBBB.el7.noarch.rpm
For major versions, disable the updates repo. See https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/6/html/deployment_guide/sec-managing_yum_repositories
...
Check that you have the repository URL and credentials
To upgrade to the latest version with a patch number that is not zero, for example, version 6.2.x, enable both repositories:
Code Block yum-config-manager --enable abiquo-base yum-config-manager --enable abiquo-updates
Optionally add your username and password to the Abiquo repos
Code Block yum-config-manager --save --setopt=abiquo-*.username=MYUSERNAME yum-config-manager --save --setopt=abiquo-*.password=MYPASSWORD
Don't forget to use a backslash to escape any shell special characters. For more details, see https://www.oreilly.com/library/view/learning-the-bash/1565923472/ch01s09.html
Clean yum and make cache
Code Block yum clean all && yum makecache
If you did not make snapshots of all servers already, then you could do this now.
9. Uninstall Docker
...
.
...
...
10. Upgrade packages on ALL servers
...
Check in your RS server(s) if there is an NFS shared folder for the NARS results (related to the Abiquo configuration property
abiquo.nars.async.fileresults.path
):Code Block language bash $ mount | grep -i "nfs\|results" | grep -v sunrpc 10.60.37.87:/abq-pro-nfs on /opt/abiquo/results-nars type nfs4 (rw,nosuid,nodev,noexec,relatime,sync,vers=4.1,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,clientaddr=10.60.37.77,local_lock=none,addr=10.60.37.87,user)
Unmount the previous shared folder if you have it mounted:
Code Block language bash sudo umount /opt/abiquo/results-nars
Also on your RS server(s) uninstall Docker
Code Block yum remove docker
Update all packages:
Code Block yum clean all && yum makecache && yum update
MariaDB update will fail. We will update it manually later
Mount the shared folder from the second step again.
Code Block language bash sudo mount -a
The Abiquo services must run as the
tomcat
user (notroot
), so set the required permissions and enforce the use of the package configuration files.
If you have a MONOLITHIC SERVER do all of the following steps on the Monolithic serverOn Abiquo server and remote services
Code Block chown -R tomcat /opt/abiquo
On the remote services with appliance manager and the V2V server (i.e. servers that mount the NFS repository)
Code Block chown -R tomcat /opt/vm_repository chmod -R a+r /opt/vm_repository
On the V2V server, check the
/etc/sysconfig/abiquo/ec2-api-tools
file exists.
The file must contain the following configuration. If the file does not exist, create it and add this configuration.For CentOS 7
Code Block EC2_HOME=/opt/aws
...
Download and install the
guestpasswordmigrator
packageRun the tool to migrate the guest passwords of the current VMs to a new column that will be added in 6.2.0.
The tool requires access to the
kinton
database and to the API RedisUsage:
Code Block --jdbc-url VAL : Replace VAL with Kinton JDBC URL including user and password --output-file VAL : Replace VAL with the output file (by default: 'guestpasswords.sql') --redis-host VAL : Redis host to connect --redis-port N : Redis port to connect (by default: 6379)
For example:
Code Block java -jar gpmigrator.jar --jdbc-url="jdbc:mariadb://localhost:3306/kintonuserkinton?user=root&password=root" --redis-host=localhost
Save the
guestpasswords.sql
file and run it after you update the database withabiquo-db
.
...