-
Notifications
You must be signed in to change notification settings - Fork 5.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8338884: java/nio/file/attribute/BasicFileAttributeView/CreationTime.java#tmp fails on alinux3 #20687
Conversation
…linux3 after JDK-8338696
👋 Welcome back syan! A progress list of the required criteria for merging this PR into |
@sendaoYan This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be:
You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 618 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
@sendaoYan The following label will be automatically applied to this pull request:
When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command. |
Webrevs
|
/issue JDK-8338884 |
@sendaoYan This issue is referenced in the PR title - it will now be updated. |
What happens in the test without this change if the fix for JDK-8338696 is applied? |
As descript in JDK-8338884, this test will report fails |
So you are saying that with the fix for JDK-8338696 applied, this test fails with |
Yes, without this change, with the fix for JDK-8338696 applied, this test fails with RuntimeException |
To reproduce the fails, test command on most linux system: rm -rf /dev/shm/tmp/ ; jtreg -v:fail,error -w /dev/shm/tmp -nr test/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java#cwd |
test/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
Outdated
Show resolved
Hide resolved
… and !Files.getFileStore(file).type().contentEquals("tmpfs")
test/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
Outdated
Show resolved
Hide resolved
test/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
Outdated
Show resolved
Hide resolved
…me or not", and set nfs not suoport create time
> mount | grep "/vmfarm "
pepsi.jvm.alibaba.net:/vmfarm on /vmfarm type nfs4 (rw,relatime,vers=4.1,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,port=0,timeo=600,retrans=2,sec=sys,clientaddr=11.165.41.2,local_lock=none,addr=11.158.137.189)
> stat /vmfarm/mountVmFarm.sh
File: ‘/vmfarm/mountVmFarm.sh’
Size: 71 Blocks: 8 IO Block: 1048576 regular file
Device: 3ch/60d Inode: 12 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2024-02-28 17:03:54.713251462 +0800
Modify: 2020-03-03 11:56:41.548038922 +0800
Change: 2020-03-03 11:56:41.548038922 +0800
Birth: - |
On RHEL 8 tmpfs doesn't seem to support birth time, but on F39 tmpfs does seem to support birth time. Looks like this might be related to the kernel version. It's difficult to enumerate all the combination of file system type and linux kernel version to determine the testd file support birth time or not. So in this PR, I get the output from |
test/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
Outdated
Show resolved
Hide resolved
test/jdk/java/nio/file/attribute/BasicFileAttributeView/libCreationTimeHelper.c
Outdated
Show resolved
Hide resolved
I think this PR should be set as draft status, sorry for that. |
For whatever it shows, the test passed on Linux, macOS, and Windows in our CI. |
@bplb Do you mean the updated one in this PR or the old one without this patch? |
Thanks for the test. |
@AlanBateman Can you review this again, thanks. |
I don't have cycles right now but I'm sure @bplb can help. |
It's now in my queue. |
test/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
Outdated
Show resolved
Hide resolved
test/jdk/java/nio/file/attribute/BasicFileAttributeView/libCreationTimeHelper.c
Outdated
Show resolved
Hide resolved
The test passed on Linux, macOS, and Windows in our internal test platform. I think after the two most recent points mentioned above are addressed it is good to go. |
…ttributeView/libCreationTimeHelper.c; 2. use System.err instead of System.out in test/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
Thanks for the verify and review. The two advices has been addressed. |
test/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
Outdated
Show resolved
Hide resolved
…st/jdk/java/nio/file/attribute/BasicFileAttributeView/CreationTime.java
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks all right now.
Thanks all for the review. |
Going to push as commit 9d621d3.
Your commit was automatically rebased without conflicts. |
@sendaoYan Pushed as commit 9d621d3. 💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored. |
Hi all,
On alinux3(alibaba cloud linux version 3) system, the
/tmp
disk partition is mounted as tmpfs filesystem type, this filesystem type doesn't support create time(birth time).Before this PR, this test check if there is
statx
system call present or not to determise the test environment support birth time or not. I think it's not enough when the tested filesystem type istmpfs
. When the tested filesystem type istmpfs
, then the tested file doesn't support birth time.On RHEL 8 tmpfs doesn't seem to support birth time, but on F39 tmpfs does seem to support birth time. Looks like this might be related to the kernel version. It's difficult to enumerate all the combination of file system type and linux kernel version to determine the testd file support birth time or not. So in this PR, I get the result from
statx
linux syscall, to determine the testd file support birth time or not.Test fix only, the change has been verified, risk is low.
Additional test:
Progress
Issue
Reviewers
Reviewing
Using
git
Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/20687/head:pull/20687
$ git checkout pull/20687
Update a local copy of the PR:
$ git checkout pull/20687
$ git pull https://git.openjdk.org/jdk.git pull/20687/head
Using Skara CLI tools
Checkout this PR locally:
$ git pr checkout 20687
View PR using the GUI difftool:
$ git pr show -t 20687
Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/20687.diff
Webrev
Link to Webrev Comment