Skip to content

WSL2 with any linux distro: apt-get update Hash Sum mismatch #12774

@kinseii

Description

@kinseii

Windows Version

Microsoft Windows [Version 10.0.26100.3476]

WSL Version

2.4.13.0

Are you using WSL 1 or WSL 2?

  • WSL 2
  • WSL 1

Kernel Version

Linux version 5.15.167.4-microsoft-standard-WSL2 (root@f9c826d3017f) (gcc (GCC) 11.2.0, GNU ld (GNU Binutils) 2.37) #1 SMP Tue Nov 5 00:21:55 UTC 2024

Distro Version

Ubuntu 24.02

Other Software

I have the issue with apt-get update command: Hash Sum mismatch.

WSL version: 2.4.13.0
Kernel version: 5.15.167.4-1
WSLg version: 1.0.65
MSRDC version: 1.2.5716
Direct3D version: 1.611.1-81528511
DXCore version: 10.0.26100.1-240331-1435.ge-release
Windows version: 10.0.26100.3476

WSL:

Windows Subsystem for Linux Distributions:
Ubuntu-24.04 (Default)

Log:

root@nb1:/etc/apt/sources.list.d# apt-get update
Get:1 http://archive.ubuntu.com/ubuntu noble InRelease [256 kB]
Get:2 http://archive.ubuntu.com/ubuntu noble-updates InRelease [126 kB]
Get:3 http://archive.ubuntu.com/ubuntu noble-backports InRelease [126 kB]
Get:4 http://archive.ubuntu.com/ubuntu noble/main amd64 Packages [1401 kB]
Get:5 http://security.ubuntu.com/ubuntu noble-security InRelease [126 kB]
Get:6 http://archive.ubuntu.com/ubuntu noble/main Translation-en [513 kB]
Get:7 http://archive.ubuntu.com/ubuntu noble/main amd64 Components [464 kB]
Get:8 http://archive.ubuntu.com/ubuntu noble/main amd64 c-n-f Metadata [30.5 kB]
Get:9 http://archive.ubuntu.com/ubuntu noble/universe amd64 Packages [15.0 MB]
Get:10 http://security.ubuntu.com/ubuntu noble-security/main amd64 Packages [731 kB]
Err:9 http://archive.ubuntu.com/ubuntu noble/universe amd64 Packages
  Hash Sum mismatch
  Hashes of expected file:
   - Filesize:15037908 [weak]
   - SHA256:ba9057fa1b91438cc8a1d26808d00c85389fe101d0c1496254df97236405599a
   - SHA1:f90c48a0fe91f4bff279e60eb7e5583cb898848a [weak]
   - MD5Sum:070718db2f33ee0a489e9abbfb780cbe [weak]
  Hashes of received file:
   - SHA256:fa5b1856dd1e47a902036286d320fedf2dce38fc2bc7b3490c802b4703e7e47d
   - SHA1:37a7669aae950cb135baf9c3a15b3564634b2f8a [weak]
   - MD5Sum:bd82d3ab1c2ca3c658eb0aabaa0ca946 [weak]
   - Filesize:15037908 [weak]
  Last modification reported: Thu, 25 Apr 2024 11:56:24 +0000
  Release file created at: Thu, 25 Apr 2024 15:10:33 +0000
