From nobody@FreeBSD.org  Sat May 11 08:52:56 2013
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1])
	by hub.freebsd.org (Postfix) with ESMTP id 3649B887
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 11 May 2013 08:52:56 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from oldred.FreeBSD.org (oldred.freebsd.org [8.8.178.121])
	by mx1.freebsd.org (Postfix) with ESMTP id 0EA26F0D
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 11 May 2013 08:52:56 +0000 (UTC)
Received: from oldred.FreeBSD.org ([127.0.1.6])
	by oldred.FreeBSD.org (8.14.5/8.14.5) with ESMTP id r4B8qtZC074095
	for <freebsd-gnats-submit@FreeBSD.org>; Sat, 11 May 2013 08:52:55 GMT
	(envelope-from nobody@oldred.FreeBSD.org)
Received: (from nobody@localhost)
	by oldred.FreeBSD.org (8.14.5/8.14.5/Submit) id r4B8qtcj074094;
	Sat, 11 May 2013 08:52:55 GMT
	(envelope-from nobody)
Message-Id: <201305110852.r4B8qtcj074094@oldred.FreeBSD.org>
Date: Sat, 11 May 2013 08:52:55 GMT
From: Alex Kozlov <spam@rm-rf.kiev.ua>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [patch] switch logs compression from bzip2 to xz
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         178504
>Category:       conf
>Synopsis:       [patch] switch logs compression from bzip2 to xz
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sat May 11 09:00:00 UTC 2013
>Closed-Date:    Sun May 12 15:24:17 UTC 2013
>Last-Modified:  Wed May 15 14:00:00 UTC 2013
>Originator:     Alex Kozlov
>Release:        RELENG_10
>Organization:
private
>Environment:
>Description:
Make newsyslog compress logs with xz instead of bzip2 to save space.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

Index: etc/newsyslog.conf
@@ -17,23 +17,23 @@
 # future, these defaults may change to more conservative ones.
 #
 # logfilename          [owner:group]    mode count size when  flags [/pid_file] [sig_num]
-/var/log/all.log			600  7	   *	@T00  J
-/var/log/amd.log			644  7	   100	*     J
-/var/log/auth.log			600  7     100  @0101T JC
-/var/log/console.log			600  5	   100	*     J
-/var/log/cron				600  3	   100	*     JC
-/var/log/daily.log			640  7	   *	@T00  JN
-/var/log/debug.log			600  7     100  *     JC
-/var/log/init.log			644  3	   100	*     J
-/var/log/kerberos.log			600  7	   100	*     J
-/var/log/lpd-errs			644  7	   100	*     JC
-/var/log/maillog			640  7	   *	@T00  JC
-/var/log/messages			644  5	   100	@0101T JC
-/var/log/monthly.log			640  12	   *	$M1D0 JN
-/var/log/pflog				600  3	   100	*     JB    /var/run/pflogd.pid
-/var/log/ppp.log	root:network	640  3	   100	*     JC
-/var/log/security			600  10	   100	*     JC
+/var/log/all.log			600  7	   *	@T00  X
+/var/log/amd.log			644  7	   100	*     X
+/var/log/auth.log			600  7     100  @0101T XC
+/var/log/console.log			600  5	   100	*     X
+/var/log/cron				600  3	   100	*     XC
+/var/log/daily.log			640  7	   *	@T00  XN
+/var/log/debug.log			600  7     100  *     XC
+/var/log/init.log			644  3	   100	*     X
+/var/log/kerberos.log			600  7	   100	*     X
+/var/log/lpd-errs			644  7	   100	*     XC
+/var/log/maillog			640  7	   *	@T00  XC
+/var/log/messages			644  5	   100	@0101T XC
+/var/log/monthly.log			640  12	   *	$M1D0 XN
+/var/log/pflog				600  3	   100	*     XB    /var/run/pflogd.pid
+/var/log/ppp.log	root:network	640  3	   100	*     XC
+/var/log/security			600  10	   100	*     XC
 /var/log/sendmail.st			640  10	   *	168   BN
 /var/log/utx.log			644  3	   *	@01T05 B
