Bug 1563674

Summary: Nautilus silently fails to delete non-empty directories on Samba share
Product: [Fedora] Fedora Reporter: Jonathan Underwood <jonathan.underwood>
Component: sambaAssignee: Guenther Deschner <gdeschner>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 28CC: abokovoy, alexl, anoopcs, asn, bcotton, cosimo.cecchi, extras-orphan, gdeschner, gmarr, hugh, jarrpa, jkurik, john.j5live, jonathan.underwood, kparal, lmohanty, madam, mbarnes, mclasen, rhughes, robatino, rpm, sandmann, sbose, ssorce
Target Milestone: ---Keywords: CommonBugs, Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: RejectedBlocker https://fedoraproject.org/wiki/Common_F28_bugs#nautilus-samba-delete-dir PrioritizedBug
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-09-11 18:50:13 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jonathan Underwood 2018-04-04 12:23:58 UTC
Description of problem:
Nautilus fails to delete non-empty directories on Samba shares. Selecting a directory and right clicking and selecting delete permanently results in the directory disappearing from the Nautilus window, as would be expected for a delete. However, looking on the server, the directory is stil pressent. Navigating out of the directory and back into it in Nautilus shows that the directory re-appears. Debugging gvfs shows that no errors arise due to this.

Version-Release number of selected component (if applicable):
nautilus-3.26.3.1-1.fc27.x86_64
gvfs-smb-1.34.2.1-1.fc27.x86_64
gvfs-1.34.2.1-1.fc27.x86_64

How reproducible:
Everytime

Steps to Reproduce:
1. Access a Samba share in Nautilus
2. Select a non-empty directory, right click, and choose to delete permanently
3.

Actual results:
Directory not deleted

Expected results:
Directory deleted.

Comment 2 Jonathan Underwood 2018-04-04 13:19:18 UTC
Verified this behaviour persists in Fedora 28 beta.

Comment 3 Fedora Blocker Bugs Application 2018-04-04 13:28:46 UTC
Proposed as a Blocker for 28-final by Fedora user jgu using the blocker tracking app because:

 The Fedora 28 release criteria state: 

"All applications that can be launched using the standard graphical mechanism of a release-blocking desktop after a default installation of that desktop must start successfully and withstand a basic functionality test." 

I would argue that deleting directories correctly on Samba shares is basic functionality of the default file manager (Nautilus). The reason that it can't is due to a bug in libsmbclient provided by the Samba package. From an end user perspective, Nautilus appears to have deleted a directory, but actually hasn't.

Comment 4 Geoffrey Marr 2018-04-09 18:04:35 UTC
Discussed during the 2018-04-09 blocker review meeting: [1]

The decision to classify this bug as a RejectedBlocker was made as the QA team does not find the "basic functionality" of the Nautilus package to be impacted, as there are several obvious workarounds and this could be addressed with an update in the future.

[1] https://meetbot.fedoraproject.org/fedora-blocker-review/2018-04-09/f28-blocker-review.2018-04-09-16.01.txt

Comment 5 Jonathan Underwood 2018-04-28 11:36:17 UTC
Note that this text in the F28 Common Bugs is incorrect: 

"If you access Samba (smb) shares using Nautilus, it's not possible to delete non-empty directories due to a bug. Current workaround is to delete files in that directory first (tedious), or use a different application for accessing that share (that is not using gvfs library, as Nautilus does)."

It's not a case of using an application that doesn't use gvfs. Rather, it's a case of using an application that doesn't make use of libsmbclient. I don't know of any such application, though.

Comment 6 Jonathan Underwood 2018-04-28 13:09:38 UTC
(In reply to Jonathan Underwood from comment #5)
> Note that this text in the F28 Common Bugs is incorrect: 
> 
> "If you access Samba (smb) shares using Nautilus, it's not possible to
> delete non-empty directories due to a bug. Current workaround is to delete
> files in that directory first (tedious), or use a different application for
> accessing that share (that is not using gvfs library, as Nautilus does)."
> 
> It's not a case of using an application that doesn't use gvfs. Rather, it's
> a case of using an application that doesn't make use of libsmbclient. I
> don't know of any such application, though.

I have confirmed that using Dolphin is a workaround for this problem.

Comment 7 Kamil Páral 2018-04-30 10:33:08 UTC
Proposing as a PrioritizedBug. This is a very common use case and a very annoying issue for anyone using samba shares.

Comment 8 Jonathan Underwood 2018-05-12 23:30:45 UTC
There's a candidate patch here:

 https://bug792147.bugzilla-attachments.gnome.org/attachment.cgi?id=371928

Any chance of pushing a package build with this to updates-testing ?

Comment 9 Jan Kurik 2018-06-06 14:16:18 UTC
Guenther, will it be possible please to provide a fixed package for the F28 release into updates-testing (see the comment above) ?

Comment 10 Ben Cotton 2018-08-01 20:46:04 UTC
Accepted as a PrioritizedBug

Comment 11 Guenther Deschner 2018-09-11 18:50:13 UTC
This bug has been resolved with a Samba update that has been shipped to f28 recently. Just verified it with nautilus and libsmbclient-4.8.5-0.fc28.x86_64