免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1651 | 回复: 7
打印 上一主题 下一主题

[Web] cronolog实现日志轮循 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2005-09-23 21:58 |只看该作者 |倒序浏览
在用cronolog实现日志轮循时,我把日志放在目录/年/月/日/上午(下午).可是这样切换后,这个目录下的日志仍然很大,差不多有2G.怎样用cronolog把日志切的更小些阿 ?? 谢谢大家了 !!

论坛徽章:
1
技术图书徽章
日期:2013-12-05 23:25:45
2 [报告]
发表于 2005-09-23 22:20 |只看该作者

cronolog实现日志轮循

请参看:
http://w.yi.org/ftp/FAPM/apache/Apache2/zh/logs.html

有条件地记录日志

论坛徽章:
0
3 [报告]
发表于 2005-09-24 00:04 |只看该作者

cronolog实现日志轮循

谢谢版主!这个网页我以前看过了。我现在不是想把日志过滤掉,是想通过cronolog把日志分成更多块,请问该怎么做啊??谢谢了!

论坛徽章:
1
技术图书徽章
日期:2013-12-05 23:25:45
4 [报告]
发表于 2005-09-24 00:09 |只看该作者

cronolog实现日志轮循

你可以按照条件来记录啊,例如图片单独记录什么的

论坛徽章:
1
技术图书徽章
日期:2013-12-05 23:25:45
5 [报告]
发表于 2005-09-24 00:11 |只看该作者

cronolog实现日志轮循

%%        a literal % character       
%n        a new-line character       
%t        a horizontal tab character       
Time fields       
%H        hour (00..23)       
%I        hour (01..12)       
%p        the locale's AM or PM indicator       
%M        minute (00..59)       
%S        second (00..61, which allows for leap seconds)       
%X        the locale's time representation (e.g.: "15:12:47"       
%Z        time zone (e.g. GMT), or nothing if the time zone cannot be determined       
Date fields       
%a        the locale's abbreviated weekday name (e.g.: Sun..Sat)       
%A        the locale's full weekday name (e.g.: Sunday .. Saturday)       
%b        the locale's abbreviated month name (e.g.: Jan .. Dec)       
%B        the locale's full month name, (e.g.: January .. December)       
%c        the locale's date and time (e.g.: "Sun Dec 15 14:12:47 GMT 1996"       
%d        day of month (01 .. 31)       
%j        day of year (001 .. 366)       
%m        month (01 .. 12)       
%U        week of the year with Sunday as first day of week (00..53, where week 1 is the week containing the first Sunday of the year)       
%W        week of the year with Monday as first day of week (00..53, where week 1 is the week containing the first Monday of the year)       
%w        day of week (0 .. 6, where 0 corresponds to Sunday)       
%x        locale's date representation (e.g. today in Britain: "15/12/96"       
%y        year without the century (00 .. 99)       
%Y        year with the century (1970 .. 203

论坛徽章:
0
6 [报告]
发表于 2005-09-24 00:25 |只看该作者

cronolog实现日志轮循

版主!上面这个说明是在哪里找来的阿 ,我看了cronolog的帮助好像没有啊 !!

论坛徽章:
1
技术图书徽章
日期:2013-12-05 23:25:45
7 [报告]
发表于 2005-09-24 00:28 |只看该作者

cronolog实现日志轮循

我的档案库里面搜录的啊

论坛徽章:
0
8 [报告]
发表于 2005-09-24 00:29 |只看该作者

cronolog实现日志轮循

是版主的网站把!挺好的!很多有用的东西啊!顶!!
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP