Bug 844485
Summary: | Cannot create files on ntfs-3g filesystem | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Richard W.M. Jones <rjones> |
Component: | kernel | Assignee: | Kernel Maintainer List <kernel-maint> |
Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | rawhide | CC: | dyasny, gansalmon, itamar, jonathan, kernel-maint, madhu.chinakonda, mbooth |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2012-08-13 20:11:53 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
Richard W.M. Jones
2012-07-30 20:56:41 UTC
Finally I can reproduce this one, in a Rawhide guest. By updating components one at a time I determined that what cause the bug is updating to kernel 3.6.0-0.rc0.git4.1.fc18.x86_64. Here is a reproducer: guestfish -xv -N fs:ntfs -m /dev/sda1 \ mkdir-p /Windows/System32/Config : \ upload tests/guests/guest-aux/windows-software /Windows/System32/Config/SOFTWARE Setting the environment variable FEBOOTSTRAP_KERNEL before the build makes the bug go away if you use export FEBOOTSTRAP_KERNEL=/boot/vmlinuz-3.5.0-1.fc18.x86_64 and reappear reliably if you use: export FEBOOTSTRAP_KERNEL=/boot/vmlinuz-3.6.0-0.rc0.git4.1.fc18.x86_64 I wonder if the new kernel has broken FUSE support in some way? Here's an even simpler reproducer which shows that simply creating a directory and writing to a file fails: FEBOOTSTRAP_KERNEL=/boot/vmlinuz-3.6.0-0.rc0.git4.1.fc18.x86_64 \ guestfish -xv -N fs:ntfs -m /dev/sda1 mkdir /foo : write /foo/bar data The error is: libguestfs: error: write: open: /foo/bar: No such file or directory Some variations on a theme. The directory exists and can be listed with "ls -l": $ guestfish -N fs:ntfs -m /dev/sda1 mkdir /foo : ll / total 8 drwxrwxrwx 1 root root 4096 Aug 1 13:56 . drwxr-xr-x 23 1000 1000 4096 Aug 1 13:56 .. drwxrwxrwx 1 root root 0 Aug 1 13:56 foo $ guestfish -N fs:ntfs -m /dev/sda1 mkdir /foo : ll /foo total 4 drwxrwxrwx 1 root root 0 Aug 1 13:56 . drwxrwxrwx 1 root root 4096 Aug 1 13:56 .. But a simple 'touch' of any file in there fails: $ guestfish -N fs:ntfs -m /dev/sda1 mkdir /foo : touch /foo/bar libguestfs: error: touch: open: /foo/bar: No such file or directory [Here is the code that the 'touch' command executes: https://github.com/libguestfs/libguestfs/blob/499497fab03716278cb5214a8aa89a35618e06c6/daemon/file.c#L32 The error is at line 69] Adding a 10 second sleep before the touch does not help, so it's not a race condition or timing related. Adding sync before the touch doesn't help either. 'touch' in the root directory of the NTFS filesystem also fails. $ guestfish -N fs:ntfs -m /dev/sda1 touch /foo libguestfs: error: touch: open: /foo: No such file or directory Using the regular echo bash-builtin also fails: $ guestfish -N fs:ntfs -m /dev/sda1 debug sh "echo > /sysroot/foo" libguestfs: error: debug: /bin/sh: /sysroot/foo: No such file or directory Upstream report of the same thing: http://sourceforge.net/mailarchive/message.php?msg_id=29617641 git bisect: c8ccbe032feb127a977c66865cb63d72d9a6e08b is the first bad commit commit c8ccbe032feb127a977c66865cb63d72d9a6e08b Author: Miklos Szeredi <mszeredi> Date: Tue Jun 5 15:10:22 2012 +0200 fuse: implement i_op->atomic_open() Add an ->atomic_open implementation which replaces the atomic open+create operation implemented via ->create. No functionality is changed. Signed-off-by: Miklos Szeredi <mszeredi> Signed-off-by: Al Viro <viro.org.uk> :040000 040000 7a000897ad0d1524a7e1cb187bc77d92b8397d56 38f02e55f70b009f8b1149cdd75f571c72406fe4 M fs Miklos posted the following fix: http://sourceforge.net/mailarchive/message.php?msg_id=29630599 and I have tested this patch on top of linux.git and confirmed that it does indeed fix this bug. Believe Miklos wound up submitting a larger series to fix this upstream: http://thread.gmane.org/gmane.linux.file-systems/66445/focus=1339000 We'll pick that up through Linus' tree (In reply to comment #8) > Believe Miklos wound up submitting a larger series to fix this upstream: > > http://thread.gmane.org/gmane.linux.file-systems/66445/focus=1339000 > > We'll pick that up through Linus' tree I applied these patches on top of kernel-3.6.0-0.rc1.git3.2 and they fix all[*] of the problems with ntfs-3g and FUSE that I found. [*] There are several problems, not just this bug. (In reply to comment #9) > (In reply to comment #8) > > Believe Miklos wound up submitting a larger series to fix this upstream: > > > > http://thread.gmane.org/gmane.linux.file-systems/66445/focus=1339000 > > > > We'll pick that up through Linus' tree > > I applied these patches on top of kernel-3.6.0-0.rc1.git3.2 > and they fix all[*] of the problems with ntfs-3g and FUSE > that I found. > > [*] There are several problems, not just this bug. Linus is on vacation and those patches are taking their sweet time getting into his tree. I'll pull them into F18/rawhide this afternoon. Thanks much for reporting and testing on this one. OK, committed. And building. Should be in tomorrow's F18/rawhide. FYI all 4 patches went into Linus's kernel. |