Session Recording 2110

Manage your database records

The ICA Log database (ICLDB) utility is a database command-line utility used to manipulate the session recording database records. This utility is installed, during the Session Recording installation, to the drive:\Program Files\Citrix\SessionRecording\Server\Bin folder on the server hosting the Session Recording Server.

Quick reference chart

The following table lists the commands and options that are available for the ICLDB utility. Type the commands using the following format:

icldb [version | locate | dormant | import | archive | remove | removeall] command-options [/l] [/f] [/s] [/?]

Note:

More extensive instructions are available in the help associated with the utility. To access the help, from a command prompt, type the drive: \Program Files\Citrix\SessionRecording\Server\Bin folder, and type icldb /?. To access help for specific commands, type icldb *command* /?.

Command Description
archive Archives the session recording files older than the retention period specified. Use this command to archive recordings and events in the recordings. The events are archived in the ArchivedEvent database table.
dormant Displays or counts the session recording files that are considered dormant. Dormant files are session recordings that were not completed due to data loss. Use this command to verify if you suspect that you are losing data. You can check whether the session recording files are becoming dormant for the entire database, or only recordings made within the specified number of days, hours, or minutes.
import Imports session recording files to the Session Recording database. Use this command to rebuild the database if you lose database records. Also, use this command to merge databases (if you have two databases, you can import the files from one of the databases).
locate Locates and displays the full path to a session recording file using the file ID as the criteria. Use this command when you are looking for the storage location of a session recording file. It is also one way to verify if the database is up-to-date with a specific file.
remove Removes the references to session recording files from the database. Use this command (with caution) to clean up the database. Specify the retention period to be used as the criteria. You can also remove the associated physical file.
removeall Removes all references to session recording files from the Session Recording Database and returns the database to its original state. The actual physical files are not deleted; however, you cannot search for these files in the Session Recording Player. Use this command (with caution) to clean up the database. Deleted references can be reversed only by restoring from your backup.
version Displays the Session Recording Database schema version.
/l Logs the results and errors to the Windows event log.
/f Forces the command to run without prompts.
/s Suppresses the copyright message.
/? Displays help for the commands.

Archive session recording files

To maintain an adequate level of spare disk capacity in the recording storage locations, archive session recording files regularly. Depending on the amount of disk space available and the typical size of session recording files, archiving intervals differ. Session recording files must be older than two days from the start date before a session recording file can be archived. This rule is to prevent any live recordings from being archived before they become complete.

Two methods are available when you archive session recordings. The database record for a session recording file can be updated to have a status of archived while the session recording file remains in the recording storage location. This method can be used to reduce the search results in the Player. The other method is to update the database record for a session recording file to the status of archived and also move the session recording file from the recording storage location to another location for backup to alternative media. When the ICLDB utility moves session recording files, the files are moved to the specified directory where the original file folder structure of year/month/day no longer exists.

The session recording record in the Session Recording Database contains two fields associated with archiving: the archive time representing the current date and time a session recording was archived; the archive note, an optional text note that might be added by the administrator during archiving. The two fields indicate a session recording has been archived and the time of archiving.

In the Session Recording Player, any archived session recordings show a status of Archived and the date and time of archiving. Session recordings that have been archived might still be played if the files have not been moved. If a session recording file was moved during archiving, a file not found error is displayed. The session recording file must be restored before the session can be played. To restore a session recording, provide the administrator with the File ID and Archive Time of the session recording from the recording Properties dialog box in the Session Recording Player. Restoring archived files is discussed further in the following Restore session recording files section.

The archive command of the ICLDB utility has several parameters that are described as follows:

  • /RETENTION:<days> - The retention period in days for session recordings. Recordings older than the number of days specified are marked as archived in the Session Recording Database. The retention period must be an integer number greater than or equal to 2 days.

  • /LISTFILES – Lists the full path and file name of session recording files as they are being archived. This parameter is optional.

  • /MOVETO:<directory> - The directory to which you physically move archived session recording files. The specified directory must exist. This parameter is optional. If no directory is specified, files remain in their original storage location.

  • /NOTE:<note> - A text note that is added to the database record for each session recording archived. Ensure that the note is enclosed with double quotes. This parameter is optional.

  • /L – Logs the results and errors to the Windows event log of the number of session recording files archived. This parameter is optional.

  • /F – Forces the archive command to run without prompts. This parameter is optional.

