docker_remote command for IBM® Db2 Warehouse
Enables you to invoke a Docker command so that it executes on one or more Db2® Warehouse remote nodes.
As a user with host operating system root authority, issue the command as follows:
docker_remote -n|--node {"remote_node1[,...,remote_nodeN]"|$hosts} -c|--command "docker_command" [-h|--help]
- -n|--node "remote_node1[,...,remote_nodeN]"|"$shell_variable"
- Specifies one or more remote nodes. You can specify the nodes in two ways:
- By providing a comma-separated list of remote nodes directly after the parameter. Enclose the list in double quotation marks (" ").
- By setting a shell variable to a comma-separated list of remote nodes and providing the variable after the parameter. Enclose the variable in double quotation marks.
- -c|--command "docker_command"
- Specifies a Docker command to execute on the remote node or nodes.
- -h|--help
- Displays help for the docker_remote command.
Examples
- The following command executes the docker ps -a command on the remote node
myhost.mydomain.com:
docker_remote --node "myhost.mydomain.com" --command "ps -a"
- The following command executes the docker ps -a command on the remote nodes
myhost1.mydomain.com, myhost2.mydomain.com, and
myhost3.mydomain.com:
docker_remote --node "myhost1.mydomain.com, myhost2.mydomain.com, myhost3.mydomain.com" --command "ps -a"
- In the following example, the hosts shell variable is set to a
comma-separated list of remote nodes and then used as the value of the --node
parameter:
hosts="myhost1,myhost2,myhost3" docker_remote --node "$hosts" --command "ps -a"