我孤身走在路上, 石子在雾中发亮,夜很安静,荒原面对太空,星星互诉衷肠
Freeswitch配置日志
Freeswitch配置日志

Freeswitch配置日志

freeswitch的日志默认是不受控制的增加,运行一段时间后,容量堪称恐怖,也不方便排查,现在调整一下大小

修改如下文件,注意你编译的时候可能设置了和我不同的路径,但是文件是不变的

vim /usr/local/freeswitch/conf/autoload_configs/logfile.conf.xml

修改代码如下:

<configuration name="logfile.conf" description="File Logging">
  
<settings>
   
<!-- true to auto rotate on HUP, false to open/close -->
  <!--设置是否重新加载配置的时候进行轮询 -->
   <param name="rotate-on-hup" value="true"/>
   <!--设置每天轮询--> 
   <param name="rotate" value="daily"/>
    <!--设置为 30,表示每天轮询日志文件的延迟时间(单位为秒)-->
    <param name="rotate-delay" value="30"/>
  </settings>
 
    <profiles>
 
    <profile name="default">
  
    <settings>
        
    <!-- File to log to -->
  
    <!--<param name="logfile" value="/var/log/freeswitch.log"/>-->

    <!-- 单文件日志大小上限,此处设置的是10MB,单位是byte-->
        
    <param name="rollover" value="10000000"/>
        
    <!-- Maximum number of log files to keep before wrapping -->
     
    <!-- If this parameter is enabled, the log filenames will not include a date stamp -->
    <!-- 设置为 7,表示保留最近7天的日志文件。-->
 
    <param name="maximum-rotate" value="7"/>
        
    <!-- Prefix all log lines by the session's uuid  -->
        
    <param name="uuid" value="true" />
      
    </settings>
      
    <mappings>

    <!-- 
    name can be a file name, function name or 'all' 
         value is one or more of debug,info,notice,warning,err,crit,alert,all
       Please see comments in console.conf.xml for more information
  -->
 
    <map name="all" value="console,debug,info,notice,warning,err,crit,alert"/>
      
    </mappings>
    
    </profile>
  
    </profiles>

    </configuration>

Freeswitch安装配置及二次开发

一条评论

  1. Pingback:centos7 搭建 Freeswitch - 无双的个人博客

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

+ 71 = 81