Bazel corrupt installation false positive on when output_user_root on a REFS partion
#19 006 ouverte le 20 juil. 2023
Métriques du dépôt
- Stars
- (25 384 stars)
- Métriques de merge PR
- (Merge moyen 22j 20h) (77 PRs mergées en 30 j)
Description
Description of the bug:
When you run bazel with an output_user_root on a ReFS partition on windows you get the following error the second time you run bazel info:
FATAL: corrupt installation: file 'd:\bzl\install\514d6bd1346ca30a25ef0dae1a54ba5f\embedded_tools\jdk\bin\java.exe' is missing or modified. Please remove 'd:\bzl/install/514d6bd1346ca30a25ef0dae1a54ba5f' and try again.
Using process monitor you can see the last modified time of java.exe you can see have been changed by something. We tried implementing flush on windows, and we no-longer have a flush which may have caused the issue, however we still see the modified time set back.
What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
On windows 11 Run "Disk Management": action -> Create VHD - select a new location and give it say 10Gb and a Fixed Size Format Mount the VHD to a drive letter and you will need to use NTFS initially
In File explorer take the new driver you have created and format it ReFS I assume the drive is D: for this reproduction
cd D:
mkdir test
cd test
echo foo > WORKSPACE
bazel --output_user_root=D:/bzl
bazel --output_user_root=D:/bzl
On the first run it extracts and runs bazel On the second run you get the error
Which operating system are you running Bazel on?
Windows 11
What is the output of bazel info release?
release 6.2.1
If bazel info release returns development version or (@non-git), tell us how you built Bazel.
No response
What's the output of git remote get-url origin; git rev-parse master; git rev-parse HEAD ?
No response
Is this a regression? If yes, please try to identify the Bazel commit where the bug was introduced.
No response
Have you found anything relevant by searching the web?
No response
Any other information, logs, or outputs that you want to share?
No response