Get:11 http://archive.ubuntu.com/ubuntu noble/universe Translation-en [5982 kB]
Get:12 http://archive.ubuntu.com/ubuntu noble/universe amd64 Components [3871 kB]
Get:13 http://archive.ubuntu.com/ubuntu noble/universe amd64 c-n-f Metadata [301 kB]
Get:14 http://archive.ubuntu.com/ubuntu noble/restricted amd64 Packages [93.9 kB]
Get:15 http://archive.ubuntu.com/ubuntu noble/restricted Translation-en [18.7 kB]
Get:16 http://archive.ubuntu.com/ubuntu noble/restricted amd64 c-n-f Metadata [416 B]
Get:17 http://archive.ubuntu.com/ubuntu noble/multiverse amd64 Packages [269 kB]
Get:18 http://archive.ubuntu.com/ubuntu noble/multiverse Translation-en [118 kB]
Get:19 http://archive.ubuntu.com/ubuntu noble/multiverse amd64 Components [35.0 kB]
Get:20 http://archive.ubuntu.com/ubuntu noble/multiverse amd64 c-n-f Metadata [8328 B]
Get:21 http://archive.ubuntu.com/ubuntu noble-updates/main amd64 Packages [979 kB]
Get:22 http://security.ubuntu.com/ubuntu noble-security/main Translation-en [139 kB]
Get:23 http://security.ubuntu.com/ubuntu noble-security/main amd64 Components [8976 B]
Get:24 http://security.ubuntu.com/ubuntu noble-security/main amd64 c-n-f Metadata [7068 B]
Get:25 http://security.ubuntu.com/ubuntu noble-security/universe amd64 Packages [827 kB]
Get:26 http://archive.ubuntu.com/ubuntu noble-updates/main Translation-en [215 kB]
Get:27 http://archive.ubuntu.com/ubuntu noble-updates/main amd64 Components [151 kB]
Get:28 http://archive.ubuntu.com/ubuntu noble-updates/main amd64 c-n-f Metadata [13.5 kB]
Get:29 http://archive.ubuntu.com/ubuntu noble-updates/universe amd64 Packages [1046 kB]
Err:29 http://archive.ubuntu.com/ubuntu noble-updates/universe amd64 Packages
  Hash Sum mismatch
  Hashes of expected file:
   - Filesize:1046312 [weak]
   - SHA256:13bff52e8634d4ea1f89f00ee0b290a345d2c6f32c7116bd5fc236a271e9cc7e
   - SHA1:9762c757406765f90d1bedd1ea32f6e87ce8c9a2 [weak]
   - MD5Sum:c4683a262b93f9575fc2c5781aad5edb [weak]
  Hashes of received file:
   - SHA256:fde58e9769d9c9824e4878b1aa53fc4660b5231a0ac23490ea383f2a1c26ec48
   - SHA1:61e5682470aeb49333e663f3d27152e4483777f3 [weak]
   - MD5Sum:34262e8a99f962519682f11160e6469b [weak]
   - Filesize:1046312 [weak]
  Last modification reported: Wed, 02 Apr 2025 02:42:48 +0000
  Release file created at: Wed, 02 Apr 2025 04:05:03 +0000
Get:30 http://archive.ubuntu.com/ubuntu noble-updates/universe Translation-en [263 kB]
Get:31 http://archive.ubuntu.com/ubuntu noble-updates/universe amd64 Components [365 kB]
Get:32 http://archive.ubuntu.com/ubuntu noble-updates/universe amd64 c-n-f Metadata [26.0 kB]
Get:33 http://archive.ubuntu.com/ubuntu noble-updates/restricted amd64 Packages [876 kB]
Get:34 http://security.ubuntu.com/ubuntu noble-security/universe Translation-en [179 kB]
Err:33 http://archive.ubuntu.com/ubuntu noble-updates/restricted amd64 Packages

Get:35 http://archive.ubuntu.com/ubuntu noble-updates/restricted Translation-en [177 kB]
Get:36 http://security.ubuntu.com/ubuntu noble-security/universe amd64 Components [51.9 kB]
Get:37 http://archive.ubuntu.com/ubuntu noble-updates/restricted amd64 Components [212 B]
Get:38 http://archive.ubuntu.com/ubuntu noble-updates/restricted amd64 c-n-f Metadata [492 B]
Get:39 http://archive.ubuntu.com/ubuntu noble-updates/multiverse amd64 Packages [21.5 kB]
Get:40 http://security.ubuntu.com/ubuntu noble-security/universe amd64 c-n-f Metadata [17.0 kB]
Get:41 http://security.ubuntu.com/ubuntu noble-security/restricted amd64 Packages [844 kB]
Err:39 http://archive.ubuntu.com/ubuntu noble-updates/multiverse amd64 Packages

