Managing Ad-Hoc filters in Contact Analyzer

I realized that when we migrated our CA instance, the ad-hoc filters didn't come with. (To be honest, it was my users who noticed first :shame:)

I knew they had to be stored somewhere on the file system, as we did a database migration and they didn't come with.

A quick search for "where are contact analyzer filters stored" turned up Avaya Professional Services - Contact Analyzer - Administration Guide - Version 1.6.8:

The report filters are xml files located in several directories under:$CA_HOME/bi*/tomcat/webapps/pentaho

With this, I was able to download all the old filters (this was easy, as I could login as root on the old box). Getting them up proved to be mildly more complicated, as I didn't have write permission to the folder on the new server; I couldn't use WinSCP to copy them because WinSCP can't elevate mid-session. Fortunately, I found a great AskUbuntu post that had the info I needed.

This snippet allows me to upload files into the savedquery folder without changing owner/group:

$ cd /opt/Avaya/CA/biserver-ce/tomcat/webapps/pentaho/apcadhoc/
$ sudo setfacl -m u:username:rwx savedquery

Now upload your files to the savedquery folder using WinSCP, or whatever program you like.

Finally, users will get Network Error #2032 if you leave yourself as the owner of the files. Fix the permissions the same way we did in the first place:

$ cd savedquery
$ sudo chown avaya:avaya *
$ sudo setfacl -m u:username:rwx *

We migrated from ACA 1.5.1 to 1.6.9 and the filters ported over without needing any changes.