To archive session recordings in the Session Recording Database and physically move session recording files

  1. Log on to the server where the Session Recording Server is installed as a local administrator.

  2. Start a command prompt.

  3. Change from the current working directory to the Bin directory of the Session Recording Server installation path (<Session Recording Server Installation Path>/Server/Bin).

  4. Run the ICLDB ARCHIVE /RETENTION:<days> /LISTFILES /MOVETO:<directory> /NOTE:<note> /L command where days is the retention period for session recording files, directory is the directory where archived session recording files are moved to, and note is the text note that is added to the database record for each session recording file being archived. Enter Y to confirm the archive.

To only archive session recordings in the Session Recording Database

  1. Log on to the server where the Session Recording Server is installed as a local administrator.

  2. Start a command prompt.

  3. Change from the current working directory to the Bin directory of the Session Recording Server installation path (<Session Recording Server Installation Path>/Server/Bin).

  4. Run the ICLDB ARCHIVE /RETENTION:<days> /LISTFILES /NOTE:<note> /L command where days is the retention period for session recordings and note is the text note that is added to the database record for each session recording being archived. Enter Y to confirm the archive.

Restore session recording files

Restoration of session recording files is required when you want to view a session recording that was archived in the Session Recording Database and the file has been moved from the recording storage location. Archived session recordings that were not moved from the recording storage location during archiving are still accessible in the Session Recording Player.

Two methods are available for restoring session recording files that have been moved. Copy the required session recording file to the restore directory for archived files, or import the required session recording file back to the Session Recording Database by using the ICLDB utility. Citrix recommends the first method for restoring archived session recording files. Remove archived files copied to the restore directory for archived files when you no longer need them.

The Session Recording Broker utilizes the Restore directory for archived files when a session recording file is not found in its original storage location. This case occurs when the Session Recording Player requests a session recording file for playback. The Session Recording Broker first attempts to find the session recording file in the original storage location. If the file is not found in the original storage location, the Session Recording Broker then checks the Restore directory for archived files. If the file is present in the restore directory, the Session Recording Broker sends the file to the Session Recording Player for playback. Otherwise, if the file is not found, the Session Recording Broker sends a file not found error to the Session Recording Player.

Importing archived session recording files by using the ICLDB utility updates the Session Recording Database with session recording information from the session recording file, including a new storage path for the session recording file. Using the ICLDB utility to import an archived session recording file does not move the file back to the original storage location when the session was recorded.

Note: An imported session recording file has the archive time and archive note cleared in the Session Recording Database. Therefore, the next time the ICLDB archive command is run, the imported session recording file might become archived again.

The ICLDB import command is useful to import a large number of archived session recording files, repair, or update incorrect and missing session recording data in the Session Recording Database, or move session recording files from one storage location to another storage location on the Session Recording Server. The ICLDB import command can also be used to repopulate the Session Recording Database with session recordings after running the ICLDB removeall command.

The import command of the ICLDB utility has several parameters that are described as follows:

  • /LISTFILES – Lists the full path and file name of session recording files while they are being imported. This parameter is optional.

  • /RECURSIVE – Searches all subdirectories for session recording files. This parameter is optional.

  • /L – Logs the results and errors to the Windows event log the number of session recording files imported. This parameter is optional.

  • /F – Forces the import command to run without prompts. This parameter is optional.

To restore session recording files by using the restore directory for archived files

  1. Log on to the server where the Session Recording Server is installed as a local administrator.

  2. In Session Recording Player Properties, determine the File ID and Archive Time of the archived session recording file.

  3. Locate the session recording file in your backups using the File ID specified in Session Recording Player Properties. Each session recording has a file name of i_<FileID>.icl, where FileID is the ID of the session recording file.

  4. Copy the session recording file from your backup to the restore directory for archived files. To determine the restore directory for archived files:

    1. From the Start menu, choose Start > All Programs > Citrix > Session Recording Server Properties.

    2. In Session Recording Server Properties, select the Storage tab. The current restore directory appears in the Restore directory for archived files field.

To restore session recording files by using the ICLDB import command

  1. Log on to the server where the Session Recording Server is installed as a local administrator.

  2. Start a command prompt.

  3. Change from the current working directory to the Bin directory of the Session Recording Server installation path (<Session Recording Server Installation Path>/Server/Bin).

  4. Either:

    • Run the ICLDB IMPORT /LISTFILES /RECURSIVE /L <directory> command where directory is the name of one or more directories, separated by a space containing session recording files. Enter Y to confirm the import.

    • Run the ICLDB IMPORT /LISTFILES /L <file> command where file is the name of one or more session recording files, separated by a space. Wildcards might be used to specify session recording files. Enter Y to confirm the import.

Manage your database records