# Does percona change slow\_query\_log automatically?

**URL:** <https://forums.percona.com/t/does-percona-change-slow-query-log-automatically/6587>\
**Category:** Other MySQL® Questions\
**Created:** [September 19, 2018, 8:50am UTC](https://forums.percona.com/t/does-percona-change-slow-query-log-automatically/6587 "2018-09-19T08:50:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![alopez](https://avatars.discourse-cdn.com/v4/letter/a/97f17d/32.png) [@alopez](https://forums.percona.com/u/alopez)\
**Post date:** [September 19, 2018, 8:50am UTC](https://forums.percona.com/t/does-percona-change-slow-query-log-automatically/6587/1 "2018-09-19T08:50:06Z")

</div>

Hello everybody, this is my first post so I do not know if I am posting in the right place :o

I am a percona’s noob and I want to set slow\_query\_log OFF. So inside my my.conf file is set OFF. I also checked percona’s config files but I randomly detect this variable is been set ON.

I forced a change with my server up:

mysql\> set global slow\_query\_log = 0;  
Query OK, 0 rows affected (0.00 sec)  
mysql\> show global variables like ‘slow\_query\_log’;  
±---------------±------+  
| Variable\_name | Value |  
±---------------±------+  
| slow\_query\_log | OFF |  
±---------------±------+  
1 row in set (0.01 sec)

But a few hours later I found it ON again. I had logged changes 1 hour and 11 hours later after the last change.

mysql\> show global variables like ‘slow\_query\_log’;  
±---------------±------+  
| Variable\_name | Value |  
±---------------±------+  
| slow\_query\_log | ON |  
±---------------±------+

So, I just want to know if pnn is enabling this variable ON or it is changed by any chron process or something similar. I also would thank any help to force slow\_query\_log to OFF

Cheers 🙂

---

<div class="post-metadata">

**Author:** ![lorraine.pocklington](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/lorraine.pocklington/32/37_2.png) [@lorraine.pocklington](https://forums.percona.com/u/lorraine.pocklington)\
**Post date:** [September 19, 2018, 9:03am UTC](https://forums.percona.com/t/does-percona-change-slow-query-log-automatically/6587/2 "2018-09-19T09:03:45Z")

</div>

Hello there, welcome to the Forum. You are in the right place. 🙂 I’m not a tech but I just wanted to let you know your post had been seen and moderated. I will see if someone can help you with it.

---

<div class="post-metadata">

**Author:** ![IMP](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/imp/32/20213_2.png) [@IMP](https://forums.percona.com/u/IMP)\
**Post date:** [September 19, 2018, 9:19am UTC](https://forums.percona.com/t/does-percona-change-slow-query-log-automatically/6587/3 "2018-09-19T09:19:34Z")

</div>

Hello,

QAN will enable slow\_query\_log if you have mysql:queries service configured with query\_source=slowlog.

Note, that QAN is capable of using performance schema to collect data. It can be done by passing --query-source perfschema when adding a service. With performance\_schema QAN will not be enabling slow\_query\_log variable.

Please see [url][Percona Monitoring and Management](https://www.percona.com/doc/percona-monitoring-and-management/pmm-admin.html#pmm-admin-add-mysql-queries%5B/url%5D) for more information.
