elasticsearch在centos6.5下的部署

  1. 安装jdk

    安装jdkde要点主要就是环境变量

    导出JAVA_HOME

    JRE_HOME

    导出可执行程序到PATH变量

    tar -zxvf jdk-8u73-linux-x64.tar.gz
    tar -zxf jdk-8u73-linux-x64.tar.gz
    mv jdk1.8.0_73 /usr/local/jdk
    echo "JAVA_HOME=/usr/local/jdk" >>/etc/profile
    echo "CLASSPATH=.:$JAVA_HOME/lib.tools.jar" >>/etc/profile
    echo "PATH=/usr/local/jdk/bin:/bin:/sbin:/usr/sbin:/bin:/usr/bin:/root/bin" >>/etc/profile
    echo "export JAVA_HOME CLASSPATH PATH" >>/etc/profile
    source /etc/profile

    /usr/local/jdk/bin/java -version
    java version "1.8.0_73"
    Java(TM) SE Runtime Environment (build 1.8.0_73-b02)
    Java HotSpot(TM) 64-Bit Server VM (build 25.73-b02, mixed mode)

2. es安装
    1) 将es压缩文件移到/opt中
          mv  elasticsearch-2.3.3.tar.gz    /opt/

2)解压,重命名
         tar zxvf elasticsearch-2.3.3.tar.gz
         mv elasticsearch-2.3.3 elasticsearch

3)由于ElasticSearch可以接收用户输入的脚本并且执行,为了系统安全考虑, 建议创建一个单独的用户用来运行ElasticSearch
         groupadd elsearch
         useradd elsearch -g elsearch -p elasticsearch

4)更改elasticsearch文件夹及内部文件的所属用户及组为elsearch:elsearch
         cd /opt
         chown -R elsearch:elsearch  elasticsearch

5)切换到elsearch用户再启动
         su elsearch cd elasticsearch/bin
         ./elasticsearch

6)[[email protected] opt]$ cd elasticsearch/bin/
[[email protected] bin]$ ./elasticsearch
[2016-11-14 10:42:43,279][WARN ][bootstrap                ] unable to install syscall filter: seccomp unavailable: requires kernel 3.5+ with CONFIG_SECCOMP and CONFIG_SECCOMP_FILTER compiled in
[2016-11-14 10:42:43,760][INFO ][node                     ] [Armadillo] version[2.3.3], pid[5178], build[218bdf1/2016-05-17T15:40:04Z]
[2016-11-14 10:42:43,760][INFO ][node                     ] [Armadillo] initializing ...
[2016-11-14 10:42:44,925][INFO ][plugins                  ] [Armadillo] modules [reindex, lang-expression, lang-groovy], plugins [], sites []
[2016-11-14 10:42:44,962][INFO ][env                      ] [Armadillo] using [1] data paths, mounts [[/ (/dev/sda3)]], net usable_space [13.1gb], net total_space [44.9gb], spins? [possibly], types [ext4]
[2016-11-14 10:42:44,962][INFO ][env                      ] [Armadillo] heap size [1007.3mb], compressed ordinary object pointers [true]
[2016-11-14 10:42:44,962][WARN ][env                      ] [Armadillo] max file descriptors [65535] for elasticsearch process likely too low, consider increasing to at least [65536]
[2016-11-14 10:42:49,414][INFO ][node                     ] [Armadillo] initialized
[2016-11-14 10:42:49,416][INFO ][node                     ] [Armadillo] starting ...
[2016-11-14 10:42:49,659][INFO ][transport                ] [Armadillo] publish_address {127.0.0.1:9300}, bound_addresses {[::1]:9300}, {127.0.0.1:9300}
[2016-11-14 10:42:49,711][INFO ][discovery                ] [Armadillo] elasticsearch/zeSg2GF5TQGMkVZeVD_U_w
[2016-11-14 10:42:52,803][INFO ][cluster.service          ] [Armadillo] new_master {Armadillo}{zeSg2GF5TQGMkVZeVD_U_w}{127.0.0.1}{127.0.0.1:9300}, reason: zen-disco-join(elected_as_master, [0] joins received)
[2016-11-14 10:42:52,882][INFO ][http                     ] [Armadillo] publish_address {127.0.0.1:9200}, bound_addresses {[::1]:9200}, {127.0.0.1:9200}
[2016-11-14 10:42:52,882][INFO ][node                     ] [Armadillo] started
[2016-11-14 10:42:52,969][INFO ][gateway                  ] [Armadillo] recovered [0] indices into cluster_state

3.怎么确认是否安装成功

在浏览器中输入 http://ip:9200/ 访问,如果无法访问,需要修改配置文件elasticsearch.yml
# vim /usr/local/src/elasticsearch-2.3.3/config/elasticsearch.yml
# Set the bind address to a specific IP (IPv4 or IPv6):  
network.host: localhost
# Set a custom port for HTTP:  
http.port: 9200 
# ./bin/elasticsearch -d       #后台进程启动
再次访问显示如下内容说明成功 
{
  "name" : "Agron",
  "cluster_name" : "elasticsearch",
  "version" : {
    "number" : "2.3.3",
    "build_hash" : "218bdf10790eef486ff2c41a3df5cfa32dadcfde",
    "build_timestamp" : "2016-05-17T15:40:04Z",
    "build_snapshot" : false,
    "lucene_version" : "5.5.0"
  },
  "tagline" : "You Know, for Search"
}

