Configuring Tariscope Observer
The Tariscope Observer service (or simply Observer), which is one of the Tariscope applications, is intended for automatic collection of information about completed calls (CDR, SMDR, AMA and others) from the PBX or from files located in some folder, initial processing of this data, and also for executing scripts for individual events.
That is, the Observer is the link that connects the telephone system with the Tariscope system. One Observer is designed to interact with one telephone system (PBX). Tariscope has no limit on the number of Observers it can receive information from. Observer can be configured to receive CDR information from various types of data sources, which are mentioned below. The choice of data source type primarily depends on the type of telephone system from which the CDR data is received.
Observers can be located both on the same server where the Tariscope system is located, and on a remote computer (server) that has a connection with the Tariscope server via an IP network. Any Observer, local or remote, must have IP communication with the Tariscope server (the TS.MAIN service) and the Microsoft SQL Server (hereinafter “SQL Server”) on which the Tariscope database is installed. When the Observer starts, it contacts the Tariscope server, receives a database connection string from it, and then connects to the Tariscope database. If you have a firewall or other security systems, you must configure them that Observer will have IP access to Tariscope server (IP port: 8001) and SQL server (IP port: 1433, 1434).
An Observer can react to the following events by executing a specific script:
- Data source connected.
- Data source disconnected.
- Change class of service. This event is only relevant if the Tariscope license includes the restriction feature for subscribers.
- Group state change. This event is only relevant if the Tariscope license includes the restriction feature for group of subscribers.
- Periodic action.
- New call. The script for this event allows you to perform some additional data processing on information about the received call. For example, you can check whether the dialed number does not belong to a specific group of phone numbers.
- Database unavailable. This event may be relevant if Observer and Microsoft SQL Server are on different servers. If you lose connection to the database, a script can send a message to the administrator.
Regardless of whether you are configuring local or remote Observers, you need to configure them in the Tariscope application. These settings are the same for both types of Observers. In the future, we will consider the features of remote Observer customization
In the Tariscope menu, choose: Data collection/Observer → Observer management. A page appears, an example of which is shown in Figure 1.
Figure 1
Let's create a new Observer. Click the Add icon on the toolbar. A menu appears, select the New Observer item. The window shown in Figure 2 will appear.
Figure 2
In the Name box, enter the name of the Observer profile. We recommend naming the profile with the name of the telephone system from which this Observer will receive data. For example, you need to receive data from CUCM (Cisco). In this case, it is better to name the profile: CUCM. The name must not contain any characters other than letters and numbers. Click Save. A window will be displayed to confirm the creation of the profile (Figure 3).
Figure 3
Click Settings. The Tariscope Observer configuration page appears, an example of which is shown in Figure 4.
Figure 4
Click on the 'here' link and select an existing phone system. For our example, it should be CUCM.
In the Data source list, select the appropriate source. For our example, if CUCM is configured as an FTP client, the data source should be an FTP server. For other types of telephone systems, data sources can be: FTP client, TCP client or server, local or remote folder, and others, depending on how the telephone system provides CDR data. To configure the data source parameters, click on the button to the right of the Data source list and perform the settings. See the documentation for a description of setting up a specific data source.
The Storage of processed CDRs box is intended to select a folder to store the raw CDR data that is received from the telephone system. This data can be used if it is necessary to completely reprocess call data. By default, they are stored in the C:\ProgramData\Tariscope folder. CDR logs have the extension CDR, and the file name includes the name of the Observer's profile and the date.
In the Creation period list, select the period for creating logs with primary CDR data. The period of creation depends on the call traffic. If it is higher, the better to choose a shorter period. One month is offered as a default period.
In the Log level list, select the level of detail for the Observer profile log. The least detailed level is Status, the most detailed level is Debug.
This concludes the debugging of the local Observer. If you are configuring a Remote Observer, enable the Remote observers switch.
Click the Save button. The Data Collection/Observer page will look similar to the one shown in Figure 5.
Figure 5
If you have created a local Observer, you can start it by clicking on the Control icon and selecting Start.
In the case when you configured a profile for a remote Observer, perform the following actions.
Work on a remote server
Before making settings on a remote server, you should:
- Perform the settings indicated above on the Tariscope server.
- If a firewall is running on the Tariscope server, add rules that will allow access to the IP ports: 8001 (Tariscope server is running on it), 1433, 1434 (SQL server ports).
- Verify that the server where Tariscope was installed is reachable over the network from the remote server where Remote Observer is installed.
Install Tariscope on the remote server (computer). http://www.tariscope.com/en/88-support_en/tariscope-4-6-administrator-en/1458-installation-4-6-en.html#:~:text=1.1%20Installation%20for%20Windows
When performing the installation for Windows, in the Tariscope components stage (Figure 1.1.5 in the article at the link above), select the Observer Server. By default, the installation is performed in the folder: C:\Program Files (x86)\SoftPI\Tariscope
To run a remote Observer, you must know:
- IP address of the server where the Tariscope server is installed. For example, the IP address of the Tariscope server is 10.10.0.148.
- The name of the profile that was created there specifically for this Observer. In our example, it is: CUCM.
Open Command Prompt with Windows administrator rights. Run the following commands there.
Go to the software folders. If you installed to the default folder, this will be the command:
cd C:\Program files (x86)\SoftPI\Tariscope\Microservices
Next, start the remote Observer, specify the name of the profile (the name parameter) and the URL of the Tariscope server (the main parameter) as its parameters. An example of such a command is given below:
.\Tariscope.Observer.exe /name=CUCM /main=”http://10.10.0.148:8001”
In this example, the name of the profile is CUCM and the URL of the Tariscope server is http://10.10.0.148:8001 , where 10.10.0.148 is the IP address of the server and 8001 is the IP port on which the server is running.
An example of such data entry is shown in Figure 6.
Figure 6
If all the settings are made correctly and the network provides access from the remote Observer to the Tariscope server, then the Observer will be connected to Tariscope and SQL Server.
You can check the result of connecting Observer in its log. Observer logs, both local and remote, are kept in the C:\ProgramData\Tariscope\Logs\Observer folder on the Tariscope server or on the remote server, respectively. The log is named [Profile Name].log. For our example, this will be the file: CUCM.log
This log is generated only after the remote Observer has successfully connected to the Tariscope server. If there is no log, it means that the connection failed.
An example of the log is shown in Figure 7.
Figure 7
You can also check the connection of the remote Observer to Tariscope in Tariscope on the Observers page (Figure 8).
Figure 8
As you can see in the figure, the Service status column displays the value Online.
You must leave the Command Prompt window open with the Remote Observer running. Closing the Command Prompt will terminate Observer. And to restart it, you will need to load the Command Prompt again and repeat the above commands.
To create other remote Observers, you need to repeat all the above actions: create a profile in Tariscope, launch a remote Observer with the appropriate profile name.
You can run remote Tariscope Observers as Windows services. For this, you can use, for example, the third-party program: nssm (https://nssm.cc/).
To create a remote Observer service, run the nssm program with the following command:
nssm install TS.Observer,
where TS.Observer is the name of the service being created. If you create multiple services, they must have different names. As a result of executing the command, the window appears as shown in Figure 9.
Figure 9
In the Path box, enter the path to the Observer file:
C:\Program files (x86)\SoftPI\Tariscope\Microservices\Tariscope.Observer.exe
In the Arguments box, enter the Observer parameters: the name of the profile and the URL of the Tariscope server. For our example it will be:
/name=CUCM /main=http://10.10.0.148:8001
Click Install service.
A corresponding Windows service will be created, which must be started from the Windows Services window.