From 72ce5f57c1e1417ee98f74ec66a5dec08878d8c2 Mon Sep 17 00:00:00 2001 From: Simon Zolin Date: Thu, 2 Jul 2020 16:52:29 +0300 Subject: [PATCH] - auth: show detailed error message if Bolt couldn't initialize its DB Close #1846 Squashed commit of the following: commit 34c612852b784d78191b37577324adeb0149e789 Author: Simon Zolin Date: Thu Jul 2 16:43:27 2020 +0300 - auth: show detailed error message if Bolt couldn't initialize its DB --- home/auth.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/home/auth.go b/home/auth.go index a2d6d5f2..3b524d29 100644 --- a/home/auth.go +++ b/home/auth.go @@ -80,7 +80,10 @@ func InitAuth(dbFilename string, users []User, sessionTTL uint32) *Auth { var err error a.db, err = bbolt.Open(dbFilename, 0644, nil) if err != nil { - log.Error("Auth: bbolt.Open: %s", err) + log.Error("Auth: open DB: %s: %s", dbFilename, err) + if err.Error() == "invalid argument" { + log.Error("AdGuard Home cannot be initialized due to an incompatible file system.\nPlease read the explanation here: https://github.com/AdguardTeam/AdGuardHome/wiki/Getting-Started#limitations") + } return nil } a.loadSessions()