jdk icon indicating copy to clipboard operation
jdk copied to clipboard

8291911: java/io/File/GetXSpace.java fails with "53687091200 != 161051996160"

Open bplb opened this issue 2 years ago • 7 comments

On Windows, suppress failure if the total space indicated by df is less than FileStore::getTotalSpace and the free space indicated by df equals FileStore::getUnallocatedSpace.


Progress

  • [ ] Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • [x] Change must not contain extraneous whitespace
  • [x] Commit message must refer to an issue

Issue

  • JDK-8291911: java/io/File/GetXSpace.java fails with "53687091200 != 161051996160"

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk pull/9856/head:pull/9856
$ git checkout pull/9856

Update a local copy of the PR:
$ git checkout pull/9856
$ git pull https://git.openjdk.org/jdk pull/9856/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 9856

View PR using the GUI difftool:
$ git pr show -t 9856

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/9856.diff

bplb avatar Aug 12 '22 14:08 bplb

Passed on 20 arbitrary nodes and on one where it failed previously due to user disk quotas.

bplb avatar Aug 12 '22 14:08 bplb

:wave: Welcome back bpb! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

bridgekeeper[bot] avatar Aug 12 '22 14:08 bridgekeeper[bot]

@bplb The following label will be automatically applied to this pull request:

  • core-libs

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.

openjdk[bot] avatar Aug 12 '22 14:08 openjdk[bot]

Webrevs

mlbridge[bot] avatar Aug 12 '22 14:08 mlbridge[bot]

This is hard to review. Would it be possible to provide a summary on how the APIs and df behave with quotas?

AlanBateman avatar Aug 15 '22 16:08 AlanBateman

This is hard to review. Would it be possible to provide a summary on the APIs and df behave with quotas?

We use the Windows API GetDiskFreeSpaceEx wherein it is stated

  • lpFreeBytesAvailableToCaller: If per-user quotas are being used, this value may be less than the total number of free bytes on a disk.
  • lpTotalNumberOfBytes: If per-user quotas are being used, this value may be less than the total number of bytes on a disk.

The df command on the other hand appears to be using something like GetQuotaInformation which fills a structure which accounts for the quota and provides the currently used and maximum allowed number of bytes for a user.

bplb avatar Aug 15 '22 17:08 bplb

In reality GetFreeDiskSpaceEx does not appear to recognize the quotas, at least in our tests.

bplb avatar Aug 15 '22 17:08 bplb

The version of the test in commit 991dc9a6bf86e3ec54fd1c244c655a86506a697d passed 5 repeats on Linux and macOS and 51 repeats on Windows, including on a node on which it previously failed.

bplb avatar Aug 17 '22 18:08 bplb

@bplb This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply add a new comment to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

bridgekeeper[bot] avatar Sep 15 '22 00:09 bridgekeeper[bot]

continue;

bplb avatar Sep 15 '22 00:09 bplb

Commit 8129630943ae98e79bceff18c20a5cb71d30ffd9 passed 50 repeats on the Unix platforms and 150 on Windows.

bplb avatar Oct 11 '22 21:10 bplb

@bplb This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply add a new comment to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

bridgekeeper[bot] avatar Nov 09 '22 08:11 bridgekeeper[bot]

Ping.

bplb avatar Nov 09 '22 18:11 bplb

@bplb 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:

8291911: java/io/File/GetXSpace.java fails with "53687091200 != 161051996160"

Reviewed-by: rriggs

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 17 new commits pushed to the master branch:

  • 102b2b32feec4727145be4814eb1a69ef462ff16: 8292033: Move jdk.X509Certificate event logic to JCA layer
  • 1b94ae13d3940951134a1010500fd95001b8cb15: 8296139: Make GrowableBitMap the base class of all implementations
  • cc8bf95046d1fba0f88b0e17481f36b2be870659: 8296718: Refactor bootstrap Test Common Functionalities to test/lib/Utils
  • 17e3412363bf5263c26d9bf1dfbef1fecc3d11a9: 8296615: use of undeclared identifier 'IPV6_DONTFRAG'
  • a5d838c337599d740e7940d7303b327199f4d07b: 8296591: Signature benchmark
  • fa8a8668a6656046d713a6b09244adfc81556d63: 8296675: Exclude linux-aarch64 in NSS tests
  • d4376f8b55391485365797d1c4d0dbbc6ed2ad92: 8296406: ChainingConstructors jtreg test reduce code duplication
  • 4a0093ccc4ec2880a789af3a50f30e44b686150e: 8294362: UL: Replace the internal usage of manual buffers with stringStream in LogSelection
  • fef68bbaf6de7e0d4be311a5f3648c16548c5b4d: 8296515: RISC-V: Small refactoring for MaxReductionV/MinReductionV/AddReductionV node implementation
  • 82cbfb5fb0db61f3f1d9f0ceeed20c1cf5474652: 8296140: Drop unused field java.util.Calendar.DATE_MASK
  • ... and 7 more: https://git.openjdk.org/jdk/compare/dd5d4df5b68a40923987841a206fac5032d72f71...master

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 master branch, type /integrate in a new comment.

openjdk[bot] avatar Nov 09 '22 21:11 openjdk[bot]

/integrate

bplb avatar Nov 14 '22 18:11 bplb

Going to push as commit 749335d34ac570760279ac81308d5d323aba4067. Since your change was applied there have been 66 commits pushed to the master branch:

  • 95b84050fc009b5665d20168d0470c9f31598d9a: 8296431: PushbackInputStream should override transferTo
  • e269dc03ad05e5734e08ca44d05e2eff4bdbc5fc: 8293681: ResponseAPDU getData() method javadoc
  • 8c472e481676ed0ef475c4989477d5714880c59e: 8294217: Assertion failure: parsing found no loops but there are some
  • 0fe2bf51b2f62bd95ef653fec4b97bea82e002e8: 8296805: ctw build is broken
  • e1d298c12d8c8f22d36ba9592d188a3162b0c6e5: 8296741: Illegal X400Address and EDIPartyName should not be created
  • b0edfc1159b160eb329a066dc2805c22937a5da8: 8164464: Consistent failure of java/awt/dnd/MissingEventsOnModalDialog/MissingEventsOnModalDialogTest.java
  • 9c399326724dc47eae90076d1237ff582b783863: 8294899: Process.waitFor() throws IllegalThreadStateException when a process on Windows returns an exit code of 259
  • 3f401b309124eecef7a39aac663bb5e8808a4476: 8296670: G1: Remove unused G1GCPhaseTimes::record_preserve_cm_referents_time_ms
  • 68301cdecae861ecb6c910aeb89465a787184454: 8296665: IGV: Show dialog with stack trace for exceptions
  • 277f0c24a2e186166bfe70fc93ba79aec10585aa: 8296821: compiler/jvmci/jdk.vm.ci.code.test/src/jdk/vm/ci/code/test/NativeCallTest.java fails after JDK-8262901
  • ... and 56 more: https://git.openjdk.org/jdk/compare/dd5d4df5b68a40923987841a206fac5032d72f71...master

Your commit was automatically rebased without conflicts.

openjdk[bot] avatar Nov 14 '22 18:11 openjdk[bot]

@bplb Pushed as commit 749335d34ac570760279ac81308d5d323aba4067.

:bulb: You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

openjdk[bot] avatar Nov 14 '22 18:11 openjdk[bot]