Solved

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

Posted on 2015-01-08
3
130 Views
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!
0
Comment
Question by:MichaelBalack
  • 2
3 Comments
 
LVL 11

Expert Comment

by:Tej Pratap Shukla ~Dexter
ID: 40539611
hi..
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 {
weekly
missingok
rotate 9
size 512000k
copytruncate
endscript
}
Refer the following link in case if you feeling any difficulty
http://www.voip-info.org/wiki/view/logrotate
0
 
LVL 1

Accepted Solution

by:
MichaelBalack earned 0 total points
ID: 40539617
Hi Dexter,

Give me some times to read through...
0
 
LVL 1

Author Closing Comment

by:MichaelBalack
ID: 40567985
It works
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Join & Write a Comment

I am a long time windows user and for me it is normal to have spaces in directory and file names. Changing to Linux I found myself frustrated when I moved my windows data over to my new Linux computer. The problem occurs when at the command line.…
Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
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…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

747 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now