From 97e7b2b2bb2bc635b5a00d9a98676818c1f36850 Mon Sep 17 00:00:00 2001 From: Craig Small Date: Wed, 2 Nov 2022 22:18:44 +1100 Subject: [PATCH] docs: Add note about fuser and mount namespaces fuser won't match block devices that are mounted by processes in a different mount namespace. This is because the file descriptor will be from the process namespace, not the "viewer" (e.g. fuser) namespace. References: #39 Signed-off-by: Craig Small --- doc/fuser.1 | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/doc/fuser.1 b/doc/fuser.1 index aa6345b..45758f3 100644 --- a/doc/fuser.1 +++ b/doc/fuser.1 @@ -6,7 +6,7 @@ .\" the Free Software Foundation; either version 2 of the License, or .\" (at your option) any later version. .\" -.TH FUSER 1 "2022-09-21" "psmisc" "User Commands" +.TH FUSER 1 "2022-11-02" "psmisc" "User Commands" .SH NAME fuser \- identify processes using files or sockets .SH SYNOPSIS @@ -275,6 +275,11 @@ The option only works on processes. If the user is the kernel, .B fuser will print an advice, but take no action beyond that. +.PP +.B fuser +will not see block devices mounted by processes in a different mount namespace. +This is due to the device ID shown in the process' file descriptor table being +from the process namespace, not fuser's; meaning it won't match. .SH BUGS .PP .B fuser \-m /dev/sgX @@ -289,6 +294,7 @@ the mount point. .BR kill (1), .BR killall (1), .BR lsof (8), +.BR mount_namespaces (7), .BR pkill (1), .BR ps (1), .BR kill (2). -- 2.50.1