FTP Download from outside home directory

Hi,

I can’t seem to see an answer to this in the forum or documentation.

I can connect to a UNIX ftp and download files from my home directory just fine (and below the directory in the structure).

I’m struggling to download something from another directory using an absolute path. The file exists activity returns true for an absolute path, but nothing happens when i try and download from the same path.

e.g. my home directory is /home/joe
a file called test1.txt in that directory may be downloaded using ‘test1.txt’ as the remote path.

But a file ‘test2.txt’ in the directory /work/folder_a/ cannot be downloaded by using either ‘/work/folder_a/test2.txt’ as the remote path, or ‘./…/…/work/folder_a/test2.txt’

Has anyone had the same problem and resolved it?

Thanks

Any directory outside home directory require credentials, are you supplying the necessary credentials ? Are you able to download using putty or any other tool ?

Yes I am supplying credentials and have no issue using other tools. Trying to avoid doing it in a GUI if I can.

I am sure some error message is generated, can you find out using try/catch

I just figured this out (by decompiling the ftp activity dll).

For some reason, if the first character of the remote path is ‘/’ then it gets stripped (which is why relative paths work fine) so if you add an extra one it downloads the absolute path just fine.

E.g.
‘/work/folder_a/test2.txt’ - FAILS
‘//work/folder_a/test2.txt’ - SUCCEEDS

2 Likes