• slider image 168
:::
條列式新聞
新聞載入中,請稍後...

15-7-1 PVE 自訂 LXC 樣版來產生 CT

來源:https://pogotsai.blogspot.tw/2018/02/pve-lcx-ct.html
參考:https://pve.proxmox.com/wiki/Custom_built_template
   https://forum.proxmox.com/threads/customize-a-lxc-template.23461/

 

  1. download a normal lxc / openvz template1
    抓一個你想改的 lxc/openvz 的樣版
  2. create an lxc container with this template
    用這樣版來產生一個 CT
  3. boot it
    啟動這個 CT
    (pct start CTID)
  4. open it
    (pct enter CTID)
  5. install / modificat everything you want
    在這個 CT 做你想要的更改, 安裝軟件, 修改什麼看你高興
  6. remove all network interfaces
    移除網路設定
    1. clean it (apt-get clean, remove hostname, resolv.conf, ect.)
      移除網路相關的設定, 清乾淨這個 CT
  7. shutdown the container
    關 CT
  8. make a backup with vzdump an select tar.gz
    用 vzdump (或UI Backup 的操作) 產生 GZIP 格式的備份
  9. move an rename the backupfile from ...../dump/xyz.tar.gz to ..... /templates/cache/name-version.tar.gz
    把生成的 .gz 檔 由 備份的 ...../dump/ 目錄 移到 放 lxc 樣版的 ..... /templates/cache/ 目錄, 並改一個好認的名字
  10. use your new template as any other
    開心使用這個己修改過的 lxc 樣版

:::
展開 | 闔起

文章類別

書籍目錄

展開 | 闔起

線上使用者

15人線上 (15人在瀏覽線上書籍)

會員: 0

訪客: 15

更多…