Re: [問題] DRBL SSI Mode 重新產生 client /etc / …
自問自答..:p
以下(很破爛的)script 可以在SSI Mode下面更新client template file
部份變數應該要寫成自動去讀/opt/drbl/conf/drbl.conf比較好:p
我不知道有沒有更好的做法 but this worked for me
===== code ======
etc_exclude_dirs="/etc/drbl/ /etc/selinux/targeted/"
drbl_common_root="/tftpboot/node_root"
drbl_common_root="/tftpboot/nodes/<your template dir name>"
etc_rsync_opt=""
for ietc in $etc_exclude_dirs; do
etc_rsync_opt="$etc_rsync_opt --exclude=$ietc"
done
rsync -a $etc_rsync_opt -u /etc $drbl_common_root
rsync -a -u $etc_rsync_opt --include="*/" --exclude="*" /var $drbl_common_root/
===== code ends =====
產生完templates之後還需要跑drbl-gen-ssi-files以及reboot client
please let me know if im doing smtg terribly wrong .. XD
※ 引述《bizkit (離別總是感傷)》之銘言:
: Hi,
: 目前使用DRBL SSI Mode於八台主機 目前已可正常開機
: 但在server上安裝新軟體並不會直接同步到client
: 在SSI Mode下
: clients的/usr /bin ...皆透過NFS與server端同
: clients的/etc /var為掛載於tmpfs下的image
: 但許多套件(如jdk)必須使用到/etc下的檔案
: 在client端便會因為/etc下檔案沒有更新而失敗
: 我有發現drbl-gen-ssi-files指令可以由
: /tftpboot/nodes/下的client template產生新的image
: 想要請問 在安裝新軟體或修改設定之後
: 我怎麼從本機的/etc /var產生新的client template於/tftpboot/nodes下?
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 118.160.69.22
※ 編輯: bizkit 來自: 118.160.69.22 (09/06 18:51)
※ 編輯: bizkit 來自: 118.160.69.22 (09/06 18:52)
※ 編輯: bizkit 來自: 118.160.69.22 (09/06 18:52)
討論串 (同標題文章)
本文引述了以下文章的的內容:
完整討論串 (本文為第 2 之 2 篇):