RFR: 8262844: (fs) FileStore.supportsFileAttributeView might return false negative in case of ext3 [v2]

Arno Zeller azeller at openjdk.java.net
Wed Mar 3 17:56:19 UTC 2021


On Wed, 3 Mar 2021 14:54:08 GMT, Alan Bateman <alanb at openjdk.org> wrote:

>> Arno Zeller has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains three additional commits since the last revision:
>> 
>>  - Removed special handling for ext4 too
>>  - Merge remote-tracking branch 'upstream/master' into LinuxFileStore
>>  - Fix ext3 detection in LinuxFileStore
>
> src/java.base/linux/classes/sun/nio/fs/LinuxFileStore.java line 144:
> 
>> 142:             }
>> 143: 
>> 144:             // no other information available so probe mount point
> 
> You've removed the special handling for ext4 too, did you mean to do that? I think we'll need to do a lot of testing with this change as I suspect it going to bite back in some unusual configurations.

Yes the change was intentional. I thought that ext4 has the same issues as ext3 and it might be possible to change the mount options or default mount options for ext4 with tune2fs to contain nouser_xattr. In this case the JDK would not detect that  extended attributes are not supported. But I must admit that I just falsified my theory. tune2fs does not allow nouser_xattr as mount option. So for ext4 it can only be that someone uses a kernel that was configured to not support extended attributes on ext4 - this might not occur in real life.
I will revert the change back to the original first change.

-------------

PR: https://git.openjdk.java.net/jdk/pull/2778


More information about the nio-dev mailing list