Making db2 use syslog

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Troels Arvin

    #1

    Making db2 use syslog

    Hello,

    On a server with DB2 v. 8.2, db2diag.log ran full, it seems (i.e. reached
    a size of 2GB). And it seems that in this case, DB2 started using syslog
    instead.

    I would actually like DB2 to use syslog instead of / in addition to the
    local log files, not only in case of a problem with the local log files.
    Is that possible?

    (The large db2diag.log file is because of heaps of 'DIA8036C XA error
    with request type of "". Transaction was not found.' messages which noone
    seems to know how to get rid of.)

    --
    Regards,
    Troels Arvin <troels@arvin.d k>

  • Oliver

    #2
    Re: Making db2 use syslog

    Troels,

    I don't know if it is possible to switch to syslog (I don't think so),
    but you may want to use logrotate instead (see 'man logrotate')! You
    should also consider to switch the notify log.

    HTH, Oliver.

    On Feb 15, 2:03 pm, Troels Arvin <tro...@arvin.d kwrote:
    Hello,
    >
    On a server with DB2 v. 8.2, db2diag.log ran full, it seems (i.e. reached
    a size of 2GB). And it seems that in this case, DB2 started using syslog
    instead.
    >
    I would actually like DB2 to use syslog instead of / in addition to the
    local log files, not only in case of a problem with the local log files.
    Is that possible?
    >
    (The large db2diag.log file is because of heaps of 'DIA8036C XA error
    with request type of "". Transaction was not found.' messages which noone
    seems to know how to get rid of.)
    >
    --
    Regards,
    Troels Arvin <tro...@arvin.d k>http://troels.arvin.dk/

    Comment

    • Sanjuro

      #3
      Re: Making db2 use syslog

      On Feb 15, 7:03 am, Troels Arvin <tro...@arvin.d kwrote:
      Hello,
      >
      On a server with DB2 v. 8.2, db2diag.log ran full, it seems (i.e. reached
      a size of 2GB). And it seems that in this case, DB2 started using syslog
      instead.
      >
      I would actually like DB2 to use syslog instead of / in addition to the
      local log files, not only in case of a problem with the local log files.
      Is that possible?
      >
      (The large db2diag.log file is because of heaps of 'DIA8036C XA error
      with request type of "". Transaction was not found.' messages which noone
      seems to know how to get rid of.)
      >
      --
      Regards,
      Troels Arvin <tro...@arvin.d k>http://troels.arvin.dk/
      This is a fairly old thread and you might have already found your
      solution.

      Large DB2 shops employ various diaglog management strategies. One
      common method is to have a script that renames the db2diag.log on a
      daily basis and deletes files older than a specified retention
      interval. To reduce amount of log messages your instance generates,
      you can always reduce diaglevel parameter in DBM configuration (0
      being lowest and 4 being highest). If you want to diagnose a problem,
      you can always switch it back to 4. By default this diaglevel is set
      to 3. You can also set the diagpath parameter to a location on a file
      system separate from your DB2 home.

      In one shop (Windows), the Sysadmin wanted to have a central SYSLOG
      database to store all log messages from all environments. He toyed
      with several free open source (free) and vendor tools but that project
      never materialized. You may explore different options there. The
      initial plan there was to make DB2 write to a network mapped location
      and then have his tool to read from there and insert into the SYSLOG
      database.

      Cheers,
      Sanjuro

      Comment

      • roger.kavallin@gmail.com

        #4
        Re: Making db2 use syslog

        You don't need a script to rename db2diag.log, use db2diag -A ..
        archives the db2diag.log to db2diag.log_yyy y-mm-dd-hh.mm.ss

        Comment

        Working...