Home > database >  What is the trailing 'm' on fuser's output?
What is the trailing 'm' on fuser's output?

Time:11-23

I'd like to list process' which use "/dev/my/dev". (Device name is an example) So I've used fuser:

$ fuser /dev/my/dev

/dev/my/dev:  19228m 19268 21620 21623 21663

Note the trailing 'm'.

If I redirect stderr, it's gone:

$ fuser /dev/my/dev 2>/dev/null 

 19228 19268 21620 21623 21663

What is this trailing 'm' doing here? Why is it reported to stderr?

fuser's version is:

$ fuser --version
fuser (PSmisc) 22.20
Copyright (C) 1993-2010 Werner Almesberger and Craig Small

Many thanks.

CodePudding user response:

The m signifies a memory-mapped (mmap) file or shared library.

The fuser manpage notes:

fuser outputs only the PIDs to stdout, everything else is sent to stderr.

Hence, the behavior you see when STDERR is redirected to the bit-bucket.

  • Related