<?xml version="1.0" encoding="UTF-8"?><rss
version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
> <channel><title>Comments on: Rotating Linux Log Files</title> <atom:link href="http://www.ducea.com/2006/06/06/rotating-linux-log-files/feed/" rel="self" type="application/rss+xml" /><link>http://www.ducea.com/2006/06/06/rotating-linux-log-files/</link> <description>The Journal Of A Linux Sysadmin</description> <lastBuildDate>Wed, 08 Feb 2012 13:08:17 +0000</lastBuildDate> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3</generator> <item><title>By: harish</title><link>http://www.ducea.com/2006/06/06/rotating-linux-log-files/comment-page-1/#comment-183643</link> <dc:creator>harish</dc:creator> <pubDate>Thu, 02 Dec 2010 04:22:17 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/06/rotating-linux-log-files/#comment-183643</guid> <description>/var/log/ftp.log file size is big.
i would like to ratate file with cron for monthly scheduld.
please help me for &#039;Logrotate&#039; script.</description> <content:encoded><![CDATA[<p>/var/log/ftp.log file size is big.<br
/> i would like to ratate file with cron for monthly scheduld.<br
/> please help me for &#8216;Logrotate&#8217; script.</p> ]]></content:encoded> </item> <item><title>By: mike</title><link>http://www.ducea.com/2006/06/06/rotating-linux-log-files/comment-page-1/#comment-183618</link> <dc:creator>mike</dc:creator> <pubDate>Mon, 29 Nov 2010 18:40:27 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/06/rotating-linux-log-files/#comment-183618</guid> <description>I have a one question. Maybe someone know, how to set the system to start rotation (creating archives, etc.) by starting system?</description> <content:encoded><![CDATA[<p>I have a one question. Maybe someone know, how to set the system to start rotation (creating archives, etc.) by starting system?</p> ]]></content:encoded> </item> <item><title>By: Linux Logrotate Setup &#171; Eager to Code, Enjoy to Debug ~ Embark into Each Stage with Your Heart</title><link>http://www.ducea.com/2006/06/06/rotating-linux-log-files/comment-page-1/#comment-178157</link> <dc:creator>Linux Logrotate Setup &#171; Eager to Code, Enjoy to Debug ~ Embark into Each Stage with Your Heart</dc:creator> <pubDate>Sun, 29 Jun 2008 08:54:35 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/06/rotating-linux-log-files/#comment-178157</guid> <description>[...] Further information about logrotate:- http://linuxcommand.org/man_pages/logrotate8.html http://www.ducea.com/2006/06/06/rotating-linux-log-files/ [...]</description> <content:encoded><![CDATA[<p>[...] Further information about logrotate:- <a
href="http://linuxcommand.org/man_pages/logrotate8.html" rel="nofollow">http://linuxcommand.org/man_pages/logrotate8.html</a> <a
href="http://www.ducea.com/2006/06/06/rotating-linux-log-files/" rel="nofollow">http://www.ducea.com/2006/06/06/rotating-linux-log-files/</a> [...]</p> ]]></content:encoded> </item> <item><title>By: - Marius -</title><link>http://www.ducea.com/2006/06/06/rotating-linux-log-files/comment-page-1/#comment-194</link> <dc:creator>- Marius -</dc:creator> <pubDate>Thu, 08 Jun 2006 15:02:03 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/06/rotating-linux-log-files/#comment-194</guid> <description>fak3r ,Thank you very much for your nice words. It really helps to know that other peoples find useful what I am writing. This is really the greatest reward I can expect when doing this...Regarding your comment about syslog... there is an option in syslog that could have been useful to you:
&lt;strong&gt;olddir &quot;directory&quot;
= old logs are moved into &quot;directory&quot; for rotation&lt;/strong&gt;
But this has an important limitation: olddir must be on the same physical drive as the log file being rotated. Now depending from your case this could have been useful (if the partition was the problem and you had enough space on another partition), or not (if you needed the logs saved on another drive - still you could have solved this by placing the logs on that drive in the first place, and solve it like that). Anyway if you are happy with the solution you found, then this is all that matters. This is the beauty of the Linux world that you can find so many different solutions to achieve the same purpose.Cheers
- Marius -</description> <content:encoded><![CDATA[<p>fak3r ,</p><p>Thank you very much for your nice words. It really helps to know that other peoples find useful what I am writing. This is really the greatest reward I can expect when doing this&#8230;</p><p>Regarding your comment about syslog&#8230; there is an option in syslog that could have been useful to you:<br
/> <strong>olddir &#8220;directory&#8221;<br
/> = old logs are moved into &#8220;directory&#8221; for rotation</strong><br
/> But this has an important limitation: olddir must be on the same physical drive as the log file being rotated. Now depending from your case this could have been useful (if the partition was the problem and you had enough space on another partition), or not (if you needed the logs saved on another drive &#8211; still you could have solved this by placing the logs on that drive in the first place, and solve it like that). Anyway if you are happy with the solution you found, then this is all that matters. This is the beauty of the Linux world that you can find so many different solutions to achieve the same purpose.</p><p>Cheers<br
/> - Marius -</p> ]]></content:encoded> </item> <item><title>By: fak3r</title><link>http://www.ducea.com/2006/06/06/rotating-linux-log-files/comment-page-1/#comment-193</link> <dc:creator>fak3r</dc:creator> <pubDate>Thu, 08 Jun 2006 14:07:02 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/06/rotating-linux-log-files/#comment-193</guid> <description>Marius
This is a great primer, wish I would have found it a year back when I was trying to learn this stuff, the docs confused me (Google for examples came to the rescue then) but I needed to learn since my hardrive (and /var in particular) was smaller thna I wanted.  Now I&#039;m using &lt;a href=&quot;http://www.weird.com/~woods/projects/newsyslog.html&quot; rel=&quot;nofollow&quot;&gt;newsyslog&lt;/a&gt;, sort of an enhanced version of syslog; same basic principals apply, but is gaining popularity among the *BSDs (but can be compiled/installed for Linux easily too, prob in debs).  I write HOWTOs on my site as well, but most aren&#039;t this detailed, as this could serve the community better than the project&#039;s current doc.fak3r</description> <content:encoded><![CDATA[<p>Marius<br
/> This is a great primer, wish I would have found it a year back when I was trying to learn this stuff, the docs confused me (Google for examples came to the rescue then) but I needed to learn since my hardrive (and /var in particular) was smaller thna I wanted.  Now I&#8217;m using <a
href="http://www.weird.com/~woods/projects/newsyslog.html" rel="nofollow">newsyslog</a>, sort of an enhanced version of syslog; same basic principals apply, but is gaining popularity among the *BSDs (but can be compiled/installed for Linux easily too, prob in debs).  I write HOWTOs on my site as well, but most aren&#8217;t this detailed, as this could serve the community better than the project&#8217;s current doc.</p><p>fak3r</p> ]]></content:encoded> </item> <item><title>By: - Marius -</title><link>http://www.ducea.com/2006/06/06/rotating-linux-log-files/comment-page-1/#comment-190</link> <dc:creator>- Marius -</dc:creator> <pubDate>Wed, 07 Jun 2006 23:05:50 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/06/rotating-linux-log-files/#comment-190</guid> <description>Chris,Thank you very much for your comment. I too find that the dateext option quite cool, especially for rotating apache log files daily (at least here I have needed it). If you will save the logs for an extended period of time then this is quite a great option to use.The way RedHat based systems (RHEL, Fedora, Centos, etc) handle the rotation of &#039;system log files&#039; is a little different than in Debian based systems: this is handled by logrotate itself, and actually I will post an update to the original post, to not create confusions about this. I don&#039;t have a Suse system available to look at it but I assume that it will follow the RedHat path, but please confirm that if you can. Thanks.</description> <content:encoded><![CDATA[<p>Chris,</p><p>Thank you very much for your comment. I too find that the dateext option quite cool, especially for rotating apache log files daily (at least here I have needed it). If you will save the logs for an extended period of time then this is quite a great option to use.</p><p>The way RedHat based systems (<a
href="http://www.redhat.com/rhel/" class="ubernym uttAcronym"><acronym
class="uttAcronym" title="Red Hat Enterprise Linux">RHEL</acronym></a>, Fedora, Centos, etc) handle the rotation of &#8216;system log files&#8217; is a little different than in Debian based systems: this is handled by logrotate itself, and actually I will post an update to the original post, to not create confusions about this. I don&#8217;t have a Suse system available to look at it but I assume that it will follow the RedHat path, but please confirm that if you can. Thanks.</p> ]]></content:encoded> </item> <item><title>By: Chris Riney</title><link>http://www.ducea.com/2006/06/06/rotating-linux-log-files/comment-page-1/#comment-189</link> <dc:creator>Chris Riney</dc:creator> <pubDate>Wed, 07 Jun 2006 22:06:55 +0000</pubDate> <guid
isPermaLink="false">http://www.ducea.com/2006/06/06/rotating-linux-log-files/#comment-189</guid> <description>I&#039;m glad that he mentioned that this was based on a Debian systems, since the RedHat &amp; SuSE systems that I work with do not have the syslog &quot;Feature&quot; that is described (must be part of syslogNG which I&#039;m not familiar with).  Both of these major commercial distributions manage the syslog files via logrotate.Actually I&#039;m just starting to work with SuSE Enterprise, and I&#039;m noticing the differences in the way RedHat &amp; SuSE implement scheduling Hourly, Daily, Weekly, &amp; Monthly rotations.A feature of of LogRotate 3.7.x that I found,  (and was looking for) is the &#039;dateext&#039; which appends the rotation date to the end instead of a sequential number.  The problem I have with the sequential number, is that logrotate moves the older log&#039;s up the sequence, which causes those file to be backed-up multiple times with differential backups.One item that you didn&#039;t cover, is how logrotate knows when it is the proper time to rotate a daily, weekly, or monthly file.  Part of that is controlled by the status file (/var/lib/logrotate.status on most Linux system) which tracks when a particular file was last rotated.  The other part is that Monthly rotations are done with the first run of logrotate that month, and Weekly&#039;s are run if the last run was later in the previous week, or the last rotation was over 7 days prior (Sunday=0 Saturday=6).   So if you are running logrotate daily, then it works itself out to the first day of the month, and Sunday&#039;s for the weeklies.</description> <content:encoded><![CDATA[<p>I&#8217;m glad that he mentioned that this was based on a Debian systems, since the RedHat &amp; SuSE systems that I work with do not have the syslog &#8220;Feature&#8221; that is described (must be part of syslogNG which I&#8217;m not familiar with).  Both of these major commercial distributions manage the syslog files via logrotate.</p><p>Actually I&#8217;m just starting to work with SuSE Enterprise, and I&#8217;m noticing the differences in the way RedHat &amp; SuSE implement scheduling Hourly, Daily, Weekly, &amp; Monthly rotations.</p><p>A feature of of LogRotate 3.7.x that I found,  (and was looking for) is the &#8216;dateext&#8217; which appends the rotation date to the end instead of a sequential number.  The problem I have with the sequential number, is that logrotate moves the older log&#8217;s up the sequence, which causes those file to be backed-up multiple times with differential backups.</p><p>One item that you didn&#8217;t cover, is how logrotate knows when it is the proper time to rotate a daily, weekly, or monthly file.  Part of that is controlled by the status file (/var/lib/logrotate.status on most Linux system) which tracks when a particular file was last rotated.  The other part is that Monthly rotations are done with the first run of logrotate that month, and Weekly&#8217;s are run if the last run was later in the previous week, or the last rotation was over 7 days prior (Sunday=0 Saturday=6).   So if you are running logrotate daily, then it works itself out to the first day of the month, and Sunday&#8217;s for the weeklies.</p> ]]></content:encoded> </item> </channel> </rss>
<!-- Served from: www.ducea.com @ 2012-02-08 14:54:11 by W3 Total Cache -->
