Alluxio使用初体验(单机版本安装)

1.官网(https://www.alluxio.org)下载

我这里下载的是最新版本的alluxio-1.7.1-hadoop-2.6

2.解压

tar -xzf alluxio-1.7.1-hadoop-2.6-bin.tar.gz

3.配置

进入conf目录
alluxio-site.properties

cp alluxio-site.properties.template alluxio-site.properties

alluxio-site.properties

alluxio.master.hostname=os1

同理拷贝alluxio-env.sh.template配置alluxio-env.sh:

export JAVA_HOME=/usr/soft/jdk1.8.0_144/
export ALLUXIO_MASTER_HOSTNAME=os1

4.启动
格式化存储目录

./bin/alluxio format

启动

./bin/alluxio-start.sh local

注意这里的启动参数,我开始的时候是查了网上其他的教程在这卡了好久。最后通过帮助命令才得解决。
./bin/alluxio-start.sh --help

Usage: alluxio-start.sh [-hNw] ACTION [MOPT] [-f]
Where ACTION is one of:
  all [MOPT]            Start all masters, proxies, and workers.
  local [MOPT]          Start all processes locally.
  master                Start the local master on this node.
  secondary_master      Start the local secondary master on this node.
  masters               Start masters on master nodes.
  proxy                 Start the proxy on this node.
  proxies               Start proxies on master and worker nodes.
  safe                  Script will run continuously and start the master if it's not running.
  worker [MOPT]         Start a worker on this node.
  workers [MOPT]        Start workers on worker nodes.
  restart_worker        Restart a failed worker on this node.
  restart_workers       Restart any failed workers on worker nodes.

如无意外就可访问
http://localhost:19999 和 http://localhost:30000

此处用了本地目录作存储。

5.Shell 操作

./bin/alluxio fs ls /
查看文件

./bin/alluxio fs copyFromLocal LICENSE /LICENSE
拷贝文件到Alluxio文件系统中

注:把文件存储在HDFS中

alluxio.underfs.address=hdfs://os1:9000/alluxio/data

(需要提前新建目录)

产生测试数据

bin/alluxio runTests

你可能感兴趣的:(Alluxio使用初体验(单机版本安装))