Bug 14771 - Some VFS operations on pathref (O_PATH) handles fail on GPFS
Summary: Some VFS operations on pathref (O_PATH) handles fail on GPFS
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: VFS Modules (show other bugs)
Version: unspecified
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Jule Anger
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-07-30 09:54 UTC by Ralph Böhme
Modified: 2021-10-05 13:19 UTC (History)
3 users (show)

See Also:


Attachments
Patch for 4.15 cherry-picked from master (27.31 KB, patch)
2021-08-31 16:22 UTC, Ralph Böhme
jra: review+
cs: review+
Details
Patch for 4.14 cherry-picked from master (13.47 KB, patch)
2021-08-31 16:23 UTC, Ralph Böhme
jra: review+
cs: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ralph Böhme 2021-07-30 09:54:37 UTC
Starting with 4.14 when using the gpfs VFS module the logs will be filled with messages like

[2021/07/14 15:17:00.456784,  1, pid=454928, effective(5194, 100003), real(5194, 0),
class=vfs] ../../source3/modules/vfs_gpfs.c:1697(vfs_gpfs_fget_dos_attributes)
vfs_gpfs_fget_dos_attributes: Getting winattrs failed for PATH Bad file descriptor

This is caused because apparently GPFS doesn't support gpfs_fstat_x() being called on an O_PATH handle. Future GPFS versions will change this, but we should be able to handle both cases in the VFS modules.

Additionally, gpfs_set_winattrs() may also be called on an pathref handle. As we already deal with the same problem in vfs_default when setting DOS attributes by using the /proc/fd path trick, we should employ the trick in vfs_gpfs.

Have patchset, need bugnumber.
Comment 1 Samba QA Contact 2021-08-26 20:09:03 UTC
This bug was referenced in samba master:

bcd6bed7b8611654a7e9752b258541f89414b020
145e739c440d39651d4f3d30682035ab868488ba
070dce224bbe190266682c5e362bc2b0ed798ecc
1a3ac7a940fbb4ad8575ee3b0c56c9de2bf4b1f6
730f8c49a9bc8333f0b722ad65e4e587421c21ec
fde1b98143568fc816165502583f72e73b5d6b71
3679f54f178ba6ddb940cc66f701e9b3a1dd543d
882a466ea5f45e5e2197f2408ccd560383e13c3f
443608ee8122a2c17258db8dca9885bb524957af
9a237e168a4bbd5665bd40d521506ca3a6825198
1bbdb81899be6c1da6fa9a63bf16a00401e09399
93a48399f427d114df63b434e7fcddc62a1d9ce5
fead05a45556993b80a84fe9bb07b10debb4ae62
Comment 2 Ralph Böhme 2021-08-31 16:22:05 UTC
Created attachment 16756 [details]
Patch for 4.15 cherry-picked from master
Comment 3 Ralph Böhme 2021-08-31 16:23:03 UTC
Created attachment 16757 [details]
Patch for 4.14 cherry-picked from master

This skips the changes in master that change vfs_gpfs_fntimes() which doesn't exist in 4.14.
Comment 4 Jeremy Allison 2021-08-31 17:58:01 UTC
Re-assigning to Jule for inclusion in 4.14.next, 4.15.0.
Comment 5 Jule Anger 2021-09-06 11:54:33 UTC
Pushed to autobuild-v4-{15,14}-test.
Comment 6 Samba QA Contact 2021-09-06 20:43:29 UTC
This bug was referenced in samba v4-15-test:

5b80738ec02fccde4d3eee34097a56e55deb8d18
f171810b970915cfe5dca8e325ad59df17d9c496
81fa1a65849e050c93a2998b7cc5069a3b68e9f3
3db79fdfd61c2a8884ed23f75bad179fd7c821cf
896a92e0382bcc19d72e2a89ba5f8a4b1d16c770
ee741bcc44ca939b4d70b071fccb88ef52b435cd
e07c7110e55ed8cf282d84a995258d4652a8c29b
45a63783526e48797689c1df0a5657fab9718fb8
3fe4d78f0217fb7d103a529504b6cad96c48c100
f626ffdf6d5a35e1c9c8e82e2dc9315a67100fa1
85e5508c4d9a040050e41e6667346bc7112fd012
a0fe4423b8e2fa9396a293910028ac4b53d81ec3
19485894d4b3b7e9f806434c686e880a94c8069b
Comment 7 Samba QA Contact 2021-09-07 08:42:38 UTC
This bug was referenced in samba v4-15-stable (Release samba-4.15.0rc5):

5b80738ec02fccde4d3eee34097a56e55deb8d18
f171810b970915cfe5dca8e325ad59df17d9c496
81fa1a65849e050c93a2998b7cc5069a3b68e9f3
3db79fdfd61c2a8884ed23f75bad179fd7c821cf
896a92e0382bcc19d72e2a89ba5f8a4b1d16c770
ee741bcc44ca939b4d70b071fccb88ef52b435cd
e07c7110e55ed8cf282d84a995258d4652a8c29b
45a63783526e48797689c1df0a5657fab9718fb8
3fe4d78f0217fb7d103a529504b6cad96c48c100
f626ffdf6d5a35e1c9c8e82e2dc9315a67100fa1
85e5508c4d9a040050e41e6667346bc7112fd012
a0fe4423b8e2fa9396a293910028ac4b53d81ec3
19485894d4b3b7e9f806434c686e880a94c8069b
Comment 8 Samba QA Contact 2021-09-07 10:49:03 UTC
This bug was referenced in samba v4-14-test:

a4a57724b929e9429fcab7ebae96ba0d6f1d7c52
994c64d309819f3e4f4822fd6c66ab12c3b7cb8f
4a17f42d00b20cf31c28c564e95937c7f457722c
d98e8e0e3f8e819d03a7e6a58c699f29476e3b13
4312b6c17dac27e0c90ceab52b0a61311ef8d618
08f18b66716030bc1b7cb4eacc6af6a32563793b
274236ff3db014f8b2003870ccd520bb5738b3a5
Comment 9 Jule Anger 2021-09-07 11:49:53 UTC
Closing out bug report.

Thanks!
Comment 10 Samba QA Contact 2021-10-05 13:19:15 UTC
This bug was referenced in samba v4-14-stable (Release samba-4.14.8):

a4a57724b929e9429fcab7ebae96ba0d6f1d7c52
994c64d309819f3e4f4822fd6c66ab12c3b7cb8f
4a17f42d00b20cf31c28c564e95937c7f457722c
d98e8e0e3f8e819d03a7e6a58c699f29476e3b13
4312b6c17dac27e0c90ceab52b0a61311ef8d618
08f18b66716030bc1b7cb4eacc6af6a32563793b
274236ff3db014f8b2003870ccd520bb5738b3a5