# First time trying to load data from mysql db to elasticsearch, need help with config file

**URL:** https://discuss.elastic.co/t/first-time-trying-to-load-data-from-mysql-db-to-elasticsearch-need-help-with-config-file/149673
**Category:** Logstash
**Created:** [September 24, 2018, 12:35pm UTC](https://discuss.elastic.co/t/first-time-trying-to-load-data-from-mysql-db-to-elasticsearch-need-help-with-config-file/149673 "2018-09-24T12:35:21Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Prakti](https://avatars.discourse-cdn.com/v4/letter/p/96bed5/32.png) [@Prakti](https://discuss.elastic.co/u/Prakti)
#### Post date: [September 24, 2018, 12:35pm UTC](https://discuss.elastic.co/t/first-time-trying-to-load-data-from-mysql-db-to-elasticsearch-need-help-with-config-file/149673/1 "2018-09-24T12:35:21Z")

</div>

Hi all,  
I'm new to ELK and I installed everything. I now want to fetch my first table from a mySQL db. I created a sample.conf file whitch I run from my command window with:

`C:\...\logstash-6.4.1\bin\logstash.bat -f sample.conf`

I get the following output from cmd:

```
Sending Logstash logs to C:/.../logstash-6.4.1/logs which is now configured via log
[2018-09-24T14:26:37,840][WARN][logstash.config.source.multilocal] Ignoring the 'pipelines.yml' file because modules o
 specified
[2018-09-24T14:26:38,230][INFO][logstash.runner] Starting Logstash {"logstash.version"=>"6.4.1"}
[2018-09-24T14:26:38,277][INFO][logstash.config.source.local.configpathloader] No config files found in path {:path=>"
ash-sample.conf"}
[2018-09-24T14:26:38,292][ERROR][logstash.config.sourceloader] No configuration found in the configured sources.
[2018-09-24T14:26:38,511][INFO][logstash.agent] Successfully started Logstash API endpoint {:port=>9600}

```

My .conf file looks like this:

```
input {
  jdbc {
    jdbc_driver_library => "mysql-connector-java-8.0.12-bin.jar"
    jdbc_driver_class => "com.mysql.jdbc.Driver"
    jdbc_connection_string => jdbc:mysql://http://localhost/phpmyadmin/db_structure.php?db=db"
    jdbc_user => "root"
    jdbc_password => ""
    statement => "SELECT title FROM `cgp1r_content` WHERE 1"
  }
}
filter{
}
output{
stdout { codec => json_lines }
   elasticsearch {
   hosts => ["localhost:9200"] 
   index => "content"
}
}

```

The Index is set up on Elasticsearch and the table in mySQL exits. I don't think my problem is there.

I'm using

- Elasticsearch 6.4.0
- Kibana 6.4.1
- Logstash 6.4.1

I looked through various posts already but i can't find the exact problem anywhere else.

If you have any tips, suggestions or anything else I'd be really happy.  
If you need more information just ask.

Thanks in advance

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [October 22, 2018, 12:35pm UTC](https://discuss.elastic.co/t/first-time-trying-to-load-data-from-mysql-db-to-elasticsearch-need-help-with-config-file/149673/2 "2018-10-22T12:35:22Z")

</div>

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