# How to set License Server

**URL:** <https://discuss.elastic.co/t/how-to-set-license-server/198742>\
**Category:** Logstash\
**Tags:** license\
**Created:** [September 9, 2019, 4:14pm UTC](https://discuss.elastic.co/t/how-to-set-license-server/198742 "2019-09-09T16:14:35Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jeggy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jeggy/32/53871_2.png) [@jeggy](https://discuss.elastic.co/u/jeggy)\
**Post date:** [September 9, 2019, 4:14pm UTC](https://discuss.elastic.co/t/how-to-set-license-server/198742/1 "2019-09-09T16:14:35Z")

</div>

I'm trying to setup a logstash service via docker-swarm.

I'm running it like this via a docker-compose file:

```
  logstash:
    image: docker.elastic.co/logstash/logstash:7.3.1
    command: logstash -e 'input{ gelf{ use_tcp => true }} output { elasticsearch{ hosts => ["http://esm2:9200"] } stdout{} }'

```

I'm getting this error messages:

```
[ERROR][logstash.licensechecker.licensereader] Unable to retrieve license information from license server {:message=>"No Available connections"}
[WARN][logstash.licensechecker.licensereader] Attempted to resurrect connection to dead ES instance, but got an error. {:url=>"http://elasticsearch:9200/", :error_type=>LogStash::Outputs::ElasticSearch::HttpClient::Pool::HostUnreachableError, :error=>"Elasticsearch Unreachable: [http://elasticsearch:9200/][Manticore::ResolutionFailure] elasticsearch: Name or service not known"}

```

The url in these messages are obviously wrong. So how do I overwrite them?

I have tried using environment variables, but am getting the exact same error message:

```
  xpack.monitoring.enabled=true
  xpack.monitoring.elasticsearch.url: http://esm2:9200
```

---

<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:** [October 7, 2019, 4:14pm UTC](https://discuss.elastic.co/t/how-to-set-license-server/198742/2 "2019-10-07T16:14:47Z")

</div>

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