[Bug 198301] New: ext4 fails to create symlink if target length is greater than block size (but smaller than PATH_MAX)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



https://bugzilla.kernel.org/show_bug.cgi?id=198301

            Bug ID: 198301
           Summary: ext4 fails to create symlink if target length is
                    greater than block size (but smaller than PATH_MAX)
           Product: File System
           Version: 2.5
    Kernel Version: Confirmed in 4.4.103 & 4.10.0
          Hardware: All
                OS: Linux
              Tree: Mainline
            Status: NEW
          Severity: normal
          Priority: P1
         Component: ext4
          Assignee: fs_ext4@xxxxxxxxxxxxxxxxxxxx
          Reporter: ernst@xxxxxxxxxxxxxxx
        Regression: No

If the block size of an ext4 file system is smaller than PATH_MAX, ext4 will
fail to create symlinks to targets with names longer than block size minus one.

Expected result: Symlinks with targets up to a length of PATH_MAX - 1 can be
created.

Actual result: Symlinks with targets up to a length of block size - 1 can be
created. If block size smaller than PATH_MAX, creating symlinks with targets
equal or greater than block size and smaller than PATH_MAX will fail with
ENAMETOOLONG. 

The strange side effect of this bug is that one can not link to every file in a
file system with a block size of e.g. 1k while PATH_MAX is 4k.

For reference, the original test & discussion which triggered this bug:
https://github.com/pjd/pjdfstest/issues/24

-- 
You are receiving this mail because:
You are watching the assignee of the bug.



[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux