- 在以下服务器之一上运行 build_dsainputs,具体取决于使用的 DSA 配置:
DSA 配置 服务器 捆绑 DSA Data Mover 服务器 外部 DSA 外部 DSC 服务器 将 build_dsainputs 脚本复制到外部 DSC 服务器并从那里运行。该脚本可以复制到任何目录并从任何目录运行。
- 使用 build_dsainputs 工具为 TPA 节点创建一个 dsainputs 文件。build_dsainputs 工具可为 SMP 和 MPP 数据库创建 /tmp/dsainputs 文件。如果使用 -u 选项指定对 /tmp 目录具有写入访问权限的用户,则该工具可以选择将文件传输到 TPA 节点。此外,还可以使用 -i 选项指定包含私钥的标识文件。以下示例显示了在未提供任何参数的情况下运行 build_dsainputs 时的输出:
build_dsainputs -d [-t] | -m <media_server_hostname>[,<media_server_hostname>...] | [-i <identity_file> -u <userid>] | [-u <userid>] | -h Parameters: -d Creates a /tmp/dsainputs file for the DSC server. -m <ms_hostname>[,<ms_hostname>...] Creates /tmp/dsainputs file(s) for a media server. Run this script one time for each Teradata system. Specify one host for an SMP System or a comma separated list for an MPP System. You may also specify a range of hostnames using <ms_hostname>[##-##] syntax. Creates a /tmp/dsainputs.<media_server_hostname> file for each host in the list. The /tmp/dsainputs files must be copied to their corresponding host before installing the ClientHandler rpm. Examples: 1) build_dsainputs -m devsys Creates /tmp/dsainputs.devsys for SMP system 'devsys'. Copy this file to the corresponding database host and rename to /tmp/dsainputs before installing the ClientHandler rpm. 2) build_dsainputs -m kiwi1,kiwi2 Creates dsainputs files for a 2-node MPP system with hosts kiwi1 and kiwi2. The following files are created: /tmp/dsainputs.kiwi1 /tmp/dsainputs.kiwi2 Copy these files to the corresponding database hosts (rename to /tmp/dsainputs) before installing the ClientHandler rpm. 3) build_dsainputs -m cucumber[1-3],onion1,tomato[12-13] /tmp/dsainputs.cucumber1 /tmp/dsainputs.cucumber2 /tmp/dsainputs.cucumber3 /tmp/dsainputs.onion1 /tmp/dsainputs.tomato12 /tmp/dsainputs.tomato13 Copy these files to the corresponding database hosts (rename to /tmp/dsainputs) before installing the ClientHandler rpm. -i <identity_file> (Optional) When used with the -m option this specifies the identify_file (that contains the private key) that will be used along with the userid (provided with the -u option) to scp the /tmp/dsainputs(s) files to their respective hosts. The -u option must be provided when the -i option is included. Example: build_dsainputs -m kiwi1,kiwi2 -i ./my_identity_file -u ec2-user -u <userid> (Optional) When used with the -m option this specifies the userid that will be used to scp the /tmp/dsainputs(s) files to their respective host(s). Note that if you are using this without the -i option and password-less SSH is not configured, you will be prompted for a password for each file transfer. Example: build_dsainputs -m kiwi1,kiwi2 -u root -t (Optional) Must be used with -d option to generate the DSA input file. If specified, Teradata-specific parameters are added to /tmp/dsainputs. If not specified, PostgreSQL parameters are added instead. -h Displays usage help.
以下示例显示了针对 4 节点 MPP 系统运行 build_dsainputs。已提供 -u 选项,用于将文件传输到单个 TPA 节点:# ./build_dsainputs -m kiwi1,kiwi2,kiwi3,kiwi4 -u root Generating /tmp/dsainputs.kiwi1 - copy this file to /tmp/dsainputs on kiwi1 before installing the ClientHandler rpm. Generating /tmp/dsainputs.kiwi2 - copy this file to /tmp/dsainputs on kiwi2 before installing the ClientHandler rpm. Generating /tmp/dsainputs.kiwi3 - copy this file to /tmp/dsainputs on kiwi3 before installing the ClientHandler rpm. Generating /tmp/dsainputs.kiwi4 - copy this file to /tmp/dsainputs on kiwi4 before installing the ClientHandler rpm. Transferring /tmp/dsainputs file to kiwi1. dsainputs.kiwi1 100% 349 0.3KB/s 00:00 Transferring /tmp/dsainputs file to kiwi2. dsainputs.kiwi2 100% 348 0.3KB/s 00:00 Transferring /tmp/dsainputs file to kiwi3. dsainputs.kiwi3 100% 348 0.3KB/s 00:00 Transferring /tmp/dsainputs file to kiwi4. dsainputs.kiwi4
- 对于 MPP 系统,媒体服务器中列出的具有 -m 选项的节点必须解析为可从每个 MPP TPA 节点访问的 IP。
- 在 SMP 系统上运行该工具时,仅显示一条文件生成和传输消息。
- 在 TPA 节点上安装 DSA ClientHandler RPM。有关详细信息,请参阅《Teradata® Data Stream Utility 安装、配置和升级指南,B035-3153》。如果在命令行上安装 clienthandler,而不是使用 PUT,请使用 rpm -ivh ClientHandler*.rpm 命令,而不是捆绑的脚本。如果在命令行上使用捆绑的 clienthandler_install.sh 脚本,/tmp/dsainputs 属性设置将被覆盖,您必须使用 rpm -e 移除 ClientHandler,然后重新执行步骤 1,为 TPA 节点创建 dsainputs 文件。
- 执行以下步骤以在 BAR NC TPA 节点上更新操作系统:
- 调整运行 BAR NC 的 TPA 节点上的以下操作系统可调参数:
net.ipv4.tcp_max_syn_backlog to 16384 (default 2048) net.core.somaxconn to 16384 (default 128)
- 在 TPA 节点上运行以下命令,以立即加入这些更改:
# echo 16384 > /proc/sys/net/core/somaxconn # echo 16384 > /proc/sys/net/ipv4/tcp_max_syn_backlog
- 在这些 TPA 节点上重新启动 ClientHandler:
# /etc/init.d/clienthandler restart
- 使用以下值修改 sysctl.conf,以使这些值在启动时得以保留:
net.core.somaxconn=16384 net.ipv4.tcp_max_syn_backlog=16384
Teradata 建议加入这些更改,以避免 DSMain 和 BAR NC 之间的网络通信出现问题。有关详细信息,请参阅 KB0016835。
- 调整运行 BAR NC 的 TPA 节点上的以下操作系统可调参数: