Hi Team,
I am using Logstash tool to sync(transfer) Oracle DB data to ElasticSearch index.
I am running Logstash as a windows service in a Remote Windows server machine.
I have run Logstash on Friday(24-6-2022 around 8PM).
After 1 hour, I log out from Remote Windows.
Today I have opened the logs: it is showing below log message::
[2022-06-24T09:01:43,438][INFO ][logstash.inputs.jdbc ][main][71f8cffeecea603df3eeab7722a780385060501c5ccd6bb01ddff67e7652dc7d] (0.004860s) SELECT req.ID,req.BU_COUNTRY,req.BUID,req.CFO_ACTION,req.CFO_SUB_TYPE,req.CFO_TYPE,req.DELIVERY_METHOD,req.DOC_NUMBER,req.CORRELATION_ID,req.ORIGINATOR,req.ORDER_NUMBER,req.STATUS_CODE_ID,req.CREATED_DATE,req.LAST_UPDATE_DATE,req.DELIVERY_DATE,req.MSG_ID,req.RESPONSE_CODE,req.IS_ACTIVE,code.STATUS_DESC FROM request req,statuscode code WHERE req.STATUS_CODE_ID=code.ID AND req.last_update_date > TIMESTAMP '2022-06-24 05:23:02.095000 +00:00' AND req.originator='Veritas' AND req.cfo_type='PO_Match'
[2022-06-24T09:01:45,822][INFO ][logstash.inputs.jdbc ][main][71f8cffeecea603df3eeab7722a780385060501c5ccd6bb01ddff67e7652dc7d] (0.004328s) SELECT req.ID,req.BU_COUNTRY,req.BUID,req.CFO_ACTION,req.CFO_SUB_TYPE,req.CFO_TYPE,req.DELIVERY_METHOD,req.DOC_NUMBER,req.CORRELATION_ID,req.ORIGINATOR,req.ORDER_NUMBER,req.STATUS_CODE_ID,req.CREATED_DATE,req.LAST_UPDATE_DATE,req.DELIVERY_DATE,req.MSG_ID,req.RESPONSE_CODE,req.IS_ACTIVE,code.STATUS_DESC FROM request req,statuscode code WHERE req.STATUS_CODE_ID=code.ID AND req.last_update_date > TIMESTAMP '2022-06-24 05:23:02.095000 +00:00' AND req.originator='Veritas' AND req.cfo_type='PO_Match'
[2022-06-24T09:01:47,830][INFO ][logstash.inputs.jdbc ][main][71f8cffeecea603df3eeab7722a780385060501c5ccd6bb01ddff67e7652dc7d] (0.005127s) SELECT req.ID,req.BU_COUNTRY,req.BUID,req.CFO_ACTION,req.CFO_SUB_TYPE,req.CFO_TYPE,req.DELIVERY_METHOD,req.DOC_NUMBER,req.CORRELATION_ID,req.ORIGINATOR,req.ORDER_NUMBER,req.STATUS_CODE_ID,req.CREATED_DATE,req.LAST_UPDATE_DATE,req.DELIVERY_DATE,req.MSG_ID,req.RESPONSE_CODE,req.IS_ACTIVE,code.STATUS_DESC FROM request req,statuscode code WHERE req.STATUS_CODE_ID=code.ID AND req.last_update_date > TIMESTAMP '2022-06-24 05:23:02.095000 +00:00' AND req.originator='Veritas' AND req.cfo_type='PO_Match'
[2022-06-24T09:01:48,190][WARN ][logstash.runner ] SIGINT received. Shutting down.
[2022-06-24T09:01:48,681][FATAL][logstash.runner ] SIGINT received. Terminating immediately..
**[2022-06-24T09:01:48,904][FATAL][org.logstash.Logstash ] **
org.jruby.exceptions.ThreadKill: null
Could you please help me to resolve this issue?
This is my logstash configuration:
input {
jdbc {
clean_run => true
jdbc_driver_library => "C:\Users\User1\WorkingDirectory\Softwares\logstash-7.17.4\ojdbc8.jar"
jdbc_driver_class => "Java::oracle.jdbc.driver.OracleDriver"
jdbc_connection_string => "jdbc:oracle:thin:@db1-cname.us.domain.com:1521/db1.sit.domain.com"
jdbc_user => "password"
jdbc_password => "password$123"
schedule => "*/1 * * * * *"
statement => "SELECT req.ID,req.BU_COUNTRY,req.BUID,req.CFO_ACTION,req.CFO_SUB_TYPE,req.CFO_TYPE,req.DELIVERY_METHOD,req.DOC_NUMBER,req.CORRELATION_ID,req.ORIGINATOR,req.ORDER_NUMBER,req.STATUS_CODE_ID,req.CREATED_DATE,req.LAST_UPDATE_DATE,req.DELIVERY_DATE,req.MSG_ID,req.RESPONSE_CODE,req.IS_ACTIVE,code.STATUS_DESC FROM request req,statuscode code WHERE req.STATUS_CODE_ID=code.ID AND req.last_update_date > :sql_last_value AND req.originator='Veritas' AND req.cfo_type='PO_Match'"
use_column_value => true
tracking_column => "last_update_date"
tracking_column_type => "timestamp"
}
}
filter {
mutate {
remove_field => ["@version", "@timestamp"]
}
}
output {
elasticsearch{
hosts => ["https://abcb01.us.domain.com:9200","https://audb02.us.domain.com:9200","https://aub03.us.domain.com:9200"]
index => "testsit2"
user => "devapp01"
password => "devapp01"
ssl => true
ssl_certificate_verification => true
cacert => 'C:\Users\User1\WorkingDirectory\Softwares\logstash-7.17.4\nonprodescertificate.cer'
document_id => "%{id}"
doc_as_upsert => true
}
}
Could you please help me out to run Logstash Continuously?