From bcf35876d1a78f19104118497e9230834109579a Mon Sep 17 00:00:00 2001 From: chrislu Date: Wed, 31 Aug 2022 23:16:05 -0700 Subject: [PATCH] add more logs --- weed/command/mount_linux.go | 4 ++++ weed/command/mount_std.go | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/weed/command/mount_linux.go b/weed/command/mount_linux.go index aebb14e61..1d1727519 100644 --- a/weed/command/mount_linux.go +++ b/weed/command/mount_linux.go @@ -3,6 +3,7 @@ package command import ( "bufio" "fmt" + "github.com/seaweedfs/seaweedfs/weed/glog" "io" "os" "strings" @@ -142,6 +143,9 @@ func checkMountPointAvailable(dir string) bool { } if mounted, err := mounted(mountPoint); err != nil || mounted { + if err != nil { + glog.Errorf("check %s: %v", mountPoint, err) + } return false } diff --git a/weed/command/mount_std.go b/weed/command/mount_std.go index db5899109..a39d88cce 100644 --- a/weed/command/mount_std.go +++ b/weed/command/mount_std.go @@ -157,7 +157,7 @@ func RunMount(option *MountOptions, umask os.FileMode) bool { // Ensure target mount point availability if isValid := checkMountPointAvailable(dir); !isValid { - glog.Fatalf("Expected mount to still be active, target mount point: %s, please check!", dir) + glog.Fatalf("Target mount point is not available: %s, please check!", dir) return true }