# Elasticsearch does not start - log4j Warning

**URL:** <https://discuss.elastic.co/t/elasticsearch-does-not-start-log4j-warning/5447>\
**Category:** Elasticsearch\
**Created:** [September 24, 2011, 12:53pm UTC](https://discuss.elastic.co/t/elasticsearch-does-not-start-log4j-warning/5447 "2011-09-24T12:53:10Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![greenmang0](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/greenmang0/32/2000_2.png) [@greenmang0](https://discuss.elastic.co/u/greenmang0)\
**Post date:** [September 24, 2011, 12:53pm UTC](https://discuss.elastic.co/t/elasticsearch-does-not-start-log4j-warning/5447/1 "2011-09-24T12:53:10Z")

</div>

Hello Everyone,  
I get following warning when I start elasticsearch.

$ elasticsearch -Des.config=/etc/elasticsearch/elasticsearch.yml -f

log4j:WARN No appenders could be found for logger (common.jna).  
log4j:WARN Please initialize the log4j system properly.  
log4j:WARN See [http://logging.apache.org/log4j/1.2/faq.html#noconfig](http://logging.apache.org/log4j/1.2/faq.html#noconfig) for  
more info.

and "elasticsearch" doesn't start.

$ cat /etc/elasticsearch/elasticsearch.yml

# The cluster name

cluster:  
name: [search.example.com](http://search.example.com)

# Path Settings

path:  
conf: /etc/elasticsearch/elasticsearch.yml  
data: /var/lib/elasticsearch  
work: /tmp/elasticsearch  
logs: /var/log/elasticsearch

# Force all memory to be locked, forcing the JVM to never swap

bootstrap.mlockall: true

# Network Settings

network:  
host: [odin.example.com](http://odin.example.com)

# Gateway Settings

gateway:  
type: fs  
fs:  
location: /mnt/elasticmnt

common:  
jna: DEBUG

$ cat /etc/elasticsearch/logging.yml

rootLogger: INFO, console, file  
logger:

# log action execution errors for easier debugging

action: DEBUG  
com.example: WARN

# gateway

gateway: DEBUG

# discovery

discovery: TRACE

appender:  
console:  
type: console  
layout:  
type: consolePattern  
conversionPattern: "[%d{ISO8601}][%-5p][%-25c] %m%n"

file:  
type: dailyRollingFile  
file: ${path.logs}/${cluster.name}.log  
datePattern: "'.'yyyy-MM-dd"  
layout:  
type: pattern  
conversionPattern: "[%d{ISO8601}][%-5p][%-25c] %m%n"

---

<div class="post-metadata">

**Author:** ![greenmang0](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/greenmang0/32/2000_2.png) [@greenmang0](https://discuss.elastic.co/u/greenmang0)\
**Post date:** [September 26, 2011, 7:18am UTC](https://discuss.elastic.co/t/elasticsearch-does-not-start-log4j-warning/5447/2 "2011-09-26T07:18:57Z")

</div>

Found the answer  
here. [http://elasticsearch-users.115913.n3.nabble.com/Problem-with-Des-config-and-logging-yml-td3198254.html](http://elasticsearch-users.115913.n3.nabble.com/Problem-with-Des-config-and-logging-yml-td3198254.html)  
But is there a way to specify location of logging.yml file? and where does  
elasticsearch look for logging.yml if not found in PWD?

---

<div class="post-metadata">

**Author:** ![greenmang0](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/greenmang0/32/2000_2.png) [@greenmang0](https://discuss.elastic.co/u/greenmang0)\
**Post date:** [September 26, 2011, 7:43am UTC](https://discuss.elastic.co/t/elasticsearch-does-not-start-log4j-warning/5447/3 "2011-09-26T07:43:30Z")

</div>

Just adjusted "path.conf", in elasticsearch.yml and problem solved.

---

<div class="post-metadata">

**Author:** ![Nick\_Hoffman](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nick_hoffman/32/1872_2.png) [@Nick\_Hoffman](https://discuss.elastic.co/u/Nick_Hoffman)\
**Post date:** [October 7, 2011, 5:16pm UTC](https://discuss.elastic.co/t/elasticsearch-does-not-start-log4j-warning/5447/4 "2011-10-07T17:16:58Z")

</div>

Thanks for posting the solution, mate! I just built and installed the Debian  
package, and this problem bit me, too.

I had to specify the following settings in my elasticsearch.yml before ES  
would start:

path.conf: /etc/elasticsearch  
path.data: /var/lib/elasticsearch  
path.work: /tmp/elasticsearch  
path.logs: /var/log/elasticsearch

---

<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:** [July 6, 2017, 3:52am UTC](https://discuss.elastic.co/t/elasticsearch-does-not-start-log4j-warning/5447/5 "2017-07-06T03:52:36Z")

</div>


