this post was submitted on 26 Apr 2025
3 points (100.0% liked)

MiniLab

180 readers
3 users here now

A community for home labs using only mini form factor (MFF) PC's, NUC's or Raspberry Pi's as servers.

founded 2 years ago
MODERATORS
 

I have a VPS with limited resources. So, I decided to use telegraf with sqlite3. As that seems less resource intensive. I'm having trouble with what seems like permissions. This is under Debian system version 12.

When I run telegraf with root permission (sudo), it runs fine. However, when I run via systemclt -- using sudo to start -- it fails to write to the database.

It's a sqlite3 database. I've given read and write permission to the file. I've given ownership of the file to telegraf. Telegraf is both a user and a group. Yet, I see same error message, database is readonly. What am I missing?

top 1 comments
sorted by: hot top controversial new old
[–] dis_honestfamiliar 1 points 1 day ago

Never mind. Turns out for sqlite3, it needs write permissions on the directory.