Jdbc input plugin -- cannot locate last_run_metadata_path

Hello ,

I am using logstash 2.3 in an Ubuntu 14.04 , not as a service ( just extracted the tar.gz ). I successfully ran logstash jdbc input plugin and fetched some data from my sql server. Now I wanna re run the same , i forgot to set record_last_run to false during the test run. Now when i try to re run it logstasg is standing still.. How can i get it to read the data again? I tried to locate .logstash_jdbc_last_run with no luck.



On windows, it is in the main directory of the user (C:/Users/%username%).
Did you try in /root, /home/user or even in /tmp (where applications data are)?

Yeah... i checked all of them... in /root , /home as well as tmp. Its not there.. when i echo the $USER_HOME its an empty line. I assume its not set...

1 Like

If you look at the input-jdbc configuration, you have

Path to file with last run time

config :last_run_metadata_path, :validate => :string, :default => "#{ENV['HOME']}/.logstash_jdbc_last_run"

Or just male a "Select * from table" without using sql_last_run, that should be working correctly.

1 Like