shell安装kettle

1.将kettle.tar上传至/opt/soft下,将依赖包上传至/opt/rpm/kettle下

2.执行/bin/bash install_kettle.sh | tee /opt/logs/kettle.log命令,脚本内容如下:

#!/bin/bash

# Author: zhangdc
# DESC: 部署kettle

echo "如果/opt/soft/mysql/不存在创建"
if [ ! -d "/opt/soft/" ];then
mkdir -p /opt/soft/
fi
echo "解压kettle"
tar -xvf /opt/soft/kettle.tar -C /opt/soft/ >/dev/null 2>&1
rpm -iUvh /opt/rpm/kettle/*.rpm --nodeps --force
rpm -qa|grep libicu-50.1.2-15.el7
if [ $? -ne 1 ];then
rpm -e --nodeps libicu-50.1.2-15.el7
fi
echo "依赖包安装完成"
source /etc/profile
chmod 777 /opt/soft/kettle/spoon.sh
sh /opt/soft/kettle/kitchen.sh

上一篇:一 Prometheus + node_exporter + Grafana 安装和部署


下一篇:linux创建软链接