Configuring the OpenSSH client
The OpenSSH daemon (sshd) can understand and handle non-Latin-1 coded character sets for interactive sessions, specifically those with a tty allocated. However, the OpenSSH client (ssh) still expects network data to be encoded in ISO 8859-1.
If the EBCDIC coded character set for your sessions is compatible with ISO 8859-1, the following setup is not required. To determine if a coded character set is compatible with a particular locale, refer to the section on locales supplied with z/OS XL C/C++ in z/OS XL C/C++ Programming Guide.
If chcp is issued in your environment, verify that the SSH peer supports the specified ASCII coded character set.
For example, if you are using a PC to connect directly to z/OS®, you issue the chcp command in the remote z/OS shell to assign the ASCII-coded character set for the terminal to match that of the PC emulator. The daemon inherits the chcp setting to translate the network data accordingly. The SSH peer, the PC emulator, must also support the new ASCII coded character set. This can be determined by checking your emulator's configuration.
If you are issuing the ssh client from z/OS to connect to a z/OS platform running in another locale, you need to verify that the ASCII coded character set of the remote session (set by chcp) is ISO 8859-1, which is what the z/OS ssh client expects.
Warning: If there is no one-to-one mapping between the EBCDIC coded character set of the session data and ISO 8859-1, then nonidentical conversions might occur. Specifically, substitution characters (for example, IBM-1047 0x3F) may be inserted into the data stream for those incompatible characters.
- You are running in the target locale when issuing the ssh command locally.
- You are running in the target locale in your remote ssh session.
To avoid nonidentical conversions, you can force the ssh client process to run in the C locale. Note also that the remote session's shell must also be configured to run in either the C locale or a locale with a coded character set that is compatible with ISO 8859-1.
LC_ALL=C ssh [arguments]
where arguments represents the
remainder of the arguments passed to ssh. alias ssh="LC_ALL=C ssh"