tsh ssh <user@hostname>

Run shell or execute a command on a remote SSH node

Arguments

NameDescription
user@hostnameAddress of remote machine to log into

Options

NameDescription
-1Forces ssh to try protocol version 1 only
-2Forces ssh to try protocol version 2 only
-4Forces ssh to use IPv4 addresses only
-6Forces ssh to use IPv6 addresses only
-AEnables forwarding of the authentication agent connection
-aDisables forwarding of the authentication agent connection
-b <bind address>Use bind_address on the local machine as the source address of the connection
-CRequests compression of all data (including stdin, stdout, stderr, and data for forwarded X11 and TCP connections)
-c <cipher spec>Selects the cipher specification for encrypting the session
-D <port>Specifies a local 'dynamic' application-level port forwarding
-e <escape char>Sets the escape character for sessions with a pty (default: '~')
-F <configfile>Specifies an alternative per-user configuration file
-fRequests ssh to go to background just before command execution
-gAllows remote hosts to connect to local forwarded ports
-I <pkcs11>Specify the PKCS#11 shared library ssh should use to communicate with a PKCS#11 token providing the user's private RSA key
-i <identity file>
  • Repeatable ♾
-KEnables GSSAPI-based authentication and forwarding (delegation) of GSSAPI credentials to the server
-kDisables forwarding (delegation) of GSSAPI credentials to the server
-L <port:host:hostport>Specifies that the given port on the local (client) host is to be forwarded to the given host and port on the remote side
-l <login name>Specifies the user to log in as on the remote machine
-M
  • Repeatable ♾
-m <mac spec>Additionally, for protocol version 2 a comma-separated list of MAC (message authentication code) algorithms can be specified in order of preference
-NDo not execute a remote command
-nRedirects stdin from /dev/null (actually, prevents reading from stdin)
-O <ctl cmd>Control an active connection multiplexing master process
-o <option>
  • Repeatable ♾
-p <port>Port to connect to on the remote host
-qQuiet mode. Causes most warning and diagnostic messages to be suppressed
-R <port:host:hostport>Specifies that the given port on the remote (server) host is to be forwarded to the given host and port on the local side
-S <ctl_path>Specifies the location of a control socket for connection sharing, or the string 'none' to disable connection sharing
-sMay be used to request invocation of a subsystem on the remote system
-TDisable pseudo-tty allocation
-t
  • Repeatable ♾
-VDisplay the version number and exit
-v
  • Repeatable ♾
  • Repeatable 3x
-W <host:port>Requests that standard input and output on the client be forwarded to host on port over the secure channel
-w <local tun>Requests tunnel device forwarding with the specified tun(4) devices between the client (local_tun) and the server (remote_tun)
-XEnables X11 forwarding
-xDisables X11 forwarding
-YEnables trusted X11 forwarding
-ySend log information using the syslog(3) system module