# Getting Logstash output cannot be used with Fleet Server integration in Fleet Server Policy. Please create a new ElasticSearch output

**URL:** <https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980>\
**Category:** Elasticsearch\
**Created:** [April 27, 2023, 5:07pm UTC](https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980 "2023-04-27T17:07:35Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![mehdi-lamrani](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mehdi-lamrani/32/108993_2.png) [@mehdi-lamrani](https://discuss.elastic.co/u/mehdi-lamrani)\
**Post date:** [April 27, 2023, 5:07pm UTC](https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980/1 "2023-04-27T17:07:36Z")

</div>

This is pretty straightforward as you can see :

![fleet-add-3](https://us1.discourse-cdn.com/elastic/original/3X/9/d/9d56b4b857ff5294e93ea739d66e81eff923db47.png)

I get this after trying to configure a logstash output on Fleet and going through all the steps.

I dont know what to do with this error message as it does not make sense to me honestly. WHy Logstash output cannot be used with Fleet Server integration if there's an option to add it and configure it there. Doesn't make sense.  
As a side note, I saw this setup working properly in a video call I had recently, so I am sure it can work.

Any Ideas ?

![fleet-add-1](https://us1.discourse-cdn.com/elastic/original/3X/3/9/39eefb39f8639c5ad5307225f1f7837b21f7dfc6.png)  
 ![fleet-add-2](https://us1.discourse-cdn.com/elastic/original/3X/6/3/63d5c978285d122fd15397c130c4c6692854df1e.png)

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [April 27, 2023, 5:29pm UTC](https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980/2 "2023-04-27T17:29:15Z")

</div>

Hello,

> [@mehdi-lamrani](#):
>
> I get this after trying to configure a logstash output on Fleet and going through all the steps.

Which steps did you follow? Please share the link of the documentation you followed.

Also, in Which version are you?

If I'm not wrong there was a [recent change](https://github.com/elastic/kibana/issues/152234) to block setting Logstash as an output for a Fleet Server policy as it can only output to Elasticsearch.

A policy for a fleet server can not have Logstash as an output, but a policy for Elastic Agents can.

---

<div class="post-metadata">

**Author:** ![mehdi-lamrani](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mehdi-lamrani/32/108993_2.png) [@mehdi-lamrani](https://discuss.elastic.co/u/mehdi-lamrani)\
**Post date:** [April 28, 2023, 11:34am UTC](https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980/3 "2023-04-28T11:34:18Z")

</div>

using current to date version (8.7)  
I do not find documentation for using the UI to do this,  
however [this blog post](https://www.gooksu.com/2022/05/fleet-server-with-logstash-output-elastic-agent/) covers the steps i've been through.

I tried to delete the fleet server integration that is added to Fleet Server policy and it worked  
(the one marked below)

 ![Screenshot 2023-04-28 at 13.22.18](https://us1.discourse-cdn.com/elastic/original/3X/3/d/3db056b14f21e0060bc2bf8e0c1ff05170c10f21.png)

After that I was able to create the logstash output.

 ![Screenshot 2023-04-28 at 13.31.38](https://us1.discourse-cdn.com/elastic/original/3X/4/1/4112b947c98f55ec76c64a4b3d2d21316355b44c.png)

(Fun fact, I was able to recreate the deleted fleet server integration on the fleet server policy after that. Was expecting some kind of error, for consistency)

HOWEVER having to delete the fleet server integration in the fleet server policy violates the setup that is needed for Fleet in my understanding. SO this workaround still makes no sense to me.

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [April 28, 2023, 12:03pm UTC](https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980/4 "2023-04-28T12:03:49Z")

</div>

> [@mehdi-lamrani](#):
>
> I do not find documentation for using the UI to do this,  
> however [this blog post](https://www.gooksu.com/2022/05/fleet-server-with-logstash-output-elastic-agent/) covers the steps i've been through.

Yeah, this is not official and it is based on an older version.

As mentioned, you cannot have a Logstash output on a Fleet Server Policy anymore.

---

<div class="post-metadata">

**Author:** ![mehdi-lamrani](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mehdi-lamrani/32/108993_2.png) [@mehdi-lamrani](https://discuss.elastic.co/u/mehdi-lamrani)\
**Post date:** [April 30, 2023, 1:16pm UTC](https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980/5 "2023-04-30T13:16:51Z")

</div>

It was a bit confusing but now I get it.  
Logstash output needs to be created first on the general fleet settings, and only later on attributed to a policy (an agent policy)  
Thanks for your insight

---

<div class="post-metadata">

**Author:** ![neutronscott](https://avatars.discourse-cdn.com/v4/letter/n/aca169/32.png) [@neutronscott](https://discuss.elastic.co/u/neutronscott)\
**Post date:** [May 17, 2023, 2:24pm UTC](https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980/6 "2023-05-17T14:24:34Z")

</div>

This is came up first for me when googling the error so just adding details.

I was trying to create a logstash output to assign to agents and got this error about a Fleet policy (which would not have used the output).

Hopefully fixed in 8.7.1. [https://github.com/elastic/kibana/pull/153226](https://github.com/elastic/kibana/pull/153226)

---

<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 14, 2023, 2:25pm UTC](https://discuss.elastic.co/t/getting-logstash-output-cannot-be-used-with-fleet-server-integration-in-fleet-server-policy-please-create-a-new-elasticsearch-output/330980/7 "2023-06-14T14:25:27Z")

</div>

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