Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to install logstash on windows 7

Tags:

logstash

How to install logstash on Windows 7?

I install zip file which size is 90 mb and then version is logstash-1.5.0 and extract then file and move it to the bath C:\Logstash

When I run:

C:\Logstash\logstash-1.5.0\bin\logstash

I have the following message:

io/console not supported; tty will not be manipulated
No command given

Usage: logstash  [command args]
Run a command with the --help flag to see the arguments.
For example: logstash agent --help

Available commands:
  agent - runs the logstash agent
  version - emits version info about this logstash

any help thank you

like image 684
Tariq Turabi Avatar asked May 29 '15 19:05

Tariq Turabi


3 Answers

The most simple way to get started and verify that your logstash is working is to start it with the following command

logstash -e 'input { stdin { } } output { stdout {} }'

this means that logstash will echo what you type in the console back out to the console, for example:

C:\logstash\bin>logstash -e 'input { stdin { } } output { stdout {} }'
io/console not supported; tty will not be manipulated Settings:
Default filter workers: 4 Logstash startup completed
I typed this
2015-12-11T09:22:22.349Z MY_PC I typed this
and then I typed this
2015-12-11T09:22:26.218Z MY_PC and then I typed this

The next thing to do is read an input from something else, for example your windows logs. For this you can save a config file to your bin folder, it can be called anything, for instance 'logstash.config'. Contents as below

# contents of logstash\bin\logstash.config

input {
  eventlog {
    type  => 'Win32-EventLog'
    logfile  => 'System'
  }
}
output {
  stdout {  }
}

If you then run

logstash -f logstash.config

Leave this running for a bit and you will see that your windows event log gets written out to the console. (You could trigger some events by running iisreset in a different console.)

not sure why is says "io/console not supported; tty will not be manipulated", probably because it is running in a windows console, but logstash is still working.

like image 196
Dr Blowhard Avatar answered Oct 06 '22 01:10

Dr Blowhard


Make a conf file and paste it in bin folder of logstash and type in cmd logstash/bin>logstash agent -f logstash.conf

like image 24
Vivek Gupta Avatar answered Oct 05 '22 23:10

Vivek Gupta


You have to run logstash manually by command in windows 7. tc-log.conf is my conf file. lslog.log is my log file. Change directory to the bin folder of logstash and run following command .

*make sure that you have done changes in command as per yours.

logstash agent -f D:/cloud/logstash-1.4.2/tc-log.conf -l D:/cloud/logstash-1.4.2/logs/lslog.log –verbose
like image 34
A.N.B Akhilesh Avatar answered Oct 06 '22 00:10

A.N.B Akhilesh