Dovetailed Technologies

Appendix F. Windows Desktop Target System Installation

These installation instructions are for Windows Desktop (e.g. non server) environments. They are written for Windows 7, but should work with minor variations on other recent versions.

The distribution .zip file for Co:Z includes pre-built binaries for 32-bit Windows systems. The Windows machine must also have OpenSSH installed, which is available as part of the free Cygwin environment.

Note: Exercise caution when editing text files in the Cygwin distribution, especially shell scripts. Make sure that you use an editor that recognizes and preserves the unix line end characters. Wordpad will work in a pinch, but Notepad will not. If you are comfortable with Unix editors, you can include the vim (vi) package when you install Cygwin.

F.1 Install Cygwin and OpenSSH on Windows

These instructions supplement the information available on the Cygwin website, and must be run under a Windows user with administrator privileges.

  1. Download and excute the Cygwin setup.exe installation wizard

  2. Accept the default wizard selections, except where changes are necessary (e.g. "Select Your Internet Connection")

  3. After choosing a Download Site, the available packages are listed. Expand the Net node in the package list and click on the Skip: icon next to the package openssh. This will cause the openssh and openssl packages to be selected for installation.

  4. (Optional) Expand the "Editors" node in the package list and select the vim package if you would like to edit with vi.

  5. Wait for the installation to complete. This may take some time depending on the speed of your internet connection.

  6. Open a shell: Start+Programs+Cygwin+Cygwin Bash Shell. NOTE: This shell must be run as Administrator.

F.2 Configure and test sshd

  1. Once Cygwin is installed, setting up sshd is simply the matter of running the script ssh-host-config from the shell opened in the previous step. Recommended user responses are included below:

    win$ ssh-host-config
    Generating /etc/ssh_host_key
    Generating /etc/ssh_host_rsa_key
    Generating /etc/ssh_host_dsa_key
    Generating /etc/ssh_config file
    Privilege separation is set to yes by default since OpenSSH 3.3.
    However, this requires a non-privileged account called 'sshd'.
    For more info on privilege separation read 
    /usr/share/doc/openssh/README.privsep.
    
    Should privilege separation be used? (yes/no) yes
    Warning: The following function requires administrator privileges!
    Should this script create a local user 'sshd' on this machine? (yes/no) yes
    Generating /etc/sshd_config file
    
    
    Warning: The following functions require administrator privileges!
    
    Do you want to install sshd as service?
    (Say "no" if it's already installed as service) (yes/no) yes
    
    Which value should the environment variable CYGWIN have when
    sshd starts? It's recommended to set at least "ntsec" to be
    able to change user context without password.
    Default is "ntsec".  CYGWIN=(Enter)
    
    The service has been installed under LocalSystem account.
    To start the service, call `net start sshd' or `cygrunsrv -S sshd'.
    
    Host configuration finished. Have fun!
              

    More information on setting up OpenSSH under Cygwin are available in the /usr/share/doc/openssh/README file under the Cygwin home directory.

    Note: If you wish to have sshd listen on a port other than the default (22) edit the file /etc/sshd_config and change the Port 22 line to reflect the desired port. With Vista, you will need to change the file permissions to do this as the file is owned by a different user id. Be sure to revert the permissions after editing.

  2. Start sshd by running cygrunsrv:

    win$ cygrunsrv -S sshd
    win$ ps -eaf
          UID     PID    PPID TTY     STIME COMMAND
      sgoetze    2644       1 con  16:28:32 /usr/bin/bash
       SYSTEM    4012       1   ?  16:30:53 /usr/bin/cygrunsrv
       SYSTEM     868    4012   ?  16:30:53 /usr/sbin/sshd
      sgoetze    1664    2644 con  16:30:58 /usr/bin/ps
              
  3. Test Cygwin ssh locally:

    [Note]Note

    When you supply the Windows userid, it must match the case of the actual id on your Windows system.

    win$ ssh <userid>@localhost
    The authenticity of host 'localhost (127.0.0.1)' can't be established.
    RSA key fingerprint is cc:7c:3d:b5:3e:43:5a:6f:12:e2:1a:af:80:45:ae:fa.
    Are you sure you want to continue connecting (yes/no)? yes
    Warning: Permanently added 'localhost' (RSA) to the list of known hosts.
    <userid>@localhost's password:
    
    win$ logout
    Connection to localhost closed.
              
  4. Test Cygwin ssh from z/OS:

    Repeat the above test from your z/OS userid to confirm that there are no firewall issues.

    ZOS$ ssh -p <port> <userid>@windows_host

F.3 Install Co:Z target executables

  1. Download Co:Z for Windows from the downloads page.

  2. From a Cygwin bash shell, create the directory /opt if it doesn't exist.

  3. Extract the contents of the distribution .zip file to the /opt directory.

  4. Ensure that the files in /opt/dovetail/coz/bin are marked executable:

    $ cd /opt/dovetail/coz/bin
    $ chmod +x cozagent cozclient fromdsn todsn
              
  5. Add {CYGWIN_HOME}/opt/dovetail/coz/bin to your Windows PATH environment variable and ensure that {CYGWIN_HOME}/bin is also present.

Copyright© 2009-2017 Dovetailed Technologies, LLC. All rights reserved.
Co:Z® is a registered trademark of Dovetailed Technologies, LLC.