-/var/log/weekly.log			640  5	   *	$W6D0 JN
-/var/log/xferlog			600  7	   100	*     JC
+/var/log/weekly.log			640  5	   *	$W6D0 XN
+/var/log/xferlog			600  7	   100	*     XC


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: eadler 
State-Changed-When: Sun May 12 15:24:14 UTC 2013 
State-Changed-Why:  
Committed. Thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=178504 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: conf/178504: commit references a PR
Date: Sun, 12 May 2013 15:24:07 +0000 (UTC)

 Author: eadler
 Date: Sun May 12 15:23:59 2013
 New Revision: 250565
 URL: http://svnweb.freebsd.org/changeset/base/250565
 
 Log:
   Make newsyslog compress logs with xz instead of bzip2 to save space.
   
   PR:		conf/178504
   Submitted by:	ak
   Reviewed by:	smh
 
 Modified:
   head/etc/newsyslog.conf
 
 Modified: head/etc/newsyslog.conf
 ==============================================================================
 --- head/etc/newsyslog.conf	Sun May 12 13:42:49 2013	(r250564)
 +++ head/etc/newsyslog.conf	Sun May 12 15:23:59 2013	(r250565)
 @@ -17,23 +17,23 @@
  # future, these defaults may change to more conservative ones.
  #
  # logfilename          [owner:group]    mode count size when  flags [/pid_file] [sig_num]
 -/var/log/all.log			600  7	   *	@T00  J
 -/var/log/amd.log			644  7	   100	*     J
 -/var/log/auth.log			600  7     100  @0101T JC
 -/var/log/console.log			600  5	   100	*     J
 -/var/log/cron				600  3	   100	*     JC
 -/var/log/daily.log			640  7	   *	@T00  JN
 -/var/log/debug.log			600  7     100  *     JC
 -/var/log/init.log			644  3	   100	*     J
 -/var/log/kerberos.log			600  7	   100	*     J
 -/var/log/lpd-errs			644  7	   100	*     JC
 -/var/log/maillog			640  7	   *	@T00  JC
 -/var/log/messages			644  5	   100	@0101T JC
 -/var/log/monthly.log			640  12	   *	$M1D0 JN
 -/var/log/pflog				600  3	   100	*     JB    /var/run/pflogd.pid
 -/var/log/ppp.log	root:network	640  3	   100	*     JC
 -/var/log/security			600  10	   100	*     JC
 +/var/log/all.log			600  7	   *	@T00  X
 +/var/log/amd.log			644  7	   100	*     X
 +/var/log/auth.log			600  7     100  @0101T XC
 +/var/log/console.log			600  5	   100	*     X
 +/var/log/cron				600  3	   100	*     XC
 +/var/log/daily.log			640  7	   *	@T00  XN
 +/var/log/debug.log			600  7     100  *     XC
 +/var/log/init.log			644  3	   100	*     X
 +/var/log/kerberos.log			600  7	   100	*     X
 +/var/log/lpd-errs			644  7	   100	*     XC
 +/var/log/maillog			640  7	   *	@T00  XC
 +/var/log/messages			644  5	   100	@0101T XC
 +/var/log/monthly.log			640  12	   *	$M1D0 XN
 +/var/log/pflog				600  3	   100	*     XB    /var/run/pflogd.pid
 +/var/log/ppp.log	root:network	640  3	   100	*     XC
 +/var/log/security			600  10	   100	*     XC
  /var/log/sendmail.st			640  10	   *	168   BN
  /var/log/utx.log			644  3	   *	@01T05 B
 -/var/log/weekly.log			640  5	   *	$W6D0 JN
 -/var/log/xferlog			600  7	   100	*     JC
 +/var/log/weekly.log			640  5	   *	$W6D0 XN
 +/var/log/xferlog			600  7	   100	*     XC
 _______________________________________________
 svn-src-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-src-all
 To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: conf/178504: commit references a PR
