替换你自己的ip
主机 | 主机ip | |
---|
aa | 192.168.174.139 | 200g |
bb | 192.168.174.140 | 200g |
aa、bb root用户下
hostnamectl set-hostname VM_0_1_centos
hostnamectl set-hostname VM_0_2_centos
cd /etc/security/limits.d
ls -lrt 20-nproc.conf
mv 20-nproc.conf 20-nproc.conf_bak
vi /etc/security/limits.conf
ulimit -a
systemctl disable firewalld.service
systemctl stop firewalld.service
systemctl status firewalld.service
groupadd -g 6000 apps
useradd -s /bin/bash -g apps -d /home/app app
passwd app
vi /etc/sudoers.d/app
app ALL=(ALL) ALL
app ALL=(ALL) NOPASSWD: ALL
Defaults !env_reset
chmod u+w /etc/sudoers
vi /etc/sudoers
root ALL=(ALL) NOPASSWD: ALL
app ALL=(ALL) ALL
app ALL=(ALL) NOPASSWD: ALL
![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/ab4bd2f2b969b75fd99262d6ac142c97.png#pic_center)
cd /
mkdir data
cd /data
dd if=/dev/zero of=/data/swapfile128G bs=1024 count=134217728
mkswap /data/swapfile128G
swapon /data/swapfile128G
cat /proc/swaps
echo '/data/swapfile128G swap swap defaults 0 0' >> /etc/fstab
aa 、bb app用户下
cd /data
mkdir projects
chown app:apps projects
ls -l
chown -R app /data
su app
ssh-keygen -t rsa
cat ~/.ssh/id_rsa.pub >>/home/app/.ssh/authorized_keys
chmod 600 ~/.ssh/authorized_keys
ssh app@192.168.174.139
ssh app@192.168.174.140
scp ~/.ssh/authorized_keys app@192.168.174.140:/home/app/.ssh
cat ~/.ssh/id_rsa.pub >> /home/app/.ssh/authorized_keys
scp ~/.ssh/authorized_keys app@192.168.174.139:/home/app/.ssh
ssh app@192.168.174.140
ssh app@192.168.174.139
获取项目
cd /data/projects
wget https://webank-ai-1251170195.cos.ap-guangzhou.myqcloud.com/fate_cluster_install_1.8.0_release-c7-u18.tar.gz
wget https://webank-ai-1251170195.cos.ap-guangzhou.myqcloud.com/fate/${version}/release/fate_cluster_install_${version}_release.tar.gz
wget https://webank-ai-1251170195.cos.ap-guangzhou.myqcloud.com/fate/1.9.0/release/fate_cluster_install_1.9.0_release.tar.gz
tar xzf fate_cluster_install_1.9.0_release.tar.gz
cd fate_cluster_install_1.9.0_release/tools-install
sh ./check.sh
cd /data/projects/fate_cluster_install_1.9.0_release/allInone/conf
vi setup.conf
cd /data/projects/fate_cluster_install_1.9.0_release/allInone
sh ./deploy.sh
cd /data/projects/fate_cluster_install_1.9.0_release/allInone
tail -f ./logs/deploy.log (部署结束,查看一下即可)
tail -f ./logs/deploy-guest.log (实时打印GUEST端的部署情况)
tail -f ./logs/deploy-mysql-guest.log (实时打印GUEST端mysql的部署情况)
tail -f ./logs/deploy-host.log (实时打印HOST端的部署情况)
tail -f ./logs/deploy-mysql-host.log (实时打印HOST端mysql的部署情况)
![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/51ae4d3f762d8eeb4a6166244262ef04.png#pic_center)
测试
http://192.168.174.139:8080/
http://192.168.174.140:8080/
source /data/projects/fate/bin/init_env.sh
flow test toy -gid 10000 -hid 10000
source /data/projects/fate/bin/init_env.sh
flow test toy -gid 9999 -hid 9999
source /data/projects/fate/bin/init_env.sh
flow test toy -gid 9999 -hid 10000
source /data/projects/fate/bin/init_env.sh
fate_test data upload -t min_test
source /data/projects/fate/bin/init_env.sh
cd /data/projects/fate/examples/min_test_task/
python run_task.py -gid 9999 -hid 9999 -aid 9999 -f fast
python run_task.py -gid 9999 -hid 10000 -aid 10000 -f fast
python run_task.py -gid 9999 -hid 9999 -aid 9999 -f normal
python run_task.py -gid 9999 -hid 10000 -aid 10000 -f normal
![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/ed4acd2b2d5c7c8a9baf04536e5533e7.png#pic_center)