# APM-Server logs are not wrriten in respective directory

**URL:** https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140
**Category:** APM
**Tags:** server
**Created:** [June 12, 2025, 1:46pm UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140 "2025-06-12T13:46:34Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![Ekta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ekta/32/55987_2.png) [@Ekta](https://discuss.elastic.co/u/Ekta)
#### Post date: [June 12, 2025, 1:46pm UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/1 "2025-06-12T13:46:34Z")

</div>

If you are asking about a problem you are experiencing, please use the following template, as it will help us help you. If you have a different problem, please delete all of this text 🙂

TIP 1: select at least one tag that further categorizes your topic. For example `server` for APM Server related questions, `java` for questions regarding the Elastic APM Java agent, or `ui` for questions about the APM App within Kibana.

TIP 2: Check out the [troubleshooting guide](https://www.elastic.co/guide/en/apm/get-started/current/troubleshooting.html) first. Not only will it help you to resolve common problems faster but it also explains in more detail which information we need before we can properly help you.

**Kibana version** : 8.18.1

**Elasticsearch version** : 8.18.1

**APM Server version** : 8.18.1

**APM Agent language and version** :

**Browser version** : crome Version 136.0.7103.93

**Original install method (e.g. download page, yum, deb, from source, etc.) and version**: deb

**Fresh install or upgraded from other version?** upgraded from 7.17.27

**Is there anything special in your setup?** For example, are you using the Logstash or Kafka outputs? Are you using a load balancer in front of the APM Servers? Have you changed index pattern, generated custom templates, changed agent configuration etc.  
No

**Description of the problem including expected versus actual behavior. Please include screenshots (if relevant)**:

I have configuredthe below options for logs store  
logging.to\_files: true  
logging.files:  
path: /var/log/apm-server  
name: apm-server  
keepfiles: 15  
permissions: 0600  
interval: 24h

But log are store in only syslog  
**Steps to reproduce** :  
1.  
2.  
3.

**Errors in browser console (if relevant)**: No

**Provide logs and/or server output (if relevant)**: No

---

<div class="post-metadata">

### Author: ![ericyap](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ericyap/32/143727_2.png) [@ericyap](https://discuss.elastic.co/u/ericyap)
#### Post date: [June 18, 2025, 3:56am UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/2 "2025-06-18T03:56:26Z")

</div>

Hi @Ekta may I know how you are deploying your APM server?

---

<div class="post-metadata">

### Author: ![Ekta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ekta/32/55987_2.png) [@Ekta](https://discuss.elastic.co/u/Ekta)
#### Post date: [June 19, 2025, 12:12pm UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/3 "2025-06-19T12:12:38Z")

</div>

@ericyap we have upgraded apm-server from 7.17.27 to 8.18.1 using .deb file dpkg -i command in Ubuntu 22.04 distribution. In 7.17.27 logs are working fine in custom location /var/log/apm-server but after upgrade log are go in syslog only. can you please help over here how to resolve this issue.

Below is the configuration regarding logs, which I have done in my yml file currently  
logging.to\_syslog: false  
logging.to\_files: true  
logging.files:  
path: /var/log/apm-server  
name: apm-server  
keepfiles: 7  
permissions: 0644  
interval: 24h

---

<div class="post-metadata">

### Author: ![ericyap](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ericyap/32/143727_2.png) [@ericyap](https://discuss.elastic.co/u/ericyap)
#### Post date: [June 20, 2025, 5:04am UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/4 "2025-06-20T05:04:17Z")

</div>

@Ekta The only thing I can think of regarding this regression might be [[logging] - Fix a regression related to `--environment` and logging config by VihasMakwana · Pull Request #321 · elastic/elastic-agent-libs · GitHub](https://github.com/elastic/elastic-agent-libs/pull/321). This fix should be included in the v8.18.3 release coming out on 24 June.

Otherwise I couldn't find anything else wrong with the logging in v8.18.1.

---

<div class="post-metadata">

### Author: ![Ekta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ekta/32/55987_2.png) [@Ekta](https://discuss.elastic.co/u/Ekta)
#### Post date: [June 23, 2025, 6:04am UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/5 "2025-06-23T06:04:12Z")

</div>

@ericyap ok thanks for the update we will check in 8.11.3 version

---

<div class="post-metadata">

### Author: ![Ekta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ekta/32/55987_2.png) [@Ekta](https://discuss.elastic.co/u/Ekta)
#### Post date: [July 3, 2025, 11:40am UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/6 "2025-07-03T11:40:22Z")

</div>

@ericyap we have upgraded version to 8.11.3 but still log are store in syslog only

---

<div class="post-metadata">

### Author: ![Ekta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ekta/32/55987_2.png) [@Ekta](https://discuss.elastic.co/u/Ekta)
#### Post date: [July 11, 2025, 9:38am UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/7 "2025-07-11T09:38:50Z")

</div>

Any update on it?

---

<div class="post-metadata">

### Author: ![ericyap](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ericyap/32/143727_2.png) [@ericyap](https://discuss.elastic.co/u/ericyap)
#### Post date: [July 14, 2025, 3:56pm UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/8 "2025-07-14T15:56:57Z")

</div>

Hi Ekta, do you mean you upgraded to 8.18.3?

---

<div class="post-metadata">

### Author: ![Ekta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ekta/32/55987_2.png) [@Ekta](https://discuss.elastic.co/u/Ekta)
#### Post date: [September 3, 2025, 11:44am UTC](https://discuss.elastic.co/t/apm-server-logs-are-not-wrriten-in-respective-directory/379140/9 "2025-09-03T11:44:39Z")

</div>

> [@Ekta](#):
>
> Below is the configuration regarding logs, which I have done in my yml file currently  
> logging.to\_syslog: false  
> logging.to\_files: true  
> logging.files:  
> path: /var/log/apm-server  
> name: apm-server  
> keepfiles: 7  
> permissions: 0644  
> interval: 24h

@ericyap we have installed 8.18.6 with above config but still log are not coming in /var/log/apm-server/ directory. can you please let us know in which version this issue resolve?
