1,安装环境
System Release Version:Ubuntu 14.04.4
Kernel Version: 4.2.0-27-generic
安装ElasticSearch
[email protected]:~$ ll
total 209300
-rw-rw-r-- 1 alvin alvin 32968292 Nov 8 11:04 elasticsearch-5.0.0.tar.gz
-rw-rw-r-- 1 alvin alvin 181352138 Nov 8 11:04 jdk-8u101-linux-x64.tar.gz
[email protected]:~$ tar xf jdk-8u101-linux-x64.tar.gz -C /opt/
[email protected]:~$ sudo vim /etc/profile
export JAVA_HOME=/opt/jdk1.8.0_101
export PATH=$JAVA_HOME/bin:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar:$PATH
[email protected]:~$ source /etc/profile
[email protected]:~$ sudo tar xf elasticsearch-5.0.0.tar.gz -C /opt/
[email protected]:~$ cd /opt/elasticsearch-5.0.0/
[email protected]:/opt/elasticsearch-5.0.0$ sudo chown alvin:alvin . -R
[email protected]:/opt/elasticsearch-5.0.0$ vim config/elasticsearch.yml
node.name: ubuntu
path.data: /tmp/elasticsearch/data
path.logs: /tmp/elasticsearch/logs
network.host: 192.168.1.31
http.port: 9200
[email protected]:/opt/elasticsearch-5.0.0$ sudo vim /etc/security/limits.conf
alvin soft nofile 65536
alvin hard nofile 65536
[email protected]:/opt/elasticsearch-5.0.0$ sudo vim /etc/sysctl.conf
vm.max_map_count=262144
[email protected]:/opt/elasticsearch-5.0.0$ sudo sysctl -p
[email protected]:/opt/elasticsearch-5.0.0$ ulimit -n
1024
[email protected]:/opt/elasticsearch-5.0.0$ exit
logout
#exit this session, because you need re-login to let the ulimit setting take effect.
先试试,看发表出来是怎样的,然后我再修改。