时间: 2024-11-05 02:55:54

elasticsearch在centos6.5下的部署的相关文章

Centos6.5下kafka部署安装

一)安装JDK 步骤1:新建路径/usr/Java, 并在其下解压 jdk-7u71-linux-x64.tar.gz # mkdir -p /usr/java # tar -zxvf jdk-7u71-linux-x64.tar.gz 步骤2:添加JDK到系统环境变量 # vi /etc/profile 新增以下内容: export JAVA_HOME=/usr/java/jdk1.7.0_71 export PATH=$JAVA_HOME/bin:$PATH export CLASSPATH

centos6.5下cacti部署说明

一.Cacti简介 1. cacti是用php语言实现的一个软件,它的主要功能是用snmp服务获取数据,然后用rrdtool储存和更新数据,当用户需要查看数据的时候用rrdtool生成图表呈现给用户.因此,snmp和rrdtool是cacti的关键.Snmp关系着数据的收集,rrdtool关系着数据存储和图表的生成. 2. Mysql配合PHP程序存储一些变量数据并对变量数据进行调用,如:主机名.主机ip.snmp团体名.端口号.模板信息等变量. 3. snmp抓到数据不是存储在mysql中,而

CentOS6.7下Ansible部署

Ansible是一种集成IT系统的配置管理, 应用部署, 执行特定任务的开源平台. 它基于Python语言实现, 部署只需在主控端部署Ansible环境, 被控端无需安装代理工具, 只需打开SSH, 让主控端通过SSH秘钥认证对其进行所有的管理监控操作. 相对于SaltStack, 它除了利用SSH安全传输, 无需在客户端进行任何配置, 而且它有一个很庞大的用户群体以及丰富的API, 相对适合部署到数量比较大且对系统软件安装要求比较严格的集群中. 更多配置参考: https://github.c

centos6.8下安装部署LNMP(备注:nginx1.8.0+php5.6.10+mysql5.6.12)

在平时运维工作中,经常需要用到LNMP应用框架.以下对LNMP环境部署记录下: 1)前期准备:为了安装顺利,建议先使用yum安装依赖库[[email protected] ~]#yum install -y make cmake gcc gcc-c++ autoconf automake libpng-devel libjpeg-devel zlib libxml2-devel ncurses-devel bison libtool-ltdl-devel libiconv libmcrypt m

Centos6.8 下 从零开始 部署 Java Web 应用

一.硬件信息 CPU: [[email protected] ~]# grep 'physical id' /proc/cpuinfo | sort -u | wc -l 2 [[email protected] ~]# grep 'core id' /proc/cpuinfo | sort -u | wc -l 4 [[email protected] ~]# grep 'processor' /proc/cpuinfo | sort -u | wc -l 16 [[email protect

CentOS6.4系统下FastDFS部署

    (一)   概述 FastDFS是一个开源的分布式文件系统,她对文件进行管理,功能包括:文件存储.文件同步.文件访问(文件上传.文件下载)等,解决了大容量存储和负载均衡的问题.特别适合以文件为载体的在线服务,如相册网站.视频网站等等. FastDFS服务端有两个角色:跟踪器(tracker)和存储节点(storage).跟踪器主要做调度工作,在访问上起负载均衡的作用. FastDFS系统结构如下图所示: 上传文件交互过程: 1. client询问tracker上传到的storage,不需

Centos6.3 下使用 Tomcat-6.0.43 非root用户 jsvc模式部署 生产环境 端口80 vsftp

一.安装JDK环境 官方下载链接 http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html 64位:http://download.oracle.com/otn-pub/java/jdk/7u71-b14/jdk-7u71-linux-x64.tar.gz 32位:http://download.oracle.com/otn-pub/java/jdk/7u71-b14/jdk-7u71-

【原】Centos6.5下cdh4.6 hive安装部署

1.前提条件: 只需要选择一台服务器即可,这里选择安装在namenode上:安装用户为cloud-user 2.安装包: sudo yum install -y hive hive-metastore hive-server2 3.安装mysql: sudo yum install -y mysql-server sudo service mysqld start sudo yum install -y mysql-connector-java sudo ln -s /usr/share/jav

CentOS6.8下部署Zabbix3.0

Centos6.8下部署安装zabbix3.0: 环境要求 PHP >= 5.4  (CentOS6默认为5.3.3,需要更新) curl >= 7.20 (如需支持SMTP认证,需更新) 安装MySQL(已安装的忽略此步骤,最好5.6以上版本) rpm -ivh http://dev.mysql.com/get/mysql-community-release-el6-5.noarch.rpm yum install mysql-server –y 启动: 设置root密码: mysql_se