What I am trying to accomplish is execute sql query against our mssql database, pass that data to ES stack in cloud.
To my understanding I have to take following actions,
install jdk on windows client where i ll be sending data from,
install logstash on windows client where i ll be sending data from,
install logstash-input-jdbc on windows client where i ll be sending data from,
change logstash.conf to add cloud id and user credentials,
create data-out.conf file like below,
input {
jdbc {
jdbc_driver_library => "sqljdbc4.jar"
jdbc_driver_class => "com.microsoft.sqlserver.jdbc.SQLServerDriver"
jdbc_connection_string => "jdbc:sqlserver://192.168.2.126\\SQLEXPRESS2014:1433;databaseName=test
jdbc_password => "sa@sa2015"
schedule => "0 0-59 0-23 * * *"
statement => "SELECT ID , Name, City, State,ShopName FROM dbo.Shops"
jdbc_paging_enabled => "true"
jdbc_page_size => "50000"
}
}
filter {
}
output {
stdout { codec => rubydebug }
elasticsearch {
protocol => "http"
index => "shops"
document_id => "%{id}"
}
}
create index on ES Kibana UI.
What confuses me is "elasticsearch { protocol => "http"" section. Will this "data-out.conf" find the cloud ES instance by checking against main "logstash.conf"?