KAA平台系列文章:
https://kaaproject.github.io/kaa/docs/v0.10.0/Welcome/
CentOS7 + JDKjdk1.8.0_211 + zookeeper 3.4.6 + MongoDB 4.0.10 + kaa-node-0.10.0-SNAPSHOT20170816065203.noarch.rpm
解压:tar -zxvf jdk.tar.gz -C /usr/local/
配置:vim /etc/profile
#my srttings
export JAVA_HOME=/usr/local/jdk1.8.0_211
export PATE=$PATH:$JAVA_HOME/bin:
source /etc/profile
错误:source /etc/profile -提示找不到命令
试试:A)locate source /etc/profile
试试:B)usr/bin/source /etc/profile
仅参考:
检查是否安装了mariadb组件:
rpm -qa | grep -i mariadb
删除组件
rpm -ev 组件名
rpm -ivh MariaDB-5.5.47-centos7-x86_64-server.rpm
rpm -ivh MariaDB-5.5.47-centos7-x86_64-client.rpm
mysql -uroot -p
创建kaa数据库
CREATE DATABASE kaa CHARACTER SET utf8 COLLATE utf8_general_ci;
tar -zxvf ./AppPackage/zookeeper-3.4.6.tar.gz -C ./
创建zoo.cfg
initLimit=10
syncLimit=5
dataDir=/usr/local/zookeeper-3.4.6/data
dataLogDir=/usr/local/zookeeper-3.4.6/logs
clientPort=2181
配置环境变量
解压:
tar -zxvf ./AppPackage/mongodb-linux-x86_64-4.0.10.tgz -C ./
启动:
./bin/mongod --dbpath /data/db
./mongo KAA
官网安装文档:
http://kaaproject.github.io/kaa/docs/v0.10.0/Administration-guide/System-installation/
检查是否安装了kaa-node组件:
rpm -qa | grep -i 组件名
删除组件
rpm -ev 组件名
安装
rpm –ivh 组件名
$ cat /etc/kaa-node/conf/admin-dao.properties | grep jdbc_username
jdbc_username=sqladmin
$ cat /etc/kaa-node/conf/admin-dao.properties | grep jdbc_password
jdbc_password=admin
$ cat /etc/kaa-node/conf/sql-dao.properties | grep jdbc_username
jdbc_username=sqladmin
$ cat /etc/kaa-node/conf/sql-dao.properties | grep jdbc_password
jdbc_password=admin
如果密码或用户名不匹配,请编辑配置文件。
$ sudo vim /etc/kaa-node/conf/admin-dao.properties
$ sudo vim /etc/kaa-node/conf/sql-dao.properties
默认需要kaa用户启动
解决:更改vim ./bin/kaa-node
修改地址为:“localhost”–>”192.168.0.110” 本机地址 192.168.0.110
cd /etc/kaa-node/conf
vim kaa-node.properties
启动顺序:Zookeeper --> MongoDB --> KAA
./zkServer.sh start
./zkServer.sh stop
./zkServer.sh status
启动: ./mongod --dbpath /data/db
启动客户端: ./bin/mongo
show dbs;
show collections;
mongo kaa
use kaa
db.yourColl.count();
db.logs_24473266966962431201.find();
db.userInfo.getDB();
db.userInfo.dataSize();
可参考
cd /usr/lib/kaa-node/bin
./kaa-node start
tail -100f /var/log/kaa/kaa-node.log
whereis kaa-node
chmod +x *.sh
echo "" > *.log
cat /var/log/kaa/* | grep ERROR
clear