Difference between revisions of "PEC-REP/Current/GCXIPEGuide/Upgrade"

From Genesys Documentation
Jump to: navigation, search
(Published)
 
 
(4 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{Article
+
{{ArticlePEServiceUpgrade
|Standalone=No
+
|ServiceId=1f419ea4-5e6e-4052-abc1-c56ff55106e2
|DisplayName=Upgrade, rollback, or uninstall GCXI
+
|AddIncluded=Yes
|TocName=Upgrade, rollback, or uninstall
+
|IncludedServiceUpgradeStrategy={{IncludedServiceUpgradeStrategy
|Context=Learn how to upgrade, rollback or uninstall Genesys Customer Experience Insights (GCXI).
+
|IncludedServiceId=4e6a78a6-ecb9-4886-8819-016d7f81b06f
|ComingSoon=No
+
|IncludedServiceUpgradeStrategy=40f069a2-01ae-4027-9aef-13f54bc53613
|Section={{Section
+
}}{{IncludedServiceUpgradeStrategy
|sectionHeading=Upgrade GCXI
+
|IncludedServiceId=5462861b-e347-4eaa-b621-9795838ee431
|alignment=Vertical
+
|IncludedServiceUpgradeStrategy=40f069a2-01ae-4027-9aef-13f54bc53613
|structuredtext=In scenarios where you have previously deployed Genesys CX Insights using Helm, use the instructions in this procedure to upgrade to a newer Genesys CX Insights release.
+
}}
 +
|OptionalServiceIntro=In scenarios where you have previously deployed GCXI using Helm, use the instructions on this page to upgrade to a newer GCXI release.
 +
|OptionalPreparatorySteps=The Helm installation package (IP) has a file name in the format gcxi-<nowiki>&</nowiki>lt;release<nowiki>&</nowiki>gt;.tgz, for example '''gcxi-100.0.029+0000.tgz'''.  
  
===Prerequisites===
+
The following steps provide detailed information about preparing to upgrade GCXI:
Obtain the Helm installation package (IP) before you begin. The Helm IP has a file name in the format gcxi-<nowiki>&</nowiki>lt;release<nowiki>&</nowiki>gt;.tgz, for example '''gcxi-018.00.tgz'''.
 
  
#On the Control Plane node, set the current directory to the helm folder, and execute the following command to create a subfolder to differentiate this release from others:  
+
#On the Control Plane node, set the current directory to the helm folder, and run the following command to create a subfolder to differentiate this release from others:  
 
#:<source lang="LANGUAGE">mkdir helm_<folder></source>
 
#:<source lang="LANGUAGE">mkdir helm_<folder></source>
#:where &lt;folder&gt; is the folder in which to extract the Helm package. For example '''018.00'''.
+
#:where &lt;folder&gt; is the folder in which to extract the Helm package. For example: '''018.00'''.
#Execute the following command to extract the Helm package:
+
#To extract the Helm package, run the following command:
 
#:<source lang="bash">tar xvzf <helm IP file name> -C helm_<folder></source>
 
#:<source lang="bash">tar xvzf <helm IP file name> -C helm_<folder></source>
#:where &lt;folder&gt; is the folder you created in the previous step, and &lt;helm IP file name&gt; is the name of the gcxi Helm package you are installing.
+
#:where:<br />&lt;folder&gt; is the folder you created in the previous step.<br /> &lt;helm IP file name&gt; is the name of the gcxi Helm package you are installing.
 
#:For example:
 
#:For example:
 
#:<source lang="bash">mkdir helm_018.00; tar xvzf gcxi-9.0.018.00.tgz -C helm_018.00</source>
 
#:<source lang="bash">mkdir helm_018.00; tar xvzf gcxi-9.0.018.00.tgz -C helm_018.00</source>
#Execute the following command to remove Ingress:
 
#:<source lang="bash">helm delete gcxi-nginx -n ingress-nginx</source>
 
 
#From the folder where you deployed the previous release of GCXI using Helm, copy the file '''values-test.yaml''' into the new folder.
 
#From the folder where you deployed the previous release of GCXI using Helm, copy the file '''values-test.yaml''' into the new folder.
#Navigate to the new folder (for example, using the CD command), and execute the following command:
+
 
#:<source lang="bash">helm upgrade --debug gcxi-helm gcxi/ --namespace gcxi --create-namespace -f values-test.yaml</source>
+
==Back up the meta database==
#Execute the following command to configure Ingress:
+
 
#:<source lang="bash">helm install --debug --set controller.kind=DaemonSet --set controller.hostNetwork=true --set tcp.34952=gcxi/gcxi:mstr --set tcp.8180=gcxi/gcxi:metrics gcxi-nginx ingress-nginx/ingress-nginx --create-namespace -n ingress-nginx</source>
+
The GCXI upgrade process automatically backs up your meta database before upgrading to the new release of GCXI. However, GCXI also provides additional options to back up the contents of your meta database, including:
|Status=No
+
*Scheduled backup using the container option BACKUP_HOUR.
}}{{Section
+
*Immediate backup using a Kubernetes job.
|sectionHeading=Rollback GCXI
+
*Immediate backup using PostgreSQL tools.
|alignment=Vertical
+
 
|structuredtext=No rollback procedure is available.
+
Backup files are stored in the gcxi-shared mount point, which is found in /genesys/gcxi/shared, unless you configure a different location. (By default, backups are stored in a subfolder called backup in /genesys/gcxi/shared).
|Status=No
+
 
}}{{Section
+
===Back up using the container variable===
|sectionHeading=Uninstall GCXI
+
Genesys recommends that you configure the container option to automatically back up your data. To schedule automatic backups, set the following container variable:
|alignment=Vertical
+
<source lang="bash">BACKUP_HOUR=<time></source>
|structuredtext=Complete the following steps to remove GCXI:
+
Where &lt;time&gt; digits in 24-hr format instruct the container to perform meta db backup in corresponding hours, for example to back up at 22:00, 6:00, and 15:00 hours:
#Execute the following command to remove Ingress:
+
<source lang="bash">BACKUP_HOUR=22,6,15</source>
#:<source lang="bash">helm delete gcxi-nginx -n ingress-nginx</source>
+
 
#Execute the following command to remove GCXI:
+
===Back up using the Kubernetes job===
#:<source lang="bash">helm uninstall gcxi-helm -n gcxi</source>
+
You can perform a backup at any time using the included Kubernetes job, gcxi-backup, as follows:
|Status=No
+
<source lang="bash">kubectl delete job "gcxi-backup" || true
}}
+
kubectl apply -f gcxi-backup.yaml</source>
|PEPageType=2cad3824-b3b9-43aa-a726-143cc1aaefe2
+
 
 +
This creates two backup files (that is, service databases): mstr_meta_<tag>.pgdump and mstr_hist_<tag>.pgdump, where &lt;tag&gt; is a timestamp. You can optionally set another value for <tag> using the BACKUP_TAG variable in gcxi-backup job yaml.
 +
 
 +
===Restoring from a backup===
 +
Ensure that backup files (pgdump) are present in the '''gcxi-shared''' mount location. If they are in another location, you must set the RESTORE_TAG variable in the '''gcxi-restore.yaml''' file.
 +
 
 +
You must stop the GCXI pods before performing a restore operation. Stop the pods using the following command:
 +
 
 +
<source lang="bash">kubectl scale --replicas=0 statefulset/gcxi</source>
 +
 
 +
Execute the following commands to restore the meta database:<source lang="bash">kubectl delete job "gcxi-restore" || true
 +
kubectl apply -f gcxi-restore.yaml</source>
 +
 
 +
Use the following command to restart the pods:
 +
<source lang="bash">kubectl scale --replicas=1 statefulset/gcxi</source>
 +
|RollUpdUpgradeExt=====GCXI example====
 +
 
 +
Set the command context by navigating to the new folder you created (see [[{{FULLPAGENAME}}#PrepStep3|above]]) and run the following command:
 +
<source lang="bash">helm upgrade --debug gcxi-helm gcxi/ --namespace gcxi --create-namespace -f values-test.yaml</source>
 +
 
 +
====RAA example====
 +
Run the following command:
 +
 
 +
<source lang="bash">
 +
helm upgrade gcxi-raa-lab helmrepo/gcxi-raa --values myvalues.yaml</source>
 +
|RollUpdRollbackExt=====RAA example====
 +
<source lang="bash">helm rollback gcxi-raa-lab --recreate-pods</source>
 +
====GCXI example====
 +
{{NoteFormat|Do not use the <tt>rollback</tt> command to roll back a GCXI upgrade. You must re-install a previous version.}}
 +
|UninstallExt=====GCXI example====
 +
 
 +
Execute the following command to remove GCXI:
 +
<source lang="bash">helm uninstall gcxi-helm -n gcxi</source>
 +
<!--Question for reviewers: OR, should it be?:
 +
<source lang="bash">helm uninstall gcxi-oc -n gcxi</source>-->
 +
 
 +
====RAA example====
 +
<source lang="bash">helm uninstall gcxi-raa-lab</source>
 
}}
 
}}

Latest revision as of 12:15, February 16, 2023

This topic is part of the manual Genesys Customer Experience Insights Private Edition Guide for version Current of Reporting.

Learn how to upgrade, roll back, or uninstall GCXI.

Important
The instructions on this page assume you have deployed the services in service-specific namespaces. If you are using a single namespace for all private edition services, replace the namespace element in the commands on this page with the name of your single namespace or project.

Supported upgrade strategies

Genesys Customer Experience Insights supports the following upgrade strategies:

ServiceUpgrade StrategyNotes
Genesys CX Insights
Reporting and Analytics Aggregates

The upgrade or rollback process to follow depends on how you deployed the service initially. Based on the deployment strategy adopted during initial deployment, refer to the corresponding upgrade or rollback section on this page for related instructions.

For a conceptual overview of the upgrade strategies, refer to Upgrade strategies in the Setting up Genesys Multicloud CX Private Edition guide.

In scenarios where you have previously deployed GCXI using Helm, use the instructions on this page to upgrade to a newer GCXI release.

Timing

A regular upgrade schedule is necessary to fit within the Genesys policy of supporting N-2 releases, but a particular release might warrant an earlier upgrade (for example, because of a critical security fix).

If the service you are upgrading requires a later version of any third-party services, upgrade the third-party service(s) before you upgrade the private edition service. For the latest supported versions of third-party services, see the Software requirements page in the suite-level guide.

Scheduling considerations

Genesys recommends that you upgrade the services methodically and sequentially: Complete the upgrade for one service and verify that it upgraded successfully before proceeding to upgrade the next service. If necessary, roll back the upgrade and verify successful rollback.

Monitoring

Monitor the upgrade process using standard Kubernetes and Helm metrics, as well as service-specific metrics that can identify failure or successful completion of the upgrade (see Observability in Genesys Customer Experience Insights).

Genesys recommends that you create custom alerts for key indicators of failure — for example, an alert that a pod is in pending state for longer than a timeout suitable for your environment. Consider including an alert for the absence of metrics, which is a situation that can occur if the Docker image is not available. Note that Genesys does not provide support for custom alerts that you create in your environment.

Preparatory steps

Ensure that your processes have been set up to enable easy rollback in case an upgrade leads to compatibility or other issues.

Each time you upgrade a service:

  1. Review the release note to identify changes.
  2. Ensure that the new package is available for you to deploy in your environment.
  3. Ensure that your existing <override>-values.yaml file is available and update it if required to implement changes.

The Helm installation package (IP) has a file name in the format gcxi-<release>.tgz, for example gcxi-100.0.029+0000.tgz.

The following steps provide detailed information about preparing to upgrade GCXI:

  1. On the Control Plane node, set the current directory to the helm folder, and run the following command to create a subfolder to differentiate this release from others:
    mkdir helm_<folder>
    where <folder> is the folder in which to extract the Helm package. For example: 018.00.
  2. To extract the Helm package, run the following command:
    tar xvzf <helm IP file name> -C helm_<folder>
    where:
    <folder> is the folder you created in the previous step.
    <helm IP file name> is the name of the gcxi Helm package you are installing.
    For example:
    mkdir helm_018.00; tar xvzf gcxi-9.0.018.00.tgz -C helm_018.00
  3. From the folder where you deployed the previous release of GCXI using Helm, copy the file values-test.yaml into the new folder.

Back up the meta database

The GCXI upgrade process automatically backs up your meta database before upgrading to the new release of GCXI. However, GCXI also provides additional options to back up the contents of your meta database, including:

  • Scheduled backup using the container option BACKUP_HOUR.
  • Immediate backup using a Kubernetes job.
  • Immediate backup using PostgreSQL tools.

Backup files are stored in the gcxi-shared mount point, which is found in /genesys/gcxi/shared, unless you configure a different location. (By default, backups are stored in a subfolder called backup in /genesys/gcxi/shared).

Back up using the container variable

Genesys recommends that you configure the container option to automatically back up your data. To schedule automatic backups, set the following container variable:

BACKUP_HOUR=<time>

Where <time> digits in 24-hr format instruct the container to perform meta db backup in corresponding hours, for example to back up at 22:00, 6:00, and 15:00 hours:

BACKUP_HOUR=22,6,15

Back up using the Kubernetes job

You can perform a backup at any time using the included Kubernetes job, gcxi-backup, as follows:

kubectl delete job "gcxi-backup" || true
kubectl apply -f gcxi-backup.yaml

This creates two backup files (that is, service databases): mstr_meta_<tag>.pgdump and mstr_hist_<tag>.pgdump, where <tag> is a timestamp. You can optionally set another value for <tag> using the BACKUP_TAG variable in gcxi-backup job yaml.

Restoring from a backup

Ensure that backup files (pgdump) are present in the gcxi-shared mount location. If they are in another location, you must set the RESTORE_TAG variable in the gcxi-restore.yaml file.

You must stop the GCXI pods before performing a restore operation. Stop the pods using the following command:

kubectl scale --replicas=0 statefulset/gcxi

Execute the following commands to restore the meta database:

kubectl delete job "gcxi-restore" || true
kubectl apply -f gcxi-restore.yaml

Use the following command to restart the pods:

kubectl scale --replicas=1 statefulset/gcxi

Rolling Update

Rolling Update: Upgrade

Execute the following command to upgrade <service>:

helm upgrade --install <service> -f <override>-values.yaml <Helm package> -n <namespace>

Tip: If your review of Helm chart changes (see Preparatory Step 3) identifies that the only update you need to make to your existing <override>-values.yaml file is to update the image version, you can pass the image tag as an argument by using the --set flag in the command:

helm upgrade --install <service> -f <override>-values.yaml <Helm package> --set <service>.image.tag=<new service version>

GCXI example

Set the command context by navigating to the new folder you created (see above) and run the following command:

helm upgrade --debug gcxi-helm gcxi/ --namespace gcxi --create-namespace -f values-test.yaml

RAA example

Run the following command:

helm upgrade gcxi-raa-lab helmrepo/gcxi-raa --values myvalues.yaml

Rolling Update: Verify the upgrade

Follow usual Kubernetes best practices to verify that the new service version is deployed. See the information about initial deployment for additional functional validation that the service has upgraded successfully.

Rolling Update: Rollback

Execute the following command to roll back the upgrade to the previous version:

helm rollback <service>

or, to roll back to an even earlier version:

helm rollback <service> <revision version>

Alternatively, you can re-install the previous package:

  1. Revert the image version in the <service>.image.tag parameter in the <override>-values.yaml file. If applicable, also revert any configuration changes you implemented for the new release.
  2. Execute the following command to roll back the upgrade:
    helm upgrade --install <service> -f <override>-values.yaml <old Helm package>
    Tip: You can also directly pass the image tag as an argument by using the --set flag in the command:
    helm upgrade --install <service> -f <override>-values.yaml <old Helm package> --set <service>.image.tag=<old service version>

RAA example

helm rollback gcxi-raa-lab --recreate-pods

GCXI example

Important
Do not use the rollback command to roll back a GCXI upgrade. You must re-install a previous version.

Rolling Update: Verify the rollback

Verify the rollback in the same way that you verified the upgrade (see Rolling Update: Verify the upgrade).


Uninstall

Warning
Uninstalling a service removes all Kubernetes resources associated with that service. Genesys recommends that you contact Genesys Customer Care before uninstalling any private edition services, particularly in a production environment, to ensure that you understand the implications and to prevent unintended consequences arising from, say, unrecognized dependencies or purged data.

Execute the following command to uninstall <service>:

helm uninstall <service> -n <namespace>

GCXI example

Execute the following command to remove GCXI:

helm uninstall gcxi-helm -n gcxi

RAA example

helm uninstall gcxi-raa-lab


Comments or questions about this documentation? Contact us for support!