Menu

#2731 dtm: Make trace file size and number of backups configurable

5.18.04
fixed
None
enhancement
dtm
-
minor
False
2018-03-16
2017-12-06
No

Currently, the OpenSAF trace file size is limited to 5 MB, and the number of backups to nine. If a longer trace is needed, we would need to make the file size and / or number of backups configurable.

Solution:

To make the trace file size and number of backups configurable we are introducing the transportd.conf like below. This file was read in startup of transportd and logwriter will be configured with below values. If we want to change these values dynamically the transportd.conf was read in SIGUSR2 handling and propagated to newly created streams and logwriter objects. Already created streams and log writer objects are not touched

# This file contains configuration for the Transportd service
# See the file osaf/services/infrastructure/dtm/README for more configuration options.

#
# TRANSPORT_MAX_LOG_FILESIZE: The  maximum size of the log file. The size value should
# be in MB's i.e if you give 6 then it is treated as 6 MB. By default value will be
# 5 MB
TRANSPORT_MAX_LOG_FILESIZE=5

#
# TRANSPORT_NO_OF_BACKUP_LOG_FILES: Number of backup files to maintain. Log rotation will
# be done based on this value. Default value will be 9
# i.e totally 10 log files will be maintain.
TRANSPORT_NO_OF_BACKUP_LOG_FILES=9

Related

Tickets: #2812
Wiki: ChangeLog-5.18.04
Wiki: NEWS-5.18.04

Discussion

  • Ravi Sekhar Reddy

    • status: unassigned --> assigned
    • assigned_to: syam prasad talluri
     
  • syam prasad talluri

    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -1 +1,21 @@
     Currently, the OpenSAF trace file size is limited to 5 MB, and the number of backups to nine. If a longer trace is needed, we would need to make the file size and / or number of backups configurable.
    +
    +Solution: 
    +
    +To make the trace file size and number of backups configurable we are introducing the transportd.conf like below. This file was read in startup of transportd and logwriter will be configured with below values. If we want to change these values dynamically the transportd.conf was read in SIGUSR2 handling and propagated to newly created streams and logwriter objects. Already created streams and log writer objects are not touched 
    +~~~
    +# This file contains configuration for the Transportd service
    +# See the file osaf/services/infrastructure/dtm/README for more configuration options.
    +
    +#
    +# TRANSPORT_MAX_LOG_FILESIZE: The  maximum size of the log file. The size value should
    +# be in MB's i.e if you give 6 then it is treated as 6 MB. By default value will be
    +# 5 MB
    +TRANSPORT_MAX_LOG_FILESIZE=5
    +
    +#
    +# TRANSPORT_NO_OF_BACKUP_LOG_FILES: Number of backup files to maintain. Log rotation will
    +# be done based on this value. Default value will be 9
    +# i.e totally 10 log files will be maintain.
    +TRANSPORT_NO_OF_BACKUP_LOG_FILES=9
    +~~~
    
     
  • Ravi Sekhar Reddy

    • status: assigned --> review
     
  • Anders Widell

    Anders Widell - 2018-02-02
    • Milestone: 5.18.01 --> 5.18.04
     
  • syam prasad talluri

    • status: review --> fixed
     
  • syam prasad talluri

    Pushed to the repo using the below commit. PR document has to be updated for this change I will update it.

    commit 4ef784cb003573376727e4f4539129326d3e4ab2
    Author: syam-talluri syam.talluri@oracle.com
    Date: Fri Mar 16 15:15:12 2018 +0530

    dtm: Added following options  --max-backups and --max-file-size to osaflog tool and in transportd [#2731]
    
     

Log in to post a comment.