Found asterisk log files growing big very fast and hard disk no more, how?

Posted on 2015-01-08
Last Modified: 2015-01-24
This is using Linux server. There are 40 GB hard disk space allocated for /. However, found that in /var/log/asterisk, the log file - messages, grows very fast; and within a week or 2, all disk space used up and consequencely, the application stops working. Is there a way to "rotate" the log file, let's say a new log file create if the log hits 500 mb or so?

Appreciate your help, thanks!
Question by:MichaelBalack
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
LVL 11

Expert Comment

by:Tej Pratap Shukla ~Dexter
ID: 40539611
Yes, Linux offers a utility to handle the log files. It will automatically create the new log file if log hits to the threshold that you have set on it

/var/log/asterisk/cdr-csv/Master.csv /var/log/asterisk/debug /var/log/asterisk/event_log /var/log/asterisk/messages {
rotate 9
size 512000k
Refer the following link in case if you feeling any difficulty

Accepted Solution

MichaelBalack earned 0 total points
ID: 40539617
Hi Dexter,

Give me some times to read through...

Author Closing Comment

ID: 40567985
It works

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
open source backup solution 1 44
How to mount nfs share on this CentOS server? 6 57
The better OS Architecture 13 90
rsyslog raw message 4 37
This is the error message I got (CODE) Error caused by incompatible libmp3lame 3.98-2 with ffmpeg I've googled this error message and found out sometimes it attaches this note "can be treated with downgrade libmp3lame to version 3.97 or 3.98" …
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension ( This reminded me of questions tha…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question