主題:Cent OS 7.8 + xCAT 2.16版 一、虛擬機 硬體配置 CPU 4 cores + Ram 16GB + OS硬碟32GB + DATA硬碟 200GB ![](https://i.imgur.com/QtRabeH.png) 設定IP : 192.168.120.201/24 設定Domain Name : xcat.stg.tw 二、建立軟體庫 [xcat-dep] name=xCAT 2 depedencies baseurl=http://xcat.org/files/xcat/repos/yum/xcat-dep/rh7/x86_64 enabled=1 gpgcheck=1 gpgkey=http://xcat.org/files/xcat/repos/yum/xcat-dep/rh7/x86_64/repodata/repomd.xml.key [xcat-core] name=xCAT 2 Core packages baseurl=http://xcat.org/files/xcat/repos/yum/latest/xcat-core enabled=1 gpgcheck=1 gpgkey=http://xcat.org/files/xcat/repos/yum/latest/xcat-core/repodata/repomd.xml.key [xcat-core-devel] name=xCAT 2 Core devel packages baseurl=http://xcat.org/files/xcat/repos/yum/devel/core-snap enabled=1 gpgcheck=1 gpgkey=http://xcat.org/files/xcat/repos/yum/devel/core-snap/repodata/repomd.xml.key [xcat-2-core] name=xcat 2 Core packages baseurl=http://xcat.org/files/xcat/repos/yum/2.13/xcat-core enabled=1 gpgcheck=1 gpgkey=http://xcat.org/files/xcat/repos/yum/2.13/xcat-core/repodata/repomd.xml.key ![](https://i.imgur.com/JF73RC7.png) 硬碟空間切割及掛載 ![](https://i.imgur.com/frxUGOS.png) yum install xCAT ![](https://i.imgur.com/FUwJPTv.png) 取讀設定檔 source /etc/profile.d/xcat.sh 取得設定資訊 xcatprobe xcatmn ![](https://i.imgur.com/L0xJnHM.png) chtab key=system passwd.username=root passwd.password=Nchc@1234 tabdump site (列出站台資訊) lsxcatd -a (檢查xCAT版本) chdef -t site dhcpinterfaces=ens192 (定義DHCP介面) makedns -n (讓DNS Service正常) makedhcp -a makedhcp -n (讓DHCP Service正常) yum install ntp makentp -a ![](https://i.imgur.com/OmzaN2v.png) copycds -n centos7.8 CentOS-7_8-x86_64-DVD-2003.iso (將系統ISO檔讀入系統,並命名為 centos7.8) lsdef -t osdistro lsdef -t osimage ![](https://i.imgur.com/kYulZB0.png) tabdump nodelist tabdump nodetype tabdump noderes tabdump mac tabdump hosts nodeadd xcattest01 groups=test mac.interface=eth0 mac.mac=00:50:56:AC:6B:2E hosts.ip=192.168.120.211 noderes.netboot=pxe noderes.xcatmaster=192.168.120.201 noderes.installnic=eth0 noderes.primarynic=eth0 noderes.nfsserver=192.168.120.201 nodetype.os=centos7.8 nodetype.arch=x86_64 nodetype.profile=test nodetype.nodetype=osi makehosts xcattest01 makedhcp xcattest01 nodeset xcattest01 osimage=centos7.8-x86_64-install-compute yum install ipmitool yum install freeipmi nodech test nodehm.power=ipmi nodehm.mgt=ipmi nodech xcattest01 ipmi.bmc=10.1.20.1 ipmi.username=root ipmi.password=calvin nodeset <noderange> osimage=rhel5.8-x86_64-install-compute rsetboot <noderange> net rpower <noderange> reset lsdef compute -i status