So... this was a difficult one to figure out! You may be better off using Windows Subsystem for Linux + Bash + Virt-Manager if you can get it, but it wasn't available for my version of Windows (LTSB).
Video! >> https://www.youtube.com/watch?v=gDEAu3oPcR0
The short version of the story is:
- Install CygWin w/ virt-manager, xinit and openssh
Configure PWDless SSH via RSA Key to KVM Host
Note: If you place your private key inside ~/.ssh/id_rsa and make sure permissions are the following SSH will automatically try using the Private Key. To create the directory .ssh with proper permissions and create the "known_hosts" file, I ususally SSH into KVM Host and accept the host-key fingerprint manually. Then move over the Private Key and test ssh'ing into KVM Host. It shouldn't ask you for your password and just auto-login.chmod 400 ~/.ssh/id_rsa
Default Username is "YouLoginName" and in windows, you can copy the file manually to the default location via
C:\cygwin64\home\YouLoginName\.ssh\id_rsa
Configure XWin to autostart Virt-Manager
cat << 'EOF' > ~/.startxwinrc export DISPLAY=:0.0 virt-manager sleep inf EOF chmod +x ~/.startxwinrc
Create Shortcut on Desktop: (This is the contents of my .cmd)
tskill.exe xwin C:\cygwin64\bin\run.exe /usr/bin/bash.exe -l -c /usr/bin/startxwin
4 Comments
Anonymous
Attention at the last row, the last letter is wrong, this is correct:
user-43d90
Thank You! Fixed! Did you get this working? I couldn't find any good guides and I thought this might help others.
Anonymous
Served me well, thnx!
1 little thing, if you are a domain user, installing for just yourself doesn't work with id_rsa?!?!
For some unknown reason ssh refuses to use the id_rsa. After installing it for all users everything was fine.
Of course I checked all the permissions etc.
user-43d90
You mean installing "Cygwin" for "All Users"? This seems odd, but this is a "hackish" setup and I don't have a domain Windows computer to test on. I'm a little confused by your comment, but glad you got it working.