• logstash nginx 报ArgumentError: comparison of String with 5 failed


     80.82.78.38 [23/Sep/2016:05:36:18 +0800] "GET http://www.baidu.com/cache/global/img/gs.gif HTTP/1.1" - 404 162 "-" "Mozilla" 0.000 -
     
     需要补一刀;
     %{IPORHOST:clientip} [%{HTTPDATE:time}] "%{WORD:verb} (?<http_url>S+)s+HTTP/%{NUMBER:httpversion}"s+-s+%{NUMBER:http_status_code}s+%{NUMBER:bytes}s+"-"s+"(?<http_user_agent>(S+))"s+(%{BASE16FLOAT:request_time})s+(%{IPORHOST:http_x_forwarded_for}|-)
     
     
     
     
     echo '80.82.78.38 [23/Sep/2016:05:36:18 +0800] "GET http://www.baidu.com/cache/global/img/gs.gif HTTP/1.1" - 404 162 "-" "Mozilla" 0.000 -' >>access.log 
    ArgumentError: comparison of String with 5 failed
                 >= at org/jruby/RubyComparable.java:155
                 >= at org/jruby/RubyString.java:1853
        output_func at (eval):145
       output_batch at /usr/local/logstash-2.3.4/vendor/bundle/jruby/1.9/gems/logstash-core-2.3.4-java/lib/logstash/pipeline.rb:293
               each at org/jruby/RubyArray.java:1613
             inject at org/jruby/RubyEnumerable.java:852
       output_batch at /usr/local/logstash-2.3.4/vendor/bundle/jruby/1.9/gems/logstash-core-2.3.4-java/lib/logstash/pipeline.rb:287
        worker_loop at /usr/local/logstash-2.3.4/vendor/bundle/jruby/1.9/gems/logstash-core-2.3.4-java/lib/logstash/pipeline.rb:232
      start_workers at /usr/local/logstash-2.3.4/vendor/bundle/jruby/1.9/gems/logstash-core-2.3.4-java/lib/logstash/pipeline.rb:201
      
      
      jrhwpt02:/var/log/nginx# echo '80.82.78.38 [23/Sep/2016:05:36:18 +0800] "GET http://www.baidu.com/cache/global/img/gs.gif HTTP/1.1" - 404 162 "-" "Mozilla" 0.000 -' >>access.log 
    You have new mail in /var/spool/mail/root
      
      {
                "@version" => "1",
              "@timestamp" => "2016-09-22T21:36:18.000Z",
                    "path" => "/data01/applog_backup/zjzc_log/zj-frontend02-access.2016-09-23",
                    "host" => "dr-mysql01.zjcap.com",
                    "type" => "zj_frontend_access",
                "clientip" => "80.82.78.38",
                    "time" => "23/Sep/2016:05:36:18 +0800",
                    "verb" => "GET",
                "http_url" => "http://www.baidu.com/cache/global/img/gs.gif",
             "httpversion" => "1.1",
        "http_status_code" => "404",
                   "bytes" => "162",
         "http_user_agent" => "Mozilla",
           "response_time" => 0.0,
                "messager" => "zj_frontend_access 80.82.78.38 [23/Sep/2016:05:36:18 +0800] "GET http://www.baidu.com/cache/global/img/gs.gif HTTP/1.1" - 404 162 "-" "Mozilla" 0.000 -"
    }
    ok

  • 相关阅读:
    尝试搭建springcloud项目(二)客户端client
    IDEA不识别yml
    尝试搭建springcloud项目(一)服务注册中心 Eureka
    curl与XPath
    curl发起网络请求
    Laravel Redis分布式锁的使用
    php 获取excel表格里面的数据
    php+redis实现简单秒杀抢购功能
    微信公众号模板消息推送
    永中,文档预览和转换的第三方平台
  • 原文地址:https://www.cnblogs.com/hzcya1995/p/13350226.html
Copyright © 2020-2023  润新知