ログ分析や可視化の基盤として有名なSplunkの構築手順をまとめました。下記の手順ではCentOS7上でSplunk7.1.2を動かしています。
1. トライアル版をダウンロード
Splunk Enterprise(商用版)は60日のフリートライアルが可能です。ソフトウェアのダウンロードはSplunkのホームページでユーザーを作成・ログインし、「Free Splunk」→「Down Free 60-Day Trial」→「Linux」タブから.tgzをダウンロードしサーバに格納します。
https://www.splunk.com/
2. 解凍して実行
先ほどのtgzファイルを格納したフォルダに移動し、以下コマンドで解凍、実行します。
# cd /opt/splunk/bin
# ./splunk start
このあと、「SPLUNK SOFTWARE LICENSE AGREEMENT」が表示されるためすべて表示させて「y」を入力します。
ログインパスワードの設定を求められるため入力します。
Create credentials for the administrator account.
Characters do not appear on the screen when you type the password.
Password must contain at least:
* 8 total printable ASCII character(s).
Please enter a new password:
Please confirm new password:
3. Splunkにアクセス
以下URLにアクセスし、ログインします。
http://サーバのIPアドレス:8000/ja-JP/
Username:admin
Password:設定した文字列
4. 起動設定
最後に起動設定をしておきます。
# chkconfig –list splunk
splunk 0:off 1:off 2:on 3:on 4:on 5:on 6:off
以上で設定終了です。