Get:42 http://archive.ubuntu.com/ubuntu noble-updates/multiverse Translation-en [4788 B]
Get:43 http://archive.ubuntu.com/ubuntu noble-updates/multiverse amd64 Components [940 B]
Get:44 http://archive.ubuntu.com/ubuntu noble-backports/main amd64 Packages [39.1 kB]
Get:45 http://archive.ubuntu.com/ubuntu noble-backports/main Translation-en [8676 B]
Get:46 http://archive.ubuntu.com/ubuntu noble-backports/main amd64 Components [7068 B]
Get:47 http://archive.ubuntu.com/ubuntu noble-backports/main amd64 c-n-f Metadata [272 B]
Get:48 http://archive.ubuntu.com/ubuntu noble-backports/universe amd64 Packages [26.4 kB]
Get:49 http://archive.ubuntu.com/ubuntu noble-backports/universe Translation-en [16.3 kB]
Get:50 http://archive.ubuntu.com/ubuntu noble-backports/universe amd64 Components [15.7 kB]
Get:51 http://archive.ubuntu.com/ubuntu noble-backports/universe amd64 c-n-f Metadata [1304 B]
Get:52 http://archive.ubuntu.com/ubuntu noble-backports/restricted amd64 Components [216 B]
Get:53 http://security.ubuntu.com/ubuntu noble-security/restricted Translation-en [170 kB]
Get:54 http://security.ubuntu.com/ubuntu noble-security/restricted amd64 Components [212 B]
Get:55 http://security.ubuntu.com/ubuntu noble-security/restricted amd64 c-n-f Metadata [468 B]
Get:56 http://security.ubuntu.com/ubuntu noble-security/multiverse amd64 Packages [17.6 kB]
Get:57 http://security.ubuntu.com/ubuntu noble-security/multiverse Translation-en [3792 B]
Get:58 http://archive.ubuntu.com/ubuntu noble-backports/restricted amd64 c-n-f Metadata [116 B]
Get:59 http://archive.ubuntu.com/ubuntu noble-backports/multiverse amd64 Components [212 B]
Get:60 http://archive.ubuntu.com/ubuntu noble-backports/multiverse amd64 c-n-f Metadata [116 B]
Get:61 http://security.ubuntu.com/ubuntu noble-security/multiverse amd64 Components [212 B]
Get:62 http://security.ubuntu.com/ubuntu noble-security/multiverse amd64 c-n-f Metadata [380 B]
Fetched 36.0 MB in 3s (10.5 MB/s)
Reading package lists... Done
E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/by-hash/SHA256/ba9057fa1b91438cc8a1d26808d00c85389fe101d0c1496254df97236405599a  Hash Sum mismatch
   Hashes of expected file:
    - Filesize:15037908 [weak]
    - SHA256:ba9057fa1b91438cc8a1d26808d00c85389fe101d0c1496254df97236405599a
    - SHA1:f90c48a0fe91f4bff279e60eb7e5583cb898848a [weak]
    - MD5Sum:070718db2f33ee0a489e9abbfb780cbe [weak]
   Hashes of received file:
    - SHA256:fa5b1856dd1e47a902036286d320fedf2dce38fc2bc7b3490c802b4703e7e47d
    - SHA1:37a7669aae950cb135baf9c3a15b3564634b2f8a [weak]
    - MD5Sum:bd82d3ab1c2ca3c658eb0aabaa0ca946 [weak]
    - Filesize:15037908 [weak]
   Last modification reported: Thu, 25 Apr 2024 11:56:24 +0000
   Release file created at: Thu, 25 Apr 2024 15:10:33 +0000
E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/noble-updates/universe/binary-amd64/by-hash/SHA256/13bff52e8634d4ea1f89f00ee0b290a345d2c6f32c7116bd5fc236a271e9cc7e  Hash Sum mismatch
   Hashes of expected file:
    - Filesize:1046312 [weak]
    - SHA256:13bff52e8634d4ea1f89f00ee0b290a345d2c6f32c7116bd5fc236a271e9cc7e
    - SHA1:9762c757406765f90d1bedd1ea32f6e87ce8c9a2 [weak]
    - MD5Sum:c4683a262b93f9575fc2c5781aad5edb [weak]
   Hashes of received file:
    - SHA256:fde58e9769d9c9824e4878b1aa53fc4660b5231a0ac23490ea383f2a1c26ec48
    - SHA1:61e5682470aeb49333e663f3d27152e4483777f3 [weak]
    - MD5Sum:34262e8a99f962519682f11160e6469b [weak]
    - Filesize:1046312 [weak]
   Last modification reported: Wed, 02 Apr 2025 02:42:48 +0000
   Release file created at: Wed, 02 Apr 2025 04:05:03 +0000
E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/noble-updates/restricted/binary-amd64/by-hash/SHA256/69bc2af898ae4b2bf11cc6799fe9345e1ee3d75d30ab38551612bb396a1080df
E: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/noble-updates/multiverse/binary-amd64/by-hash/SHA256/c920e9c2b511da92a7ccfd700bbd9f74cc0327411c6d31134a0019c566d12fa2
E: Some index files failed to download. They have been ignored, or old ones used instead.

Repro Steps

apt-get update

Expected Behavior

The apt-get update command should be successful.

Actual Behavior

Error: Hash Sum mismatch

Diagnostic Logs

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions