From 0109c883528b052b097cd26dcb8b22174324439a Mon Sep 17 00:00:00 2001 From: Changyuan Lyu Date: Mon, 7 Oct 2024 20:33:36 -0700 Subject: [PATCH] cpud: print fstab mount errors In most cases when we get an error "CPUD: your $PWD is not in the remote namespace", it is due to some missing mounts, for example, a mount target dir does not exist on the remote machine. Printing out the mount errors helps debugging. Signed-off-by: Changyuan Lyu --- session/session.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/session/session.go b/session/session.go index 12ecc959..a76512fa 100644 --- a/session/session.go +++ b/session/session.go @@ -169,7 +169,7 @@ func (s *Session) Run() error { if tab, ok := os.LookupEnv(fstab); ok { verbose("Mounting %q", tab) if err := mount.Mount(tab); err != nil { - verbose("fstab mount failure: %v", err) + log.Printf("fstab mount failure: %v", err) // Should we die if the mounts fail? For now, we think not; // the user may be able to debug. Just record that it failed. s.fail = true