Skip to main content
Solved

Upload files into SFTP server on a schedule

  • April 17, 2020
  • 1 reply
  • 208 views

fmeuser_gc
Contributor
Forum|alt.badge.img+8

Trying to upload .SHP files into SFTP server using scheduler. I've tried FTPCaller and 'Upload to SFTP server' action (in FME 2019.1 Automation) but it doesn't authenticate and throws this error -

Ensure correct host key is listed in the known hosts file

 

In Automation, I've uploaded private key in SSH format to resources folder and passed it to 'Path to Hosts file' parameter. It doesn't get authenticated but was able to connect to SFTP server in WinSCP via private key. Not sure if the private key has to be in SSH format or PuTTY format for FME. Firstly can this be done?

Also tried in FTPCaller with 'Upload from an Attribute' transfer type, but not sure of the URL value as it only has hostname and username.

Please suggest. Thanks in advance!

Best answer by siennaatsafe

Hi @fmeuser_gc,

Thanks for posting this question. Unfortunately, private SSH keys are not supported in the SFTP external action. However, do have instructions on using Public SSH keys here https://docs.safe.com/fme/html/FME_Server_Documentation/WebUI/Automations-External-Actions/Ext-Action-SFTP.htm

As for a workaround, you can use the FTPCaller as detailed here by Debbi and Gerhard https://knowledge.safe.com/questions/66175/how-do-i-use-sftp-ssh-keys-to-download-a-file.html If you are using FME Cloud you will have to use Gerhard's method. However, Debbi's solution should work fine on a local FME Server.

If you have any issue please let me know.

Kind regards,

Sienna

View original
Did this help you find an answer to your question?

1 reply

siennaatsafe
Safer
Forum|alt.badge.img+11
  • Safer
  • Best Answer
  • April 20, 2020

Hi @fmeuser_gc,

Thanks for posting this question. Unfortunately, private SSH keys are not supported in the SFTP external action. However, do have instructions on using Public SSH keys here https://docs.safe.com/fme/html/FME_Server_Documentation/WebUI/Automations-External-Actions/Ext-Action-SFTP.htm

As for a workaround, you can use the FTPCaller as detailed here by Debbi and Gerhard https://knowledge.safe.com/questions/66175/how-do-i-use-sftp-ssh-keys-to-download-a-file.html If you are using FME Cloud you will have to use Gerhard's method. However, Debbi's solution should work fine on a local FME Server.

If you have any issue please let me know.

Kind regards,

Sienna


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings