ap_log_perror无法从配置文件读取日志级别? [英] ap_log_perror unable to read loglevel from configuration file?
问题描述
Loglevel error
我在配置文件httpd.conf文件中给出此信息,当我使用ap_log_rerror函数时,它仅捕获有错误或高于日志级别的日志消息,但是当我使用ap_log_perror函数时,它是显示从默认日志级别开始的日志消息警告,我无法理解为什么在ap_log_perror情况下不从配置读取日志级别? 为什么我用ap_log_perror无法达到相同的目的?
I am giving this in the configuration file,httpd.conf file,when i am using the function ap_log_rerror,it is capturing only log messages that are having error or above loglevels,but when i am using the function ap_log_perror function it is showing log messages starting from default loglevel warn,i cannot understand why in the case of ap_log_perror it is not reading the loglevel from configuration ? why i am unable achieve the same with ap_log_perror ?
推荐答案
ap_log_perror无法从配置文件中读取,我在代码log.c中进行了更改,为此,并在其中添加了一个读取配置的函数文件日志级别,从配置文件中读取日志级别后,将其分配给log.c文件中声明的default_loglevel,因此可以正常工作.
ap_log_perror would not read from the configuration file,i made changes in the code log.c,in order to do so and added a function there that reads the config file loglevel,after reading loglevel from configuration file ,it is assigned to the default_loglevel declared in log.c file and thus, can work.
干杯!
这篇关于ap_log_perror无法从配置文件读取日志级别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!