ytyou / ticktock

TickTockDB is an OpenTSDB-like time series database, with much better performance.
GNU General Public License v3.0
72 stars 8 forks source link

Unable to launch #27

Closed mzy2240 closed 1 year ago

mzy2240 commented 1 year ago

Building process seems to be fine.

 Yongtao You (yongtao.you@gmail.com) and Yi Lin (ylin30@gmail.com).
 This program comes with ABSOLUTELY NO WARRANTY. It is free software,
 and you are welcome to redistribute it under certain conditions.
 For details, see <https://www.gnu.org/licenses/>.
Failed to open file /var/log/ticktock.log for writing: 13
2023-01-18 07:26:08.650 [INFO] [main] TickTock version: 0.10.1, on khadas-vim3, pid: 30690
2023-01-18 07:26:08.650 [INFO] [main] mm::page-size = 4096
2023-01-18 07:26:08.650 [INFO] [main] mm::m_network_buffer_len = 524288
2023-01-18 07:26:08.650 [INFO] [main] mm::m_network_buffer_small_len = 326
2023-01-18 07:26:08.650 [INFO] [main] GC Freq: 300 secs
2023-01-18 07:26:08.650 [INFO] [main] Loading data from /ticktock/data
2023-01-18 07:26:08.650 [INFO] [main] number of ts locks: 1800
2023-01-18 07:26:08.650 [ERROR] [main] Not enough disk space at /ticktock/data (0 <= 32768)
2023-01-18 07:26:08.650 [ERROR] [main] Failed to open file /ticktock/data/ticktock.meta for append: 2
2023-01-18 07:26:08.650 [FATAL] [main] Failed to open meta file /ticktock/data/ticktock.meta for writing
Initialization failed. Abort!
mzy2240 commented 1 year ago

I am running on Khadas Vim3 Pro which has 6 cores and 4 GB RAM, with 1TB NVME SSD.

mzy2240 commented 1 year ago

There is no folder named /ticktock/*. Do I need to grand admin access during building process?

ylin30 commented 1 year ago

Hi there,

No you don't need to rebuild. It is a config problem. I guess you are using the default config which may not be suitable in your computer. Please modify a few parameters in your config (default: /conf/tt.conf):

Directory under which to store TSDB data;

tsdb.data.dir = /ticktock/data --> Seems you don't even have /ticktock/ folder yet.

Directory under which to store append logs;

append.log.dir = /ticktock/append --> Same as above

Log file (full path)

log.file = /var/log/ticktock.log ---> The folder permission is not correct, likely owned by root.

I would suggest you to create a folder in your local directory, and put data/, append/ and log/ subdir there. Here is my config for your reference.

tsdb.data.dir = /home/ylin30/tmp/data append.log.dir = /home/ylin30/tmp/append log.file = /home/ylin30/tmp/log/ticktock.log

Hope it works.

mzy2240 commented 1 year ago

Thank you! After the above correction, it now works as expected.