2016-09-12 157 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

相关问题