Comments (5)
@rmohr Can you please take a look ?
from kubevirt.
Suspect cause:
This is suspect to be a defect of bazeldnf. The bazeldnf selects package from upstream centos8/9 or local docker container (in our case). For some reason, bazeldnf messed up.
Guess this might be related to https://github.com/rmohr/bazeldnf/blob/67cb93b4fd7dd217cafac3625dd09313dde9dad2/pkg/bazel/bazel.go#L125C1-L135C36, which seems trying to fix it but does not work for this case.
We are using KubeVirt release-1.0.1
I don't think it is related to this. This path is only executed when resolving dependencies from a remote repository to write the expected checksums to the WORKSPACE file (would be called during jack/rpm-deps.sh
to update dependencies in the WORKSPACE file but it does not actually download any RPMs, nor does it itself calculate a checksum).
rpm( // this is line 2360
name = "libmpc-0__1.1.0-9.1.el8.x86_64",
sha256 = "4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95",
urls = ["http://rpms:80/AppStream/Packages/libmpc-1.1.0-9.1.el8.x86_64.rpm"],
)
So here it seems to have the correct digest. The rpm
rule is just a thin wrapper around what http_archive
does. If there would be a bug passing down the sha256
to the bazel downloader, I think we would know about this already, but maybe that would be something ...
Error in download: java.io.IOException: Error downloading [http://rpms:80/AppStream/Packages/libmpc-1.1.0-9.1.el8.x86_64.rpm] to /root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/external/libmpc-0__1.1.0-9.1.el8.x86_64/rpm/downloaded: Checksum was 4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95 but wanted 93c2232d1885ec6265159f4669aeb13335a80e74d3ae0832f624678d87ea3638
This seems to look like we would have in the WORKSPACE file the checksum 93c2232d1885ec6265159f4669aeb13335a80e74d3ae0832f624678d87ea3638
specified, but according to your code snippet above you have 4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95
there. This looks to me like a very suspicius thing when you say that the checksum of the file actually is 4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95
in the container.
It looks to me like some important bit of info is missing or not entirely correct. Because what I would expect to see in your case would be a message the other way round, that it wanted 4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95
but got 93c2232d1885ec6265159f4669aeb13335a80e74d3ae0832f624678d87ea3638
.
Just to highlight it again:
Bazeldnf should calculate the checksum based on the downloaded RPM in the builder, in this case it is /root/.cache/bazel/_bazel_root/6f347497f91c9a385dcd9294645b76e0/external/libmpc-0__1.1.0-9.1.el8.x86_64/rpm/downloaded. The checksum should be consistent.
Bazeldnf does not do that. It just writes a checksum it gets from the repo information into the WORKSPACE file. If you have there 4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95
, then we just call BAZELs download things and are no longer involved during build (https://github.com/rmohr/bazeldnf/blob/main/internal/rpm.bzl#L25).
from kubevirt.
Thanks @rmohr for your response. This is a very weird error we don't understand. It is reproducing on local dev env and CI. We expect the WORKSPACE is the only place where customized RPM is updated, e,g, checksum and rul, as what we already do in above example. The incorrect checksum this error was suggesting (93c2232d1885ec6265159f4669aeb13335a80e74d3ae0832f624678d87ea3638
) seems is from an upstream rpm stream. We've explicitly cleaned the cache by Makefile and hack/dockerized, wondering if there are something still missing.
Can you please point me any suggestions or workaround that can fix this blocker ?
from kubevirt.
Can you please point me any suggestions or workaround that can fix this blocker ?
Can you grep the WORKSPACE file and all cache directories for the 93c2232d1885ec6265159f4669aeb13335a80e74d3ae0832f624678d87ea3638
checksum and maybe backtrace where this value is even coming from?
from kubevirt.
I see the files rsynced into builder container is not identical to the kubevirt on the host..
The synced WORKSPACE inside the container is 93c2232d1885ec6265159f4669aeb13335a80e74d3ae0832f624678d87ea3638
:
[root@f80633154e04 kubevirt]# grep -B3 libmpc-1.1.0-9.1.el8.x86_64.rpm /root/go/src/kubevirt.io/kubevirt/WORKSPACE
rpm(
name = "libmpc-0__1.1.0-9.1.el8.x86_64",
sha256 = "93c2232d1885ec6265159f4669aeb13335a80e74d3ae0832f624678d87ea3638",
urls = ["http://rpms:80/AppStream/Packages/libmpc-1.1.0-9.1.el8.x86_64.rpm"],
This is not the same of what is defined in KubeVirt project on host, which is :
➜ kubevirt git:(release-1.0.1) ✗ grep -B3 libmpc-1.1.0-9.1.el8.x86_64.rpm WORKSPACE
rpm(
name = "libmpc-0__1.1.0-9.1.el8.x86_64",
sha256 = "4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95",
urls = ["http://rpms:80/AppStream/Packages/libmpc-1.1.0-9.1.el8.x86_64.rpm"],
I just directly downloaded rpm from RPM container. The checksum is 4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95
[root@f80633154e04 tmp]# wget http://rpms:80/AppStream/Packages/libmpc-1.1.0-9.1.el8.x86_64.rpm
[root@f80633154e04 tmp]# sha256sum libmpc-1.1.0-9.1.el8.x86_64.rpm
4fbf751702394211896af9f253ad2f38c80f603e007a7c9ed2b9c8e5d97f2f95
digging..
update:
I figured out the cause. Thanks !
from kubevirt.
Related Issues (20)
- How to add multiple DNS search domains and DNS ndots option to a guest VM's search list of /etc/resolv.conf HOT 4
- Hashing the VM name for the UUID leads to duplicates HOT 5
- DRAFT: [GSoC] Unification of Container Disk and Hotplug Features in Kubevirt HOT 1
- Can not create a VMI in a bare metal k8s environment HOT 13
- Handler Mem/CPU request configurable? HOT 4
- Bazel can't push to private repository HOT 5
- Optimize IsKubeVirtServiceAccount() HOT 3
- e2e: swap-enabled tests are failing on k8s-1.29 HOT 2
- Windows 10/11 and iscsi claim doesn't work HOT 3
- Proposal changes for hook sidecar Beta HOT 3
- GKE - websocket: bad handshake and Error starting VirtualMachine the server has asked for the client to provide credentials HOT 5
- Remove the `virt_launcher.process` custom SELinux policy HOT 2
- VirtualMachine is in crashingbackoff state HOT 7
- virt-launcher fails with "Connecting to libvirt daemon failed" on EKS HOT 6
- Modifying the instancetype does not cause the virtual machine's Current CPU Topology value to refresh. HOT 4
- refactor: replace all the datavolumes and pvcs name assignements with PVCNameFromVirtVolume HOT 3
- KubeVirt coding guidelines or best practices HOT 10
- refactor: simplify reconcileSpec in restore.go HOT 4
- Cannot apply updates from a GitOps manager (Rancher Fleet etc.). Generation field implicitly added HOT 3
- kubevirt-launcher panic when using hookSidecars to add vhostuser disk device HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kubevirt.