Ad Widget

Collapse

[zabbix-1.6.1] logwatch issue

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • tekknokrat
    Senior Member
    • Sep 2008
    • 140

    #1

    [zabbix-1.6.1] logwatch issue

    I want to make use of logwatch feature.
    I created a item with configuration:

    key: log[/var/log/syslog]
    Type of Information: Log File
    Update interval (in sec): 5sec
    Status: Active

    Also I added zabbix to adm group (which is default group for logfile creation in debian) and restartet service.
    But in lastdata no output of logfiles is shown. Any help is appreciated because we are in need on triggering some action based on special logfile entries.
  • tekknokrat
    Senior Member
    • Sep 2008
    • 140

    #2
    without a regex we got it working. problem is when a regex is used theres no output.
    Is the initial search for a regex done from beginning of logfile or is check looking only for new entries?

    Comment

    • tekknokrat
      Senior Member
      • Sep 2008
      • 140

      #3
      this all is again proxy setup. when log messages arrive server they crash the server processs!

      error message is:
      WARNING: nonstandard use of \' in a string literal
      LINE 1: ...e,source,severity) values (124,1232052281,25844,0,'Jan 15 09...
      ^
      HINT: Use '' to write quotes in strings, or use the escape string syntax (E'...').
      WARNING: nonstandard use of \' in a string literal
      LINE 1: ...extcheck=1232052282,prevvalue=lastvalue,lastval ue='Jan 15 09...
      ^
      HINT: Use '' to write quotes in strings, or use the escape string syntax (E'...').
      20397:20090115:224440 [Z3005] Query failed: [0] PGRES_FATAL_ERROR:ERROR: value too long for type character varying(255)
      [update items set nextcheck=1232052282,prevvalue=lastvalue,lastvalue ='Jan 15 09:07:25 192.168.102.32 dnsmasqnotify[31687]: del, ID: XX:XX:XX:XX:XX:XX:XX, IF: br0 IP: 10.13.31.143, MAC: XX:XX:XX:XX:XX:XX, Host: iPhone-440, expires: 1232010136 (-309), agent_id: 01040000000002270018bab687703a42544f70656e7a6f6e65 0000000000000000000000000 ',lastclock=1232052281,lastlogsize=0 where itemid=25844]
      20397:20090115:224440 [Z3005] Query failed: [0] PGRES_FATAL_ERROR:ERROR: current transaction is aborted, commands ignored until end of transaction block
      Last edited by tekknokrat; 15-01-2009, 23:49. Reason: obfuscating mac

      Comment

      • tekknokrat
        Senior Member
        • Sep 2008
        • 140

        #4
        Can someone give a statement to this issue?

        This problems is similar to the bug issued here apart from that in my setup it is distributed monitoring (sqlite proxy) and postgres doesnt accept special chars like quotes.
        The solution to resolve this issue is also in very informative pg-log message, use of double quotes or escape string syntax (E'..').

        EDIT: Also this bug issues the problem https://support.zabbix.com/browse/ZBX-312

        Comment

        • tekknokrat
          Senior Member
          • Sep 2008
          • 140

          #5
          other error that breaks server:

          Query failed: [0] PGRES_FATAL_ERROR:ERROR: invalid byte sequence for encoding "UTF8": 0xfc
          HINT: This error can also happen if the byte sequence does not match the encoding expected by the server, which is controlled by "client_encoding".
          [insert into history_str (clock,itemid,value) values (1232205117,26302,' p�_�')]
          8355:20090117:161201 [Z3005] Query failed: [0] PGRES_FATAL_ERROR:ERROR: invalid byte sequence for encoding "UTF8": 0xfc
          dont know origin of that error atm., only demonstrates again sensibility of server regarding data sent.

          Comment

          • tekknokrat
            Senior Member
            • Sep 2008
            • 140

            #6
            got this partially solved with altering the columns prevvalue/lastvalue of table items to character varying(1024). At least no servercrash atm.

            Comment

            Working...