error You have $NVM_DIR set to "/root/.nvm", but that directory does not exist. Check your profile files and environment.

#error [min@localhost ~]$ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 13527 100 13527 0 0 17679 0 --:--:-- --:--:-- --:--:-- 17682 You have $NVM_DIR set to "/root/.nvm", but that directory does not exist. Check your profile files and environment. #fix error [min@localhost ~]$ unset NVM_DIR [min@localhost ~]$ curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.3/install.sh | bash % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 13527 100 13527 0 0 28270 0 --:--:-- --:--:-- --:--:-- 28240 => Downloading nvm from git to '/home/min/.nvm' => Cloning into '/home/min/.nvm'... remote: Enumerating objects: 290, done. remot...

how to make kibana-plugin II

#start project min@min-HVM-domU:~/kibana$ yarn start yarn run v1.22.4 $ node scripts/kibana --dev log [14:53:58.044] [warning][plugins-discovery] Explicit plugin paths [/home/min/kibana/x-pack] should only be used in development. Relative imports may not work properly in production. log [14:53:58.808] [warning][plugins-discovery] Expect plugin "id" in camelCase, but found: beats_management log [14:53:58.824] [warning][plugins-discovery] Expect plugin "id" in camelCase, but found: triggers_actions_ui [BABEL] Note: The code generator has deoptimised the styling of /home/min/kibana/x-pack/plugins/siem/server/utils/beat_schema/8.0.0/filebeat.ts as it exceeds the max of 500KB. log [14:56:22.508] [info][plugins-service] Plugin "visTypeXy" is disabled. log [14:56:22.510] [info][plugins-service] Plugin "ingestManager" is disabled. log [14:56:22.511] [info][plugins-service] Plugin "lists" is disabled. log [14:56:22.51...

how to make kibana-plugin

#set kibana developement root@min-HVM-domU:~# wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.7.0-amd64.deb --2020-05-20 19:12:33-- https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.7.0-amd64.deb Resolving artifacts.elastic.co (artifacts.elastic.co)... 151.101.110.222, 2a04:4e42:36::734 접속 artifacts.elastic.co (artifacts.elastic.co)|151.101.110.222|:443... 접속됨. HTTP request sent, awaiting response... 200 OK Length: 314465174 (300M) [application/octet-stream] Saving to: ‘elasticsearch-7.7.0-amd64.deb’ elasticsearch-7.7.0-amd64.deb 0%[ ] 440.44K 72.3KB/s eta 63m 3s delasticsearch-7.7.0-amd64.deb 100%[=====================================================>] 299.90M 38.1MB/s in 3m 34s 2020-05-20 19:16:08 (1.40 MB/s) - ‘elasticsearch-7.7.0-amd64.deb’ saved [314465174/314465174] root@min-HVM-domU:~# dpkg -i elasticsearch-7.7.0-amd64.deb Selecting previously unselected package...

kube-state-metrics

#clone kube-state-metrics [root@k8s-master ~]# git clone https://github.com/kubernetes/kube-state-metrics.git Cloning into 'kube-state-metrics'... remote: Enumerating objects: 1, done. remote: Counting objects: 100% (1/1), done. remote: Total 18700 (delta 0), reused 0 (delta 0), pack-reused 18699 Receiving objects: 100% (18700/18700), 15.96 MiB | 3.60 MiB/s, done. Resolving deltas: 100% (11775/11775), done. #apply config [root@k8s-master kube-state-metrics]# kubectl apply -f examples/standard clusterrolebinding.rbac.authorization.k8s.io/kube-state-metrics created clusterrole.rbac.authorization.k8s.io/kube-state-metrics created deployment.apps/kube-state-metrics created serviceaccount/kube-state-metrics created service/kube-state-metrics created [root@k8s-master kube-state-metrics]# #create user [root@k8s-master kube-state-metrics]# kubectl create clusterrolebinding cluster-admin-binding --clusterrole=cluster-admin --user=root clusterrolebinding.rbac...

deploy docker image on kubernetes

#apply patch [root@k8s-master ~]# cat Dockerfile FROM openjdk:8-jdk MAINTAINER gnoti VOLUME /tmp ARG JAR_FILE=test.springboot.netty-0.0.1-SNAPSHOT.jar COPY ${JAR_FILE} app.jar ENTRYPOINT ["java","-Djava.security.egd=file:/dev/./urandom","-jar","/app.jar"] EXPOSE 8088[root@k8s-master ~]# [root@k8s-master ~]# docker build -t gnotiboot . Sending build context to Docker daemon 157MB Step 1/7 : FROM openjdk:8-jdk ---> 3e50df58f25e Step 2/7 : MAINTAINER gnoti ---> Running in e3a88d96f015 Removing intermediate container e3a88d96f015 ---> 5cfc31ae7709 Step 3/7 : VOLUME /tmp ---> Running in 7c87f897218c Removing intermediate container 7c87f897218c ---> 002b046cc33b Step 4/7 : ARG JAR_FILE=test.springboot.netty-0.0.1-SNAPSHOT.jar ---> Running in 805698ab8292 Removing intermediate container 805698ab8292 ---> 539b5c4b2e87 Step 5/7 : COPY ${JAR_FILE} app.jar ---> ea2812dc02e7 Step 6/7 : ENTRYPOINT ["java",...

change fscrawler rest port

#set config [root@elk docs]# cat /root/.fscrawler/fsindex/_settings.yaml --- name: "fsindex" fs: url: "/home/weblogic/docs" update_rate: "15m" excludes: - "*/~*" json_support: false filename_as_id: false add_filesize: true remove_deleted: true add_as_inner_object: false store_source: false index_content: true attributes_support: false raw_metadata: false xml_support: false index_folders: true lang_detect: false continue_on_error: false ocr: language: "eng" enabled: true pdf_strategy: "ocr_and_text" follow_symlinks: false elasticsearch: nodes: - url: "http://192.168.0.126:9200" bulk_size: 100 flush_interval: "5s" byte_size: "10mb" rest: url : "http://127.0.0.1:9091/fscrawler" enable_cors: false [root@elk docs]# #show result [root@elk ~]# curl http://127.0.0.1:9092/fscrawler/ { "ok": true, "v...

sync dbms using logstash

#set logstash [root@elk74 ~]# cd /etc/logstash/ [root@elk74 logstash]# ll 합계 44 drwxrwxr-x. 2 root root 6 3월 26 17:55 conf.d -rw-r--r--. 1 root root 2019 3월 26 17:55 jvm.options -rw-r--r--. 1 root root 8880 3월 26 17:55 log4j2.properties -rw-r--r--. 1 root root 959 5월 8 11:09 logs.yml -rw-r--r--. 1 root root 342 3월 26 17:55 logstash-sample.conf -rw-r--r--. 1 root root 8866 5월 8 08:58 logstash.yml -rw-r--r--. 1 root root 285 3월 26 17:55 pipelines.yml -rw-------. 1 root root 1696 3월 26 17:55 startup.options [root@elk74 logstash]# vi logs.yml input { jdbc { jdbc_driver_library => "/root/mysql-connector-java-8.0.16.jar" jdbc_driver_class => "com.mysql.jdbc.Driver" jdbc_connection_string => "jdbc:mysql://192.168.0.158:3306/es_db" jdbc_user => root jdbc_password => mypass123 jdbc_paging_enabled => true tracking_column => "unix_ts_in_secs" use_column_value => true tracking...