# Purging logs

**URL:** <https://community.wowza.com/t/purging-logs/35805>\
**Category:** Wowza Streaming Engine\
**Tags:** server-administration\
**Created:** [November 30, 2010, 7:33am UTC](https://community.wowza.com/t/purging-logs/35805 "2010-11-30T07:33:14Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Geoff\_Galitz](https://avatars.discourse-cdn.com/v4/letter/g/5daacb/32.png) [@Geoff\_Galitz](https://community.wowza.com/u/Geoff_Galitz)\
**Post date:** [November 30, 2010, 7:33am UTC](https://community.wowza.com/t/purging-logs/35805/1 "2010-11-30T07:33:14Z")

</div>

Hello.

I can see in the docs a method to roll over logs, but I don’t see anything on purging old logs. Is that possible using wowza or must I use an external script for that?

---

<div class="post-metadata">

**Author:** ![Roger\_Littin](https://avatars.discourse-cdn.com/v4/letter/r/d26b3c/32.png) [@Roger\_Littin](https://community.wowza.com/u/Roger_Littin)\
**Post date:** [November 30, 2010, 7:22am UTC](https://community.wowza.com/t/purging-logs/35805/2 "2010-11-30T07:22:09Z")

</div>

There is not really any built in way of purging old files. You will need to do it with an external script.

---

<div class="post-metadata">

**Author:** ![Roger\_Littin](https://avatars.discourse-cdn.com/v4/letter/r/d26b3c/32.png) [@Roger\_Littin](https://community.wowza.com/u/Roger_Littin)\
**Post date:** [November 30, 2010, 9:53am UTC](https://community.wowza.com/t/purging-logs/35805/3 "2010-11-30T09:53:23Z")

</div>

I don’t think it will take too well to removing the log file. I have tried moving the current log file before and it doesn’t complain but then it doesn’t create a new one either. [http://nicerhttpd.blogspot.com/2008/11/logrotate-and-log4j.html](http://nicerhttpd.blogspot.com/2008/11/logrotate-and-log4j.html) This gives a example on how to use both.

---

<div class="post-metadata">

**Author:** ![alan\_costello](https://avatars.discourse-cdn.com/v4/letter/a/c89c15/32.png) [@alan\_costello](https://community.wowza.com/u/alan_costello)\
**Post date:** [December 4, 2010, 3:04pm UTC](https://community.wowza.com/t/purging-logs/35805/4 "2010-12-04T15:04:58Z")

</div>

We have access and error logs building up on our server - can we not just delete the ones a few months old we do not use?

Also (we re-configured to use sawmill) is this expected:

user/local/wowzamediaserver/logs - access daily logs (about 300 Megs each), error logs

user/local/wowzamediaserver/logs/_defaultVHost_ - access daily logs (about 200 Megs each, error logs and stats logs (probably for Sawmill)

user/local/wowzamediaserver/logs/_defaultVHost_/myStreamingDirectory - access daily logs (about 15 megs each), error logs and stats logs

Should we have so many different logs going on?

Thanks.

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [December 4, 2010, 6:04pm UTC](https://community.wowza.com/t/purging-logs/35805/5 "2010-12-04T18:04:07Z")

</div>

Looks like you have configured /conf/log4j.properties to do VHost and Application logging. These are commented out by default, so someone enabled them on that server. You can easily comment those sections out.

It’s up to you how long to keep logs. Wowza does not need logs for operations. You can disable all logging if you wanted to.

Richard

---

<div class="post-metadata">

**Author:** ![Geoff\_Galitz](https://avatars.discourse-cdn.com/v4/letter/g/5daacb/32.png) [@Geoff\_Galitz](https://community.wowza.com/u/Geoff_Galitz)\
**Post date:** [November 30, 2010, 8:51am UTC](https://community.wowza.com/t/purging-logs/35805/6 "2010-11-30T08:51:53Z")

</div>

If I use logrotate to manage the logs rather than use the internal Wowza mechansim, do I need to restart Wowza or will it happily notice the log file has disappeared and create a new one? Or is there a way to get Wowza to recreate the log file without restarting the app and disrupting currently connected users?
