sge安装
qmaster sge安装
1 | install_rpm.sh #qmaster节点上运行 |
使用nfs将qmaster上的sge部署到exec节点
- 在qmaster和exec节点安装nfs。需要保证各机器上的nfs版本一致。
1
2
3sudo yum -y install nfs-utils #安装
sudo yum -y upgrade nfs-utils #更新
rpm -qa | grep nfs-utils #查看版本
qmaster节点配置nfs。在qmaster节点的/etc/exports中添加
/opt/sge 10.40.0.0/16(rw,root_squash)
,其中10.40是exec节点的ip前缀。修改/etc/sysconfig/nfs
中的参数RPCNFSDCOUNT=64,将线程数设为64. 在文件/proc/net/rpc/nfsd
中可以查看线程数。这样qmaster节点上的/opt/sge文件可以共享给所有ip以10.40开头的exec。1
2
3
4sudo systemctl start rpcbind.service
sudo systemctl start nfs.service #启动服务
sudo exportfs -ra #使配置生效
sudo systemctl status nfs.service #查看statusexec节点挂载nfs。nfs日志文件放在
/var/log/message
和/var/log/cron
中,出现故障的时候可查看日志。1
2
3sudo mount -t nfs -o rw,vers=3,acdirmin=5,acdirmax=8,hard,proto=tcp xx.xx.xx.xx:/opt/nfs/train1 /opt/nfs/train1 #在exec挂载qmaster的目录,挂载之前exec和qmaster目录都需要存在。xx.xx.xx.xx是qmaster的ip
nfsstat -m #查看nfs版本
umount -f #卸载exec上的nfs,可添加-l强制卸载错误解决。qmaster节点上启动服务
sudo systemctl start rpcbind.service
时出现问题A dependency job for rpcbind.service failed. See 'journalctl -xe' for details.
主要是因为ipv6被禁用了,打开/etc/systemd/system/sockets.target.wants/rpcbind.socket
,注释掉ListenStream=[::]:111
即可。
启动sge服务
在所有qmaster和exec节点执行下面的操作:
1
2qconf -ah $node_name
qconf -as $node_nameon exec node run:
1
2
3install_deps.sh
install_rpm.sh
install_execd.shstart on boot
1
2
3
4
5systemctl enable sgemaster.p6444 #启动qmaster上的sge
sudo /etc/init.d/sgeexecd.p6444 start
systemctl enable sgeexecd.p6444
sudo /etc/init.d/sgemaster.p6444 start
systemctl status sgeexecd.p6444 #查看sge状态
keeping grid stable
保证集群中内存不会崩,当内存接近使用完的时候自动杀死当前占用内存最多的非系统应用。
1 | sudo bash |
配置
qconf -me dx-ai-speechoffline-training1
1 | complex_values ram_free=188G,gpu=2 #没有gpu不写gpu,配置共享内存 |
cephfs挂载
1 | sudo fusermount -uz /opt/meituan/cephfs |
sge使用
1 | qhost -q #查看sge节点信息 |
df -h 查看nfs是否配置成功
working on centos 6/7
以上所有安装脚本以及相应的资源文件无法提供