# Logstash output to FTP

**URL:** <https://discuss.elastic.co/t/logstash-output-to-ftp/183680>\
**Category:** Logstash\
**Created:** [May 31, 2019, 8:25am UTC](https://discuss.elastic.co/t/logstash-output-to-ftp/183680 "2019-05-31T08:25:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![saif3r](https://avatars.discourse-cdn.com/v4/letter/s/49beb7/32.png) [@saif3r](https://discuss.elastic.co/u/saif3r)\
**Post date:** [May 31, 2019, 8:25am UTC](https://discuss.elastic.co/t/logstash-output-to-ftp/183680/1 "2019-05-31T08:25:07Z")

</div>

Hello,

We have a use case, where our admins would like to receive Logstash's json output files directly to their FTP using non-standard ftp port.  
I tried using file output plugin with below path, but it fails.

`ftp://logstash:password@10.10.10.10:652/test.json`

Connecting normally via browser, works.  
The error:

> [ERROR] 2019-05-31 10:12:02.977 [[main]\>worker9] WorkerLoop - Exception in pipelineworker, the pipeline stopped processing new events, please check your filter configuration and restart Logstash.  
> org.jruby.exceptions.SystemCallError: (ENOTDIR) Not a directory - ftp:

Any idea how to tackle this topic? Thanks!

---

<div class="post-metadata">

**Author:** ![pastechecker](https://avatars.discourse-cdn.com/v4/letter/p/0ea827/32.png) [@pastechecker](https://discuss.elastic.co/u/pastechecker)\
**Post date:** [May 31, 2019, 9:21am UTC](https://discuss.elastic.co/t/logstash-output-to-ftp/183680/2 "2019-05-31T09:21:21Z")

</div>

Hello.  
Probably it is not possible with the file output to accomplish that. If you would like to do that, you could use the NFS. Mount the external partition locally and save the file there. Or just use RSYNC or other tool to synchronize the data between servers.

Another options would be:

- Use the TCP as a transport for your FTP traffic and you could handle this request on your FTP Server.  
[https://www.elastic.co/guide/en/logstash/current/plugins-outputs-tcp.html](https://www.elastic.co/guide/en/logstash/current/plugins-outputs-tcp.html)

- install another logstash on the FTP machine (from the 1st logstash you gonna use the TCP as a transport to the another logstash instance and later output as a file).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [June 28, 2019, 9:21am UTC](https://discuss.elastic.co/t/logstash-output-to-ftp/183680/3 "2019-06-28T09:21:29Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
