Unresponsive CIFS mounts block unrelated I/O

Bug #1323624 reported by Adam Porter
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Expired
Medium
Unassigned

Bug Description

If I have a CIFS mount, and then that mount's server goes down, other file operations on my client system block until the Samba server comes back up. This causes extremely weird behavior, things like right-click menus not disappearing, mouse clicks in X not working at all while keyboard input does work, plasma-desktop fails to finish loading its configuration, resulting in half-empty panels and no wallpaper, etc.

I will try to illustrate:

$ grep cifs /etc/fstab
//server/Downloads /mnt/downloads cifs user,guest,noauto

$ mount /mnt/downloads

$ dolphin /mnt/downloads

$ ssh root@server "service smbd stop"

$ lsof | grep downloads
lsof: WARNING: can't stat() cifs file system /mnt/downloads
      Output information may be incomplete.
[lsof blocks here]

At this point, the weird bugs begin happening: Dolphin blocks when I right-click in its window. This leaves a blocked right-click menu (which is sometimes invisible, sometimes visible but empty, and sometimes a solid gray rectangle), and this blocked right-click menu grabs mouse clicks in X, preventing me from clicking anything else in X, while the keyboard continues working. At this point I kill Dolphin from a terminal using the keyboard, but plasma-desktop is still not responding to mouse clicks. So I kill and restart plasma-desktop from a terminal, but when it loads, it doesn't load completely, leaving a half-empty panel with missing applets, and no wallpaper--and still no response to mouse clicks.

But it's not all about X apps. Even /bin/df blocks. At one point, I wondered if my system had somehow run out of disk space, which can cause weird behavior, so I ran df. But df just sat there, with no output whatsoever.

And after all this, when I do:

$ ssh root@server "service smbd start"

Everything suddenly unblocks and works fine again.

It seems to me that having kernel CIFS mounts cause blocking in unrelated I/O is a major bug, potentially a security bug due to the denial-of-service issue. The way it causes an apparently inexplicable chain of weird behavior in all sorts of programs makes it very difficult to debug.

CIFS mounts are LAN mounts. It seems like a simple solution would be to have a very short timeout, 1-2 seconds or so. If it times out, just return an error and let the apps blocking on that I/O get on with what they're doing. The current behavior means that using kernel CIFS mounts is a recipe for disaster.

ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: linux-image-generic 3.13.0.24.29
ProcVersionSignature: Ubuntu 3.13.0-24.47-generic 3.13.9
Uname: Linux 3.13.0-24-generic x86_64
NonfreeKernelModules: fglrx
ApportVersion: 2.14.1-0ubuntu3.2
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC1: me 11691 F.... pulseaudio
 /dev/snd/controlC0: me 11691 F.... pulseaudio
CurrentDesktop: KDE
Date: Tue May 27 06:44:22 2014
InstallationDate: Installed on 2010-05-20 (1467 days ago)
InstallationMedia: Kubuntu 10.04 LTS "Lucid Lynx" - Release amd64 (20100427)
IwConfig:
 eth0 no wireless extensions.

 lo no wireless extensions.
MachineType: System manufacturer System Product Name
ProcFB: 0 VESA VGA
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-24-generic root=UUID=e3d95eec-f6ce-426f-b110-6633ff6f62c3 ro quiet splash vt.handoff=7
RelatedPackageVersions:
 linux-restricted-modules-3.13.0-24-generic N/A
 linux-backports-modules-3.13.0-24-generic N/A
 linux-firmware 1.127.2
RfKill:

SourcePackage: linux
UpgradeStatus: Upgraded to trusty on 2014-05-07 (20 days ago)
dmi.bios.date: 08/04/2009
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: 0602
dmi.board.asset.tag: To Be Filled By O.E.M.
dmi.board.name: P5Q PRO TURBO
dmi.board.vendor: ASUSTeK Computer INC.
dmi.board.version: Rev 1.xx
dmi.chassis.asset.tag: Asset-1234567890
dmi.chassis.type: 3
dmi.chassis.vendor: Chassis Manufacture
dmi.chassis.version: Chassis Version
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvr0602:bd08/04/2009:svnSystemmanufacturer:pnSystemProductName:pvrSystemVersion:rvnASUSTeKComputerINC.:rnP5QPROTURBO:rvrRev1.xx:cvnChassisManufacture:ct3:cvrChassisVersion:
dmi.product.name: System Product Name
dmi.product.version: System Version
dmi.sys.vendor: System manufacturer

Revision history for this message
Adam Porter (alphapapa) wrote :
summary: - Unresponsive CIFS mounts blocks unrelated I/O
+ Unresponsive CIFS mounts block unrelated I/O
Revision history for this message
Brad Figg (brad-figg) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

Would it be possible for you to test the latest upstream kernel? Refer to https://wiki.ubuntu.com/KernelMainlineBuilds . Please test the latest v3.15 kernel[0].

If this bug is fixed in the mainline kernel, please add the following tag 'kernel-fixed-upstream'.

If the mainline kernel does not fix this bug, please add the tag: 'kernel-bug-exists-upstream'.

If you are unable to test the mainline kernel, for example it will not boot, please add the tag: 'kernel-unable-to-test-upstream'.
Once testing of the upstream kernel is complete, please mark this bug as "Confirmed".

Thanks in advance.

[0] http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.15-rc7-utopic/

Changed in linux (Ubuntu):
importance: Undecided → Medium
status: Confirmed → Incomplete
penalvch (penalvch)
tags: added: bios-outdated-0701
Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for linux (Ubuntu) because there has been no activity for 60 days.]

Changed in linux (Ubuntu):
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.