File: //snap/google-cloud-cli/396/help/man/man1/gcloud_compute_tpus_queued-resources_scp.1
.TH "GCLOUD_COMPUTE_TPUS_QUEUED\-RESOURCES_SCP" 1
.SH "NAME"
.HP
gcloud compute tpus queued\-resources scp \- copy files to and from a Cloud TPU Queued Resource via SCP
.SH "SYNOPSIS"
.HP
\f5gcloud compute tpus queued\-resources scp\fR [[\fIUSER\fR@]\fIINSTANCE\fR:]\fISRC\fR [[[\fIUSER\fR@]\fIINSTANCE\fR:]\fISRC\fR\ ...] [[\fIUSER\fR@]\fIINSTANCE\fR:]\fIDEST\fR [\fB\-\-batch\-size\fR=\fIBATCH_SIZE\fR;\ default=64] [\fB\-\-compress\fR] [\fB\-\-dry\-run\fR] [\fB\-\-force\-key\-file\-overwrite\fR] [\fB\-\-node\fR=\fINODE\fR;\ default="0"] [\fB\-\-plain\fR] [\fB\-\-recurse\fR] [\fB\-\-scp\-flag\fR=\fISCP_FLAG\fR] [\fB\-\-ssh\-key\-file\fR=\fISSH_KEY_FILE\fR] [\fB\-\-strict\-host\-key\-checking\fR=\fISTRICT_HOST_KEY_CHECKING\fR] [\fB\-\-worker\fR=\fIWORKER\fR;\ default="0"] [\fB\-\-zone\fR=\fIZONE\fR] [\fB\-\-internal\-ip\fR\ |\ \fB\-\-tunnel\-through\-iap\fR] [\fB\-\-ssh\-key\-expiration\fR=\fISSH_KEY_EXPIRATION\fR\ |\ \fB\-\-ssh\-key\-expire\-after\fR=\fISSH_KEY_EXPIRE_AFTER\fR] [\fIGCLOUD_WIDE_FLAG\ ...\fR]
.SH "DESCRIPTION"
Copy files to and from a Cloud TPU Queued Resource via SCP.
.SH "EXAMPLES"
To copy a file (for example, a text file in the local home directory) to a Cloud
Queued Resource, run:
.RS 2m
$ gcloud compute tpus queued\-resources scp ~/my\-file my\-qr:
.RE
To copy a file into all nodes and workers in a Cloud TPU Queued Resource (with
the default batch size), run:
.RS 2m
$ gcloud compute tpus queued\-resources scp ~/my\-file my\-qr: \e
\-\-worker=all \-\-node=all
.RE
To copy a file into all nodes and workers in a Cloud TPU Queued Resource with a
batch size of 4, run:
.RS 2m
$ gcloud compute tpus queued\-resources scp ~/my\-file my\-qr: \e
\-\-worker=all \-\-node=all \-\-batch\-size=4
.RE
To copy a file into all workers in the first node of a Cloud TPU Queued
Resource, run:
.RS 2m
$ gcloud compute tpus queued\-resources scp ~/my\-file my\-qr: \e
\-\-worker=all
.RE
To copy a file from a Cloud TPU Queued Resource to the home directory of the
local computer, run:
.RS 2m
$ gcloud compute tpus queued\-resources scp my\-qr:~/my\-file ~/
.RE
To copy all files in a folder to a Cloud TPU Queued Resource, run:
.RS 2m
$ gcloud compute tpus queued\-resources scp ~/my\-folder/ my\-qr: \e
\-\-recurse
.RE
.SH "POSITIONAL ARGUMENTS"
.RS 2m
.TP 2m
[[\fIUSER\fR@]\fIINSTANCE\fR:]\fISRC\fR [[[\fIUSER\fR@]\fIINSTANCE\fR:]\fISRC\fR ...]
Specifies the files to copy.
.TP 2m
[[\fIUSER\fR@]\fIINSTANCE\fR:]\fIDEST\fR
Specifies a destination for the source files.
.RE
.sp
.SH "FLAGS"
.RS 2m
.TP 2m
\fB\-\-batch\-size\fR=\fIBATCH_SIZE\fR; default=64
Batch size for simultaneous command execution on the client's side. When using a
comma\-separated list (e.g. '1,4,6') or a range (e.g. '1\-3') or ``all`` keyword
in \f5\-\-worker\fR flag, it executes the command concurrently in groups of the
batch size. This flag takes a value greater than 0 to specify the batch size to
control the concurrent connections that can be established with the TPU workers,
or the special keyword ``all`` to allow the concurrent command executions on all
the specified workers in \f5\-\-worker\fR flag. Maximum value of this flag
should not be more than the number of specified workers, otherwise the value
will be treated as ``\-\-batch\-size=all``.
.TP 2m
\fB\-\-compress\fR
Enable compression.
.TP 2m
\fB\-\-dry\-run\fR
Print the equivalent scp/ssh command that would be run to stdout, instead of
executing it.
.TP 2m
\fB\-\-force\-key\-file\-overwrite\fR
If enabled, the gcloud command\-line tool will regenerate and overwrite the
files associated with a broken SSH key without asking for confirmation in both
interactive and non\-interactive environments.
If disabled, the files associated with a broken SSH key will not be regenerated
and will fail in both interactive and non\-interactive environments.
.TP 2m
\fB\-\-node\fR=\fINODE\fR; default="0"
TPU node(s) to connect to. The supported value is a single 0\-based index of the
node(s) in the case of a TPU Pod. It additionally supports a comma\-separated
list (e.g. '1,4,6'), range (e.g. '1\-3'), or special keyword ``all" to run the
command concurrently on each of the specified node(s).
Note that when targeting multiple nodes, you should run 'ssh\-add' with your
private key prior to executing the gcloud command. Default: 'ssh\-add
~/.ssh/google_compute_engine'.
.TP 2m
\fB\-\-plain\fR
Suppress the automatic addition of \fBssh(1)\fR/\fBscp(1)\fR flags. This flag is
useful if you want to take care of authentication yourself or use specific
ssh/scp features.
.TP 2m
\fB\-\-recurse\fR
Upload directories recursively.
.TP 2m
\fB\-\-scp\-flag\fR=\fISCP_FLAG\fR
Additional flags to be passed to \fBscp(1)\fR. This flag may be repeated.
.TP 2m
\fB\-\-ssh\-key\-file\fR=\fISSH_KEY_FILE\fR
The path to the SSH key file. By default, this is
\f5\fI~/.ssh/google_compute_engine\fR\fR.
.TP 2m
\fB\-\-strict\-host\-key\-checking\fR=\fISTRICT_HOST_KEY_CHECKING\fR
Override the default behavior of StrictHostKeyChecking for the connection. By
default, StrictHostKeyChecking is set to 'no' the first time you connect to an
instance, and will be set to 'yes' for all subsequent connections.
\fISTRICT_HOST_KEY_CHECKING\fR must be one of: \fByes\fR, \fBno\fR, \fBask\fR.
.TP 2m
\fB\-\-worker\fR=\fIWORKER\fR; default="0"
TPU worker to connect to. The supported value is a single 0\-based index of the
worker in the case of a TPU Pod. When also using the \f5\-\-command\fR flag, it
additionally supports a comma\-separated list (e.g. '1,4,6'), range (e.g.
\'1\-3'), or special keyword ``all" to run the command concurrently on each of
the specified workers.
Note that when targeting multiple workers, you should run 'ssh\-add' with your
private key prior to executing the gcloud command. Default: 'ssh\-add
~/.ssh/google_compute_engine'.
.TP 2m
\fB\-\-zone\fR=\fIZONE\fR
Zone of the tpu to scp. If not specified and the \f5\fIcompute/zone\fR\fR
property isn't set, you might be prompted to select a zone (interactive mode
only).
To avoid prompting when this flag is omitted, you can set the
\f5\fIcompute/zone\fR\fR property:
.RS 2m
$ gcloud config set compute/zone ZONE
.RE
A list of zones can be fetched by running:
.RS 2m
$ gcloud compute zones list
.RE
To unset the property, run:
.RS 2m
$ gcloud config unset compute/zone
.RE
Alternatively, the zone can be stored in the environment variable
\f5\fICLOUDSDK_COMPUTE_ZONE\fR\fR.
.TP 2m
At most one of these can be specified:
.RS 2m
.TP 2m
\fB\-\-internal\-ip\fR
Connect to TPU VMs using their internal IP addresses rather than their external
IP addresses. Use this to connect from a Google Compute Engine VM to a TPU VM on
the same VPC network, or between two peered VPC networks.
.TP 2m
\fB\-\-tunnel\-through\-iap\fR
Tunnel the SSH connection through Cloud Identity\-Aware Proxy for TCP
forwarding.
This flag must be specified to attempt to connect via IAP tunneling. If it is
not set, and connection to a Cloud TPU VM without external IP address is
attempted from outside the network, then the command will fail.
To use IAP tunneling, there must be firewall access to the SSH port for the IAP
TCP IP address range for the network the TPU is created in. See the user guide
(https://cloud.google.com/iap/docs/using\-tcp\-forwarding) for more details.
To learn more, see the IAP for TCP forwarding documentation
(https://cloud.google.com/iap/docs/tcp\-forwarding\-overview).
.RE
.sp
.TP 2m
At most one of these can be specified:
.RS 2m
.TP 2m
\fB\-\-ssh\-key\-expiration\fR=\fISSH_KEY_EXPIRATION\fR
The time when the ssh key will be valid until, such as
"2017\-08\-29T18:52:51.142Z." This is only valid if the instance is not using OS
Login. See $ gcloud topic datetimes for information on time formats.
.TP 2m
\fB\-\-ssh\-key\-expire\-after\fR=\fISSH_KEY_EXPIRE_AFTER\fR
The maximum length of time an SSH key is valid for once created and installed,
e.g. 2m for 2 minutes. See $ gcloud topic datetimes for information on duration
formats.
.RE
.RE
.sp
.SH "GCLOUD WIDE FLAGS"
These flags are available to all commands: \-\-access\-token\-file, \-\-account,
\-\-billing\-project, \-\-configuration, \-\-flags\-file, \-\-flatten,
\-\-format, \-\-help, \-\-impersonate\-service\-account, \-\-log\-http,
\-\-project, \-\-quiet, \-\-trace\-token, \-\-user\-output\-enabled,
\-\-verbosity.
Run \fB$ gcloud help\fR for details.
.SH "NOTES"
This variant is also available:
.RS 2m
$ gcloud alpha compute tpus queued\-resources scp
.RE