Import failed - Error 1024

I was attempting to migrate a Subversion repo to GIT and received this error…

error: 1024
error: Unexpected error has occurred; please report along with the logs (‘D:\ATLASSVN\GeoMaster\subgit-import-20210727-153011.zip’)
error: to https://support.tmatesoft.com/, thank you!

Here is the file as requested: subgit-import-20210727-153011.zip (7.6 KB)

Hello John,

thank you for reporting this issue.
May I ask you what type of authentication is used for ssh? Is that key-based authentication and if yes what is the private key type format, PEM (RSA) or OPENSSH format?

Hey Ildar,

I was using svn+ssh with a putty key.

I ran from a batch file from a Win 10 environment…

pageant.exe threadgillj.ppk
C:\Tools\subgit-3.3.11\bin\subgit import --default-domain integral.co.nz --authors-file authors.txt --trunk trunk --branches branches --tags tags --non-interactive --trust-server-cert --private-key threadgillj.ppk --svn-url svn+ssh://threadgillj@svn.integral.co.nz/repo/GeoMaster/ D:\GIT\GeoMaster

Apparently pageant is needed to keep the putty credentials available for subgit?

Hope this helps.

Hi John,

the problem most probably is that the key is in putty format (ppt). Could you please try to convert it into the PEM format:

Convert a .pem File into .ppk, and Vice Versa, on Windows and Linu

and then try to start the import using the converted key?

Yup did that. The new command line is…

C:\Tools\subgit-3.3.11\bin\subgit import --default-domain integral.co.nz --authors-file authors.txt --trunk trunk --branches branches --tags tags --non-interactive --trust-server-cert --private-key threadgillj.pem --svn-url svn+ssh://threadgillj@svn.integral.co.nz/repo/GeoMaster/ D:\GIT\GeoMaster

There’s a new log file. Looks like a disconnection talking to the SVN repo:subgit-import-20210727-202422.zip (14.0 KB)

Hi John,

this looks to be an SSH agent issue. May I ask you to try stopping and unloading the Putty agent (pageant.exe) and also try to unset the SSH_AUTH_SOCK environment variable if it’s set.

I agree is seems SSH related. I unloaded pageant and removed a SVN_SSH environment variable (set to C:\Program Files (x86)\PuTTY\plink.exe). No sign of a SSH_AUTH_SOCK env variable. Opened a new elevated command prompt and ran:

C:\Tools\subgit-3.3.11\bin\subgit import --default-domain integral.co.nz --authors-file authors.txt --trunk trunk --branches branches --tags tags --non-interactive --trust-server-cert --private-key threadgillj.pem --svn-url svn+ssh://threadgillj@svn.integral.co.nz/repo/GeoMaster/ D:\GIT\GeoMaster

but got this…

IMPORT FAILED

error: svn: E170001: Authentication required for ‘threadgillj@svn+ssh://svn.integral.co.nz’

So definitely an SSH issue but not sure how to work around it. BTW, no log file generated this time.

Haha! … might have it sorted. I grabbed the generated config file from D:\GIT\GeoMaster\subgit and copied it to D:\ATLASSVN\GeoMaster.

I edited to ensure that in the [SVN] section the url was set correctly and auth was set at default:
url = svn+ssh://threadgillj@svn.integral.co.nz/repo/GeoMaster
auth = default

In the [auth "default"] section
sshKeyFile = D:/ATLASSVN/GeoMaster/threadgillj.pem
useDefaultSubversionConfigurationDirectory = false
subversionConfigurationDirectory = C:/Users/John/AppData/Roaming/Subversion

This section did not seem to be setup correctly.

Then ran this from D:\ATLASSVN\GeoMaster
subgit import D:\GIT\GeoMaster

Seems to be busy “Translating Subversion revisions to Git commits…” :-)

Hi John,

that “Translating Subversion revisions to Git commits…” message indeed means that the import is in progress, so you are right, you have sorted that out! :)
As for the E170001 error – most probably this happened because the key has not been caught despite it was set as the command argument, we will investigate why could it have happened. The workaround is actually the approach with the preliminary configuration which you have applied)