Edge for Private Cloud 4.16.09 版
反熵維護
Apache Cassandra 環狀節點需要定期維護,確保所有節點的一致性。如要執行這項維護作業,請使用 Cassandra「nodetool -h localhost repair」指令。
在單一區域或單一資料中心安裝 Apigee 時,請在一個 Cassandra 節點上使用「nodetool -h localhost repair」指令,確保環中所有節點的一致性。在多區域或多資料中心 Apigee 安裝中,請在環中的每個節點 (跨所有區域或資料中心) 使用「nodetool -h localhost repair -pr」。
如要進一步瞭解「遺忘刪除」和 Cassandra 一致性,以及如何使用「nodetool」,請參閱:
http://wiki.apache.org/cassandra/Operations - Consistency
重要事項:Apigee 不建議在未與 Apigee 客戶成功團隊聯絡的情況下,新增、移動或移除 Cassandra 節點。Apigee 系統會使用 IP 位址追蹤 Cassandra 節點,如果執行環狀維護作業,但未在 Apigee 環境中繼資料執行對應更新,會導致不理想的結果。
記錄檔維護
Cassandra 記錄檔會儲存在每個節點的 /<inst_root>/apigee/var/log/cassandra 目錄中。根據預設,最多可建立 50 個記錄檔,每個檔案的大小上限為 20 MB。達到上限後,系統會在建立新記錄時刪除舊記錄。
如果發現 Cassandra 記錄檔占用過多空間,可以編輯 log4j 設定,修改分配給記錄檔的空間量。
- 編輯 /<install_dir>/apigee/customer/application/cassandra.properties,設定下列屬性。如果該檔案不存在,請建立檔案:
conf_log4j-server_log4j.appender.r.maxfilesize=20MB # max file size
conf_log4j-server_log4j.appender.r.maxbackupindex=50 # max open files - 使用下列指令重新啟動 Cassandra:
$ /<install_dir>/apigee/apigee-service/bin/apigee-service apigee-cassandra restart