KopiaUI + SFTP is not Windows friendly

The KopiaUI (Windows version) setup to a remote Linux SFTP server asks for the path to the “known_hosts” file (or its contents).

This file is typically available in a local Linux installation - but not in Windows. For example, my putty application stores this in the Windows registry - which is not accessible via path. And the contents of the registry key were unable to be parsed by KopiaUI.

I believe this is a Feature Request, unless there is a work-around that I haven’t discovered yet.

I looked at other Windows applications that connect to ssh / sftp servers, to see how they configure the connection and deal with the issue of key path, and in particular - known_hosts.

Putty
WinSCP
Duplicati
Cyberduck

In all cases, the user enters the following required parameters:
path to server:port, path on server, user name and (ssh) password. In all cases, the ssh private key is an optional input item. known_hosts not present at all.

Upon entering the required input items, these 4 applications connect, and the server sends the ssh fingerprint to the Windows client for confirmation and authentication.

I am not an ssh expert. If there is a method to connect a Windows device to an sftp server using KopiaUI as is - please share it.

Thanks for KopiaUI. So much potential here!

1 Like

Still testing, but I’m currently mounting my remote storage via sshfs-win. There are various implementations of this with different GUI’s and whatnot, but they all more or less do the same thing. So far so good for me, mounting with a drive letter on login, then pointing Kopia at the mounted path in “filesystem” mode, but obviously this is just a workaround.

I’m using Duplicacy on the same remote storage over SFTP and it works great, entering the normal fields you outlined in your post.

Let me know if you figure out a way to directly access the storage via Kopia!

It’s an old thread, but since I came across this while looking for something else, I may as well give a workaround for this one. At least there may be others on Windows who may benefit from this.

OpenSSH has been part of Windows installation at least since Windows 10. So, you can basically make an ssh connection to your host from the command prompt: ssh username@example.com. Immediately after that you will be asked something like:

The authenticity of host 'example.com (93.184.216.34)' can't be established.
ECDSA key fingerprint is SHA256:VHJ1c3QgbWUsIEkga25vdyB3aGF0IEknbSBkb2luZy4.
Are you sure you want to continue connecting (yes/no)?

After you write yes, the public key of the host will be saved into the file
C:\Users\username\.ssh\known_hosts. The host will ask for your password after that, but you don’t have to log in at this point if you don’t want to.

Now, you can use that known_hosts file as the one Kopia requires for the SFTP connection. And if you have multiple hosts you want to use for backups, you can just do the same with each one of them, and all their keys will be saved into the same known_hosts file.

2 Likes

I never sign up for these forums but this time I did just to say THANK YOU. If it weren’t for your detailed instructions I would still be beating my head against the wall!

Forum Moderator- this is written exactly as it should be done and works exactly as it should. I would STRONGLY suggest adding this to the official Kopia documentation!

You’re welcome. This issue has also come up on Github lately, with hopes of mitigating the requirement of the known_hosts data. I would personally advocate making it optional (required by default), even though it has its own security issues. It may just be too complicated for an average Windows user.

And if you struggle with key mismatch even if everything is ok, then it may be this issue of Kopia not accepting ed25519 keys on SFTP right now