ElasticSearch 모니터링툴 설치하기
두가지 종류가 있음
apache elasiticHQ
xxxxxxxxxx파이썬 설치 https://linuxize.com/post/how-to-install-python-3-on-centos-7/Apache elasticsearch HQhttp://www.elastichq.org/gettingstarted.html
x
$sudo yum install centos-release-scl$sudo yum install rh-python36$python --version$scl enable rh-python36 bash$python --versioninstall HQ
xxxxxxxxxx1. Download or clone the repository https://github.com/ElasticHQ/elasticsearch-HQ2. Navigate to the root of the repository: pip install -r requirements.txt3. Start the server: python3 application.py4. Point your browser to: http://localhost:5000
Kibana monitoring
두 번째는 elasticsearch의 모니터링툴
6.5 부터는 모니터링툴이 자동으로 포함되어잇지만 이전버전들은 설치 해야함 .
현재 사용중인 6.2.2 에서는 kibana monitoring 을 사용하려면 xpack 설치가 필요
elasticsearch와 kibana 에 x-pack 설치 (sudo 권한)
xxxxxxxxxx[user@localhost bin]$ ./elasticsearch-plugin install x-pack[sudo] pduser의 암호:-> Downloading x-pack from elastic[=================================================] 100% @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ WARNING: plugin requires additional permissions @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@* java.io.FilePermission \\.\pipe\* read,write* java.lang.RuntimePermission accessClassInPackage.com.sun.activation.registries* java.lang.RuntimePermission getClassLoader* java.lang.RuntimePermission setContextClassLoader* java.lang.RuntimePermission setFactory* java.net.SocketPermission * connect,accept,resolve* java.security.SecurityPermission createPolicy.JavaPolicy* java.security.SecurityPermission getPolicy* java.security.SecurityPermission putProviderProperty.BC* java.security.SecurityPermission setPolicy* java.util.PropertyPermission * read,writeSee http://docs.oracle.com/javase/8/docs/technotes/guides/security/permissions.htmlfor descriptions of what these permissions allow and the associated risks.Continue with installation? [y/N]y@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ WARNING: plugin forks a native controller @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@This plugin launches a native controller that is not subject to the Javasecurity manager nor to system call filters.Continue with installation? [y/N]yElasticsearch keystore is required by plugin [x-pack-security], creating...-> Installed x-pack with: x-pack-core,x-pack-deprecation,x-pack-graph,x-pack-logstash,x-pack-ml,x-pack-monitoring,x-pack-security,x-pack-upgrade,x-pack-watcher설치를 하면 bin 디렉토리안에 x-pack 폴더가 생긴다 폴더에 들어가서 비밀번호 설정을 할것이다.
xxxxxxxxxx[user@localhost x-pack]$ ./setup-passwords interactiveInitiating the setup of passwords for reserved users elastic,kibana,logstash_system.You will be prompted to enter passwords as the process progresses.Please confirm that you would like to continue [y/N]yEnter password for [elastic]:Reenter password for [elastic]:Enter password for [kibana]:Reenter password for [kibana]:Enter password for [logstash_system]:Reenter password for [logstash_system]:Changed password for user [kibana]Changed password for user [logstash_system]Changed password for user [elastic][user@localhost x-pack]$
kibana xpack 설치
kibana 홈디렉토리의 bin디렉토리로 이동
xxxxxxxxxx[user@localhost bin]$ ./kibana-plugin install x-packAttempting to transfer from x-packAttempting to transfer from https://artifacts.elastic.co/downloads/kibana-plugins/x-pack/x-pack-6.2.2.zipTransferring 269704442 bytes....................Transfer completeRetrieving metadata from plugin archiveExtracting plugin archiveExtraction completeOptimizing and caching browser bundles...Plugin installation complete
kiabana 비밀번호 설정
xpack 을 설치하면 보안이 복잡하다 그렇기 때문에 나는 사용하지 않기로 함 !!
elasticsearch.yml 파일과 kibana.yml 파일에 다음과 같이 추가해줘야함
xxxxxxxxxxxpack.security.enabledfalse
설정 후에 elasticsearch 를 종료하고 다시 시작해야한다.
참고자료
https://www.elastic.co/guide/en/elasticsearch/reference/6.2/installing-xpack-es.html
'BackEnd > ElasticSearch' 카테고리의 다른 글
| [Elasticsearch] failed to obtain node locks (0) | 2019.06.21 |
|---|---|
| SuggestAPI 소개 (0) | 2019.06.10 |
| Nori 사용 해서 노래 가사 검색하기 (0) | 2019.06.10 |
| Elasticsearch Nori (0) | 2019.05.27 |
| Elasticsearch logger (0) | 2019.02.25 |