2016-09-12 154 views
1

什麼在日誌文件:Arangodb日誌記錄文件

"arango_instance_database/journals/logfile-xxxxxx.db 

我可以刪除它們?

如何縮小尺寸?
我設置

database.maximal-journal-size = 1048576 

,但這些文件還在32M大。

我可以設置一些像

/var/log/... 

目錄呢?

回答

1

你引用Write Ahead Logfiles其至少是暫時將您的數據被留在屋裏。

所以其一個非常糟糕的主意在自己的刪除它們,只要你還是喜歡你的數據文件保持完整。

這些文件被使用,因此文件可以連續寫入磁盤。系統閒置後,聚合器作業將從中選擇文檔並將其移入數據庫文件。

你可以找到interesting documentation of situations where others didn't choose such an architectural approach, and data was written directly into their data files on the disk,然後這對你的系統做什麼。

將WAL文件中的所有文檔都移動到db文件後,ArangoDB將刪除分配的空間。

0

謝謝了很多的答覆:-)

所以在arangodb部署爲「單一實例」的情況下,我可以設置:

--wal.suppress-shape-information true 
--wal.historic-logfiles 0 

還有別的嗎?

如何

--wal.logfile-size 

什麼是決定其大小最好/常見做法?

+0

'suppress-shape-in​​formation'在3.0中不可用。減少'logfile-size'可能會導致更多的被使用,但是它們可能會被更快地移除。 '歷史日誌文件'需要重新同步副本;如果您決定更快地將它們扔掉,複製可能無法在網絡分割後趕上。 – dothebart

+0

@ dothebart 但是--wal.suppress-shape-in​​formation仍然存在於3.0的官方文檔中。 https://docs.arangodb.com/3.0/Manual/Administration/Configuration/Wal.html 因此,我如何報告更新文檔? – Tomek

+0

我;-) https://github.com/arangodb/arangodb/commit/b96cdf4ba8adf2886fbc0ef3bb1c1da94be6b01e感謝您報告。 – dothebart

相關問題