next up previous contents
Next: 驗證 Up: Nova Previous: 計算節點安裝與設定   Contents

新增計算節點到 CELL 資料庫

  1. 載入管理者環境變變數。
    [root@ip112 ~]# . admin.token
    
  2. 確認資料庫中有計算主機。
    [root@ip112 ~]# openstack compute service list --service nova-compute
    +----+--------------+------------------------+------+---------+-------+----------------------------+
    | ID | Binary       | Host                   | Zone | Status  | State | Updated At                 |
    +----+--------------+------------------------+------+---------+-------+----------------------------+
    | 13 | nova-compute | ip112.csie.cyut.edu.tw | nova | enabled | up    | 2018-05-24T14:28:49.000000 |
    +----+--------------+------------------------+------+---------+-------+----------------------------+
    
  3. 發理取得資料庫中的計算主機。
    [root@ip112 ~]# su -s /bin/sh -c "nova-manage cell_v2 discover_hosts --verbose" nova
    /usr/lib/python2.7/site-packages/oslo_db/sqlalchemy/enginefacade.py:332: 
    NotSupportedWarning: Configuration option(s) ['use_tpool'] not supported
      exception.NotSupportedWarning
    Found 2 cell mappings.
    Skipping cell0 since it does not contain hosts.
    Getting computes from cell 'cell1': 4b4e2923-ee89-4057-b7d1-473951f313c2
    Checking host mapping for compute host 'ip112.csie.cyut.edu.tw': 9784a642-7c16-473b-91ed-95ee3d066021
    Creating host mapping for compute host 'ip112.csie.cyut.edu.tw': 9784a642-7c16-473b-91ed-95ee3d066021
    Found 1 unmapped computes in cell: 4b4e2923-ee89-4057-b7d1-473951f313c2
    
  4. 當新增計算節點時,必須再執行上一個動作,也可在 /etc/nova/nova.conf 的 scheduler 章節中設定自動發現週期。
    [root@ip112 ~]# egrep '^(\[scheduler|^discover)' /etc/nova/nova.conf
    [scheduler]
    discover_hosts_in_cells_interval = 300
    



2018-09-19