Issue description:
It is not possible sync repository https://packages.microsoft.com/rhel/8/prod/ because there are differences in sha256 checksums.
Repository URL: https://packages.microsoft.com/rhel/8/prod/
Example of affected package: adutil-preview-0.7.022-1.x86_64.rpm
[MIRROR] adutil-preview-0.7.022-1.x86_64.rpm: Downloading successful, but checksum doesn't match. Calculated: 7450321d76c36418ecee48545724bb98161cb9b14e51a4c5d2a2d5637595b107(sha256) Expected: 061d903499bbbacdbcc643eab29746a01a267b9aeacb4d10d96a4af957326925(sha256)
[FAILED] adutil-preview-0.7.022-1.x86_64.rpm: No more mirrors to try - All mirrors were already tried without success
## Package adutil-preview-0.7.022-1.x86_64.rpm sha256 checksum verification
7450321d76c36418ecee48545724bb98161cb9b14e51a4c5d2a2d5637595b107 adutil-preview-0.7.022-1.x86_64.rpm
## Information from repodata for package adutil-preview-0.7.022-1.x86_64.rpm
checksum type="sha256" pkgid="YES">061d903499bbbacdbcc643eab29746a01a267b9aeacb4d10d96a4af957326925
location href="adutil-preview-0.7.022-1.x86_64.rpm"
## sha256 checksum differences:
package: 7450321d76c36418ecee48545724bb98161cb9b14e51a4c5d2a2d5637595b107
repodata: 061d903499bbbacdbcc643eab29746a01a267b9aeacb4d10d96a4af957326925
Please verify packages and if necessary regenerate repodata. Thanks
@konstruktoid : Would you be able to verify the claim above from @libor-p ?
There is multiple issues with that repository.
Running sudo rpm -Uvh https://packages.microsoft.com/config/rhel/8/packages-microsoft-prod.rpm as instructed on https://docs.microsoft.com/en-us/windows-server/administration/linux-package-repository-for-microsoft-software fetches the correct RPM but the repo baseurl is incorrect, rhel/8.0/prod should be rhel/8/prod.
[packages-microsoft-com-prod]
name=packages-microsoft-com-prod
baseurl=https://packages.microsoft.com/**rhel/8.0/prod**
enabled=1
gpgcheck=1
gpgkey=https://packages.microsoft.com/keys/microsoft.asc
sslverify=1
$ curl https://packages.microsoft.com/**rhel/8.0/prod**/repodata/repomd.xml
<html>
<head><title>404 Not Found</title></head>
<body>
<center><h1>404 Not Found</h1></center>
<hr><center>nginx/1.16.1</center>
</body>
</html>
$ curl -s https://packages.microsoft.com/**rhel/8/prod**/repodata/repomd.xml | head -n3
<?xml version="1.0" encoding="UTF-8"?>
<repomd xmlns="http://linux.duke.edu/metadata/repo" xmlns:rpm="http://linux.duke.edu/metadata/rpm">
<revision>1605745291</revision>
I can however install adutil-preview, except answer the EULA question...
$ sudo dnf install adutil-preview
Last metadata expiration check: 0:02:36 ago on Mon 23 Nov 2020 09:36:41 PM UTC.
Dependencies resolved.
[...]
Install 4 Packages
Total download size: 7.5 M
Installed size: 17 M
Is this ok [y/N]: y
Downloading Packages:
(1/4): krb5-workstation-1.17-18.el8.x86_64.rpm 601 kB/s | 940 kB 00:01
(2/4): libkadm5-1.17-18.el8.x86_64.rpm 97 kB/s | 185 kB 00:01
(3/4): realmd-0.16.3-18.el8.x86_64.rpm 122 kB/s | 233 kB 00:01
(4/4): adutil-preview-0.7.029-1.x86_64.rpm 2.7 MB/s | 6.1 MB 00:02
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total 1.7 MB/s | 7.5 MB 00:04
warning: /var/cache/dnf/packages-microsoft-com-prod-37360e73ce94b4be/packages/adutil-preview-0.7.029-1.x86_64.rpm: Header V4 RSA/SHA256 Signature, key ID be1229cf: NOKEY
packages-microsoft-com-prod 2.6 kB/s | 983 B 00:00
Importing GPG key 0xBE1229CF:
Userid : "Microsoft (Release signing) <[email protected]>"
Fingerprint: BC52 8686 B50D 79E3 39D3 721C EB3E 94AD BE12 29CF
From : https://packages.microsoft.com/keys/microsoft.asc
Is this ok [y/N]: y
Key imported successfully
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Installing : realmd-0.16.3-18.el8.x86_64 1/4
Installing : libkadm5-1.17-18.el8.x86_64 2/4
Installing : krb5-workstation-1.17-18.el8.x86_64 3/4
Installing : adutil-preview-0.7.029-1.x86_64 4/4
Running scriptlet: adutil-preview-0.7.029-1.x86_64 4/4
Use of adutil requires acceptance of the adutil EULA.
Do you accept the terms of the EULA for adutil as specified at /usr/share/adutil/microsoft_adutil_pre-release_license.md y/N?
Cannot proceed with install since EULA was NOT accepted.
warning: %post(adutil-preview-0.7.029-1.x86_64) scriptlet failed, exit status 1
Error in POSTIN scriptlet in rpm package adutil-preview
Verifying : krb5-workstation-1.17-18.el8.x86_6
Error in POSTIN scriptlet in rpm package adutil-preview
Verifying : krb5-workstation-1.17-18.el8.x86_64 1/4
Verifying : libkadm5-1.17-18.el8.x86_64 2/4
Verifying : realmd-0.16.3-18.el8.x86_64 3/4
Verifying : adutil-preview-0.7.029-1.x86_64 4/4
Installed:
adutil-preview-0.7.029-1.x86_64 krb5-workstation-1.17-18.el8.x86_64 libkadm5-1.17-18.el8.x86_64 realmd-0.16.3-18.el8.x86_64
Complete!
$ sudo dnf install adutil-preview
Last metadata expiration check: 0:00:19 ago on Mon 23 Nov 2020 09:40:36 PM UTC.
Package adutil-preview-0.7.029-1.x86_64 is already installed.
Dependencies resolved.
Nothing to do.
Complete!
$ wget https://packages.microsoft.com/rhel/8/prod/adutil-preview-0.7.029-1.x86_64.rpm
[...]
$ rpm --checksig -v adutil-preview-0.7.029-1.x86_64.rpm
adutil-preview-0.7.029-1.x86_64.rpm:
Header V4 RSA/SHA256 Signature, key ID be1229cf: OK
Header SHA1 digest: OK
V4 RSA/SHA256 Signature, key ID be1229cf: OK
MD5 digest: OK
$ curl -sSL https://packages.microsoft.com/keys/microsoft.asc > ./microsoft.asc
$ sudo rpm --import ./microsoft.asc
$ rpm --checksig -v adutil-preview-0.7.029-1.x86_64.rpm
adutil-preview-0.7.029-1.x86_64.rpm:
Header V4 RSA/SHA256 Signature, key ID be1229cf: OK
Header SHA1 digest: OK
V4 RSA/SHA256 Signature, key ID be1229cf: OK
MD5 digest: OK
$ sha256sum adutil-preview-0.7.029-1.x86_64.rpm
acdf7aff04ac72c136e7c009784a0dc33d7aa8ff4af13c4a00239bfc43976a6e adutil-preview-0.7.029-1.x86_64.rpm
$ grep acdf7aff04ac72c136e7c009784a0dc33d7aa8ff4af13c4a00239bfc43976a6e a7828bf004485feff5b6003f5440fee5f13e1c2cd7247e7dc8ab97039b85eabc-filelists.xml
<package pkgid="acdf7aff04ac72c136e7c009784a0dc33d7aa8ff4af13c4a00239bfc43976a6e" name="adutil-preview" arch="x86_64">
Thanks a lot. That makes it much easier to find out if we are dealing with a documentation repo issue or a software package repo issue.
Looking up rhel/8.0/prod via a web search, there appears to be other tickets for this already here on GitHub, but they are all closed:
There is also a related post in git memory: https://www.gitmemory.com/issue/Azure/azure-storage-fuse/396/686815499
Not quite sure exactly what to make of this, but my most immediate thought is that this might not be fixable by a direct document edit, unless I have missed something obvious.
I'm using repository config file from https://packages.microsoft.com/config/rhel/8/prod.repo . Content of the file is:
[packages-microsoft-com-prod]
name=packages-microsoft-com-prod
baseurl=https://packages.microsoft.com/rhel/8/prod/
enabled=1
gpgcheck=1
gpgkey=https://packages.microsoft.com/keys/microsoft.asc
This is valid configuration. But issue is with repodata which are not aligned with packages. From my point of view, for example package adutil-preview-0.7.022-1.x86_64.rpm has been updated, but repodata were not re-generated after the change. It is reason why sha256 checksum for repodata and package is different.
Repodata re-generation of https://packages.microsoft.com/rhel/8/prod/ should fix the issue.
Yeah, this isn't a documentation issue, but there doesn't seem to be any other smooth way to report issues like this.
@libor-p, you're correct as well. A repodata re-generation and a verification of packages-microsoft-prod.rpm should be done.
Most helpful comment
Yeah, this isn't a documentation issue, but there doesn't seem to be any other smooth way to report issues like this.
@libor-p, you're correct as well. A repodata re-generation and a verification of
packages-microsoft-prod.rpmshould be done.