]> Git Repo - linux.git/commit
CIFS: Print message when attempting a mount
authorRodrigo Freire <[email protected]>
Sun, 7 Oct 2018 15:21:26 +0000 (12:21 -0300)
committerSteve French <[email protected]>
Wed, 24 Oct 2018 02:16:05 +0000 (21:16 -0500)
commitf80eaedd6c5978fdd31549446cfa4a7212522b8d
tree4e393792ac08946aecf4cc67dbe1258b43e54db1
parent9a0efeccfa7ea6a82585bb2def161de006396b7d
CIFS: Print message when attempting a mount

Currently, no messages are printed when mounting a CIFS filesystem and
no debug configuration is enabled.

However, a CIFS mount information is valuable when troubleshooting
and/or forensic analyzing a system and finding out if was a CIFS
endpoint mount attempted.

Other filesystems such as XFS, EXT* does issue a printk() when mounting
their filesystems.

A terse log message is printed only if cifsFYI is not enabled. Otherwise,
the default full debug message is printed.

In order to not clutter and classify correctly the event messages, these
are logged as KERN_INFO level.

Sample mount operations:

[root@corinthians ~]# mount -o user=administrator //172.25.250.18/c$ /mnt
(non-existent system)

[root@corinthians ~]# mount -o user=administrator //172.25.250.19/c$ /mnt
(Valid system)

Kernel message log for the mount operations:

[  450.464543] CIFS: Attempting to mount //172.25.250.18/c$
[  456.478186] CIFS VFS: Error connecting to socket. Aborting operation.
[  456.478381] CIFS VFS: cifs_mount failed w/return code = -113
[  467.688866] CIFS: Attempting to mount //172.25.250.19/c$

Signed-off-by: Rodrigo Freire <[email protected]>
Signed-off-by: Steve French <[email protected]>
fs/cifs/cifsfs.c
fs/cifs/transport.c
This page took 0.051362 seconds and 4 git commands to generate.