# IRIS Focus 7.5 patch 5

## 1. What this patch contains

New in patch 5:

- FIRE-12245: In the azimuthal equidistant map projection, zooming out in a
  small map pane (for example one pane of the four product tiled view) could
  leave the map stuck: it could no longer be panned or zoomed back in. How far
  the map can be zoomed out no longer depends on the size of the map pane.

This patch is cumulative. If you have not applied an earlier IRIS Focus
7.5 patch, it also includes the fixes from those patches:

- FIRE-12667: The way IRIS Focus integrates with LDAP has been replaced.
  See section 6 below, this change requires configuration file edits.
- FIRE-12868: Product times are refreshed after a significant change or jump
  in the displayed time.
- FIRE-11688: LDAP users that have no assigned roles are prevented from
  logging in, and a hybrid data display issue was corrected.

## 2. Acquire the patch

Contact your Vaisala PCS support representative to obtain the 
iris-focus-7.5-patch-5.tar.gz file containing instructions,
software and configuration updates.

## 3. Transfer the patch file to the IRIS Focus server

Use a secure file transfer method (e.g., SCP, SFTP) to copy the patch file to the
IRIS Focus server. Place the patch file in a temporary directory, such as:
`/srv/iris-focus-7.5-patch-5`.

## 4. Stop IRIS Focus services

Before applying the patch, stop the following IRIS Focus services to prevent any
conflicts during the installation process. Use the following command to stop the
services:

    systemctl stop monit vaisala-radarsw-webapp

## 5. Extract and apply the patch

Log in as root (or "sudo -i") and change to the temporary directory where the
patch tar file was stored.

If you used the suggested location, you can use the following commands to
switch to the root user and change to the temporary directory:

    sudo -i
    cd /srv/iris-focus-7.5-patch-5

Next extract and apply the patch using the following commands:

    tar xvzf iris-focus-7.5-patch-5.tar.gz
    ./apply-patch.sh

Once the patch is applied, the /usr/vaisala/radarsw/version should show
7.5.5. You can check this with the following command:

    cat /usr/vaisala/radarsw/version

## 6. Check/Edit configuration files

If you have already applied an earlier IRIS Focus 7.5 patch, and you
completed the configuration steps for it at that time, you can skip this whole
section. The fix in patch 5 does not require any configuration change.

The rest of this section applies when you are moving to patch 5 from an
installation that has not had an earlier 7.5 patch applied.

### /etc/vaisala/radarsw/webapp/application.yaml

The application.yaml file required changes for this patch that
will require human review and editing. You will need to transfer
information from your previous application.yaml file into the
appropriate locations in the new application.yaml file. In,
in particular:

- Kafka settings (in particular the bootstrap servers and any
  security settings)
- LDAP settings (if you are using LDAP)
- Any other custom settings you may have adjusted in your 
  application.yaml file

A backup of your original application.yaml file is included in
the patch with the name application.yaml.before-7.5-patch-5.
You can use this file to review the settings you had in place
before the patch and transfer them to the new application.yaml file.

The way IRIS Focus integrates with LDAP has been replaced. The way
LDAP integration is configured is different. You will not be able
to directly copy your prior ldap configuration into the new
application.yaml file. LDAP configuration uses the same basic
parameters but the layout is different and you no longer need to
specify a "sudo" LDAP user account (which should make your IT
department happier). The new template configuration file has
additional comments that should help explain the parameters and how
to configure them.

To see the differences between the old and new configuration files, you
can use the following command:

    cd /etc/vaisala/radarsw/webapp 
    diff application.yaml application.yaml.before-7.5-patch-5

Please review all differences. You will need to restore your Kafka settings
apply your LDAP settings to the new configuration file. You may also have other
custom settings that you will need to restore in the new configuration file.

Hint: If you have emacs installed and know how to use ediff, you can use the
following command to compare the two files side by side with differences
highlighted and the ability to easily copy changes from one file to the other:

    emacs -nw application.yaml application.yaml.before-7.5-patch-5

A README-LDAP.md file is included detailing how LDAP integration
is done, configured as well as some troubleshooting tips. Please refer
to that file for much more information if you have not already received
it in an alternative form.

### /etc/haproxy/haproxy.cfg

NOTE: This step applies to every installation. The patch installs an
updated haproxy.cfg over /etc/haproxy/haproxy.cfg, so you should review
it even if you do not intend on upgrading the haproxy package.

It was discovered that the /etc/haproxy/haproxy.cfg created by the
IRIS Focus 7.5 installation is not compatible with newer versions
of the haproxy package. This can be an issue for installations
that have automatic updates enabled for OS packages.

If you upgrade the haproxy package to a newer version, such as 2.8.0
or later, it will refuse to start until you make changes to the
haproxy.cfg file that was created at the time IRIS Focus was installed.

The haproxy.cfg file is sometimes tweaked by customers for the
particular installation. This patch installs the updated haproxy.cfg
and preserves a copy of the one that was on your system beforehand, so
that you can restore any customizations you had made.

Compare the two files and re-apply any of your own customizations to
/etc/haproxy/haproxy.cfg:

    cd /etc/haproxy
    diff haproxy.cfg.before-7.5-patch-5 haproxy.cfg

## 7. Restart IRIS Focus services

After applying the patches and making any necessary changes to the
configuration files, restart the IRIS Focus services using the following
command:

    systemctl start vaisala-radarsw-webapp monit

If you had to make changes to the haproxy.cfg file, you will also need
to restart the haproxy service:

    systemctl restart haproxy

## 8. Verify the fix

Open IRIS Focus in a browser and confirm the map behaves correctly. If your
installation uses the azimuthal equidistant projection, display the four
product tiled view, zoom all the way out in one of the panes, and confirm that
you can still pan the map and zoom back in.

Note that your browser may still be holding cached map images from before the
patch. If the map looks wrong after the patch, force a reload of the page
(Ctrl-Shift-R in most browsers) before reporting a problem.

## 9. Remove the patch file and temporary directory

After the patch has been successfully applied and the services have been
restarted, you can remove the patch file and the temporary directory to
free up space on the server. If you used the suggested location, use the
following command to remove the patch file and temporary directory:

    rm -rf /srv/iris-focus-7.5-patch-5