Date: Sun, 12 May 2013 21:24:25 +0000 (UTC)

 Author: eadler
 Date: Sun May 12 21:24:18 2013
 New Revision: 250579
 URL: http://svnweb.freebsd.org/changeset/base/250579
 
 Log:
   Revert r250565 which causes issues for older CPUs
   
   PR:		conf/178504
   Requested by:	many
 
 Modified:
   head/etc/newsyslog.conf
 
 Modified: head/etc/newsyslog.conf
 ==============================================================================
 --- head/etc/newsyslog.conf	Sun May 12 20:44:28 2013	(r250578)
 +++ head/etc/newsyslog.conf	Sun May 12 21:24:18 2013	(r250579)
 @@ -17,23 +17,23 @@
  # future, these defaults may change to more conservative ones.
  #
  # logfilename          [owner:group]    mode count size when  flags [/pid_file] [sig_num]
 -/var/log/all.log			600  7	   *	@T00  X
 -/var/log/amd.log			644  7	   100	*     X
 -/var/log/auth.log			600  7     100  @0101T XC
 -/var/log/console.log			600  5	   100	*     X
 -/var/log/cron				600  3	   100	*     XC
 -/var/log/daily.log			640  7	   *	@T00  XN
 -/var/log/debug.log			600  7     100  *     XC
 -/var/log/init.log			644  3	   100	*     X
 -/var/log/kerberos.log			600  7	   100	*     X
 -/var/log/lpd-errs			644  7	   100	*     XC
 -/var/log/maillog			640  7	   *	@T00  XC
 -/var/log/messages			644  5	   100	@0101T XC
 -/var/log/monthly.log			640  12	   *	$M1D0 XN
 -/var/log/pflog				600  3	   100	*     XB    /var/run/pflogd.pid
 -/var/log/ppp.log	root:network	640  3	   100	*     XC
 -/var/log/security			600  10	   100	*     XC
 +/var/log/all.log			600  7	   *	@T00  J
 +/var/log/amd.log			644  7	   100	*     J
 +/var/log/auth.log			600  7     100  @0101T JC
 +/var/log/console.log			600  5	   100	*     J
 +/var/log/cron				600  3	   100	*     JC
 +/var/log/daily.log			640  7	   *	@T00  JN
 +/var/log/debug.log			600  7     100  *     JC
 +/var/log/init.log			644  3	   100	*     J
 +/var/log/kerberos.log			600  7	   100	*     J
 +/var/log/lpd-errs			644  7	   100	*     JC
 +/var/log/maillog			640  7	   *	@T00  JC
 +/var/log/messages			644  5	   100	@0101T JC
 +/var/log/monthly.log			640  12	   *	$M1D0 JN
 +/var/log/pflog				600  3	   100	*     JB    /var/run/pflogd.pid
 +/var/log/ppp.log	root:network	640  3	   100	*     JC
 +/var/log/security			600  10	   100	*     JC
  /var/log/sendmail.st			640  10	   *	168   BN
  /var/log/utx.log			644  3	   *	@01T05 B
 -/var/log/weekly.log			640  5	   *	$W6D0 XN
 -/var/log/xferlog			600  7	   100	*     XC
 +/var/log/weekly.log			640  5	   *	$W6D0 JN
 +/var/log/xferlog			600  7	   100	*     JC
 _______________________________________________
 svn-src-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/svn-src-all
 To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org"
 

From: Ulrich =?utf-8?B?U3DDtnJsZWlu?= <uqs@FreeBSD.org>
To: freebsd-gnats-submit@freebsd.org
Cc: eadler@freebsd.org
Subject: Re: conf/178504: [patch] switch logs compression from bzip2 to xz
Date: Wed, 15 May 2013 15:50:09 +0200

 This is not only an issue for CPU, but more for RAM. XZ uses a lot more
 RAM to compress files, and if an attacker can spam logfiles fast enough,
 especially those that are not rotated on size, like maillog, then they
 can probably gobble up enough RAM to make it be a problem.
 
 I guess the low entropy of logfiles works in our favor here, however.
 
 Cheers,
 Uli
>Unformatted:
