Bug 1374334

Summary: selinux prevents gnome-disks from working
Product: [Fedora] Fedora Reporter: pavel raur <pavel.raur.pr>
Component: selinux-policyAssignee: Miroslav Grepl <mgrepl>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 25CC: amigadave, bugzilla, dominick.grift, dwalsh, gmarr, lvrabec, mcatanzaro+wrong-account-do-not-cc, mgrepl, pavel.raur.pr, phatina, plautrba, puiterwijk, robatino, stefw, tsmetana, zeenix
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-09-14 14:04:39 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:
Bug Depends On:    
Bug Blocks: 1277289    
Attachments:
Description Flags
disks error picture
none
journalctl
none
packages on my pc
none
journal during gnome-disks operation none

Description pavel raur 2016-09-08 13:10:28 UTC
Created attachment 1199080 [details]
disks error picture

Description of problem:
Gnome-disk-utility can't setup FAT and NTFS partition after formatting.

Version-Release number of selected component (if applicable):
gnome-disk-utility-3.21.3-1.fc25.x86_64

How reproducible:
always

Steps to Reproduce:
1.start gnome-disk-utility
2.format disk
3.create FAT or NTFS partition on it

Actual results:
an error window will come up (picture in attachment)

Expected results:
selected partition type should by created on the disk

Additional info:

Comment 1 pavel raur 2016-09-08 13:11:26 UTC
Created attachment 1199081 [details]
journalctl

Comment 2 pavel raur 2016-09-08 13:12:02 UTC
Created attachment 1199090 [details]
packages on my pc

Comment 3 Fedora Blocker Bugs Application 2016-09-08 13:19:11 UTC
Proposed as a Blocker for 25-beta by Fedora user me2 using the blocker tracking app because:

 Violates final release criteria:

Default application functionality 

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.

All applications installed by default in Fedora Workstation must comply with each MUST and MUST NOT guideline in the Applications and Launchers policy.

Comment 4 Michael Catanzaro 2016-09-10 03:19:16 UTC
This is too niche to be a release blocker. If Disks couldn't show partition tables at all or just failed to start, that's the sort of basic functionality that would be a release blocker.

Anyway, the error is being returned by udisks_block_call_format_finish, so let's see what the udisks (storaged) developers think of it.

Comment 5 Chris Murphy 2016-09-10 18:15:31 UTC
Has udisksd mounted any file system on the drive having its partition table changed? At the time of the error message what you do get for 'cat /proc/mounts'? And then also what do you get if you issue 'partprobe' on the command line?

Comment 6 Chris Murphy 2016-09-11 19:53:52 UTC
sfdisk exits with status 1, fails to re-read the partition table because device or resource is busy. Could be bug 1371761.

Comment 7 Tomas Smetana 2016-09-12 10:14:28 UTC
I don't have an environment for testing this at hand right now... However: there are quite suspicious AVC denials in the log too. Are you sure they're not related?

Comment 8 Geoffrey Marr 2016-09-13 01:57:45 UTC
Discussed during the 2016-09-12 blocker review meeting: [1]

The decision to delay the classification of this as a bug was made as we believe it may have been fixed, so we will delay the decision to re-test and clarify the report.

[1] https://meetbot.fedoraproject.org/fedora-blocker-review/2016-09-12/f25-blocker-review.2016-09-12-16.01.txt

Comment 9 pavel raur 2016-09-13 07:41:16 UTC
With fully upddated fedora 25 disk works if you disable selinux, so its a problem in selinux. Attaching journal while formatting a flash drive and creating a partition with enforcing=0.

gnome-disk-utility-3.21.91-1.fc25.x86_64
selinux-policy-3.13.1-211.fc25.noarch
selinux-policy-targeted-3.13.1-211.fc25.noarch
storaged-2.6.2-2.fc25.x86_64
util-linux-2.28.2-1.fc25.x86_64

Comment 10 pavel raur 2016-09-13 07:42:04 UTC
Created attachment 1200376 [details]
journal during gnome-disks operation

Comment 11 Tomas Smetana 2016-09-14 14:04:39 UTC

*** This bug has been marked as a duplicate of bug 1375156 ***