[ mailman-Feature Requests-1695897 ] patch to rename log files in order to work with logrotate

SourceForge.net noreply at sourceforge.net
Sat Apr 7 03:30:51 CEST 2007


Feature Requests item #1695897, was opened at 2007-04-06 21:30
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=350103&aid=1695897&group_id=103

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Jim Popovitch (jimpop)
Assigned to: Nobody/Anonymous (nobody)
Summary: patch to rename log files in order to work with logrotate

Initial Comment:
Mailman needs to have different log file names in order to work properly with logrotate.  A proper Logrotate conf file for Mailman needs a postrotate command in order to restart Mailman after log files have been rotated.  See FAQ 04.007 for more details (http://www.python.org/cgi-bin/faqw-mm.py?req=edit&file=faq04.007.htp)

Here is a patch against v2.1.9

-------------------------
+++ Logging/Logger.py           2007-04-06 21:11:18.600639072 -0400
--- Logging/Logger.py.old       2007-04-06 21:10:05.672725800 -0400
@@ -43,7 +43,6 @@
         Otherwise, the file is created only when there are writes pending.
         """
         self.__filename = os.path.join(mm_cfg.LOG_DIR, category)
+        self.__filename += '.log'
         self.__fp = None
         self.__nofail = nofail
         self.__encoding = LOG_ENCODING or sys.getdefaultencoding()
-------------------------

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=350103&aid=1695897&group_id=103


More information about the Mailman-coders mailing list