Troubleshooting
Problem
The Netezza replication environment, Persistent Transport System (henceforth referred to as PTS) stores transaction log files containing SQL statement execution, load file data, replication metadata, and other information. Software on the PTS copies files from master node’s PTS (henceforth referred to as master PTS) to the subordinate node’s PTS host (henceforth referred to as subordinate PTS).
Master PTS transfers files to the subordinate PTS(s) serially and in uncompressed format. Transaction log files for big queries can be very large in size and transferring such large size files between PTSs is a time-consuming process.
Resolving The Problem
IBM PureData for Analytics (referred to as Netezza) software release 7.2.1.6-P2 introduces feature that compresses data on master PTS before sending and decompresses it on subordinate PTS on receiving it from the network.
Master PTS uses multiple threads to read, compress and send data chunks to the subordinate PTS. On the subordinate PTS, multiple threads read the compressed data from the network interface, decompress the data and write them to the file system.
Feature behavior:
Since Netezza software version 7.2.1.6-P2, compression and parallelism are controlled using the ptsconfigure command on the master PTS node. It is necessary to send a SIGHUP signal to the PTS process for parameter changes to take effect. Alternatively, ptsd daemon on the PTS host can be restarted for the changes to take effect.
Example:
kill -n SIGHUP <pid>
OR
service ptsd restart
Following section describes configuration and description about configurable parameters.
COMPRESSION_LEVEL – This parameter enables or disables on-the-fly compression and sets the compression aggressiveness level. Valid values are from 0 to 9; the default value is 0.
Compression Level Effect
------------------------
0 Compression is disabled
1 Lowest degree of compression, lowest CPU cost
-----------
2-8 Intermediate compression levels.
-----------
9 Highest degree of compression, highest CPU cost
COMPRESSION_THREADS – This parameter sets the number of read-and-compress worker threads. Each compressor thread reads from the filesystem, compresses data and enqueues compressed chunks for sending. Valid values are from 1 to 64. The default setting is 4 threads. Compressor threads are only used when compression is enabled (COMPRESSION_LEVEL > 0) or SENDER_THREADS > 1. Increasing the number of compressor threads might be necessary on a multi-core system where there is not enough CPU bandwidth per core to compress data at the rate that the network can consume it. Current PTS systems should have ample CPU power for
this purpose and it should not be necessary to modify this setting from the default value.
SENDER_THREADS – This parameter sets the number of sender worker threads. Each sender thread writes compressed chunks over a TCP connection to a corresponding receiver thread on the subordinate PTS node. When compression is disabled (COMPRESSION_LEVEL = 0) and SENDER_THREADS is 1, PTS operates in the standard single-threaded mode. Sender threads
are used when COMPRESSION_LEVEL > 0 or SENDER_THREADS >= 2. Valid values are from 1 to 64, and the default value is 1.
Each sender thread requires a dedicated TCP port, and the port numbers are consecutive starting after the PTS main port number. For example, if PTS is using the default TCP port number 52573, sender threads would use ports 52574, 52575 and so forth.
Compression ratio information and PTS transfer rate is available in the PTS Receiver log file: /opt/ibm/nzpts/logs/receiver.log
· Enable feature:
Customers can enable the feature with setting the level of compression, number of sender & compression threads on master PTS:
# enable compression using one worker thread
ptsconfigure -param COMPRESSION_LEVEL=9,SENDER_THREADS=1
# enable compression using four worker threads
ptsconfigure -param COMPRESSION_LEVEL=9,SENDER_THREADS=4
· Disable feature:
By default, this new feature is disabled.
If the feature has been enabled, it can be disabled with following command on master PTS.
ptsconfigure -param COMPRESSION_LEVEL=0,SENDER_THREADS=1,COMPRESSOR_THREADS=0
Set the parameters (compression level, compression threads, sender threads) to enable or disable the feature on master PTS only. Nothing should be set on subordinate PTS.
Performance Results:
The following measurements were observed for file transfer from master PTS to subordinate PTS. The measurements were observed for a single file (data volume range: 5 GB to 1 TB)
Time taken for data transfer (in seconds)
Data in GB Feature enabled Feature disabled % improvement

Observations:
1. We could observe upto 45% improvement in data transfer rate. However, this is subjective to the type of data (how compressible the data is), network characteristics (network bandwidth, latency etc.)
2. Customers may not see expected improvement for smaller sized data files (upto 10-15 GB). For significant (more than 50GB) volume of data, the improvement is observed consistently.
3. The improvement can be consistently observed in case of large data loads or large by value transactions.
CAVEATS WHEN FEATURE IS ENABLED
CAVEATS WHEN FEATURE IS DISABLED
NOTE:
Since 7.2.1.6-P2, although master and subordinate NPS can still run different software versions, it is recommended as best practice that both master and subordinate NPS should run versions 7.2.1.6-P2 or later.
After 7.2.1.6-P2, due to above mentioned feature, if master and subordinate NPS have to run different versions; one on 7.2.1.6-P2 or later and another on 7.2.1.6 or lower; both PTSs still need to be on version 7.2.1.6-P2 or later. In such case, manual steps are required after every upgrade for such setup to work. Please refer <link for tech note on ptsrelaxversion> for more information.
Product Synonym
NPS Netezza Performance Server PureData for Anayltics PDA
Was this topic helpful?
Document Information
Modified date:
17 October 2019
UID
ibm10717321