Unable to connect to SQL database using jdbc driver

Hi

Am experiencing connection issues when trying to connect to sql database using jdbc driver.
I'm using intergrated security for connection but error shows l require a jdbc user. Is it correct to be requested of a username when using intergrated security ?

See below connection string and logstash error log

input {
jdbc {
# SqlServer jdbc connection string to our database, employeedb
# "jdbc:sqlserver://HostName\instanceName;database=DBName;user=UserName;password=Password"
jdbc_connection_string => "jdbc:sqlserver://MPWETLP1/databaseName=DBName;integratedSecurity=true"
# The path to our downloaded jdbc driver
jdbc_driver_library => "C:\Program Files\Microsoft JDBC Driver 6.2 for SQL Server\sqljdbc_6.2\enu\sqljdbc4-2.0.jar"
# The name of the driver class for SqlServer
jdbc_driver_class => "com.microsoft.sqlserver.jdbc.SQLServerDriver"
# Query for testing purpose
statement => "SELECT TOP 10 * from dbo.EB_Errorlog"
}
}

output {
#stdout { codec => json_lines }
elasticsearch {
hosts => ["localhost:9200"]
}
}

[2019-10-30T13:37:31,403][INFO ][logstash.runner ] Starting Logstash {"logstash.version"=>"7.3.1"}
[2019-10-30T13:37:31,809][INFO ][org.reflections.Reflections] Reflections took 47 ms to scan 1 urls, producing 19 keys and 39 values
[2019-10-30T13:37:31,903][ERROR][logstash.inputs.jdbc ] Missing a required setting for the jdbc input plugin:

input {
jdbc {
jdbc_user => # SETTING MISSING
...
}
}
[2019-10-30T13:37:31,903][ERROR][logstash.agent ] Failed to execute action {:action=>LogStash::PipelineAction::Create/pipeline_id:main, :exception=>"LogStash::ConfigurationError", :message=>"Something is wrong with your configuration.", :backtrace=>["C:/ELK-Stack/logstash-7.3.1/logstash-core/lib/logstash/config/mixin.rb:87:in config_init'", "C:/ELK-Stack/logstash-7.3.1/logstash-core/lib/logstash/inputs/base.rb:60:in initialize'", "org/logstash/plugins/PluginFactoryExt.java:258:in plugin'", "org/logstash/plugins/PluginFactoryExt.java:120:in buildInput'", "org/logstash/execution/JavaBasePipelineExt.java:50:in initialize'", "C:/ELK-Stack/logstash-7.3.1/logstash-core/lib/logstash/java_pipeline.rb:24:in initialize'", "C:/ELK-Stack/logstash-7.3.1/logstash-core/lib/logstash/pipeline_action/create.rb:36:in execute'", "C:/ELK-Stack/logstash-7.3.1/logstash-core/lib/logstash/agent.rb:325:in block in converge_state'"]}
[2019-10-30T13:37:32,106][INFO ][logstash.agent ] Successfully started Logstash API endpoint {:port=>9600}
[2019-10-30T13:37:37,227][INFO ][logstash.runner ] Logstash shut down.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.