The officially official Devuan Forum!

You are not logged in.

#1 2018-08-15 02:13:02

0xf4b10
Member
Registered: 2018-05-12
Posts: 27  

How to solve files hash sum mismatches when updating?

I've added to my sources lists the repositories of metasploit and virtualbox in order to make it easy to install them. It was working normally and the updates were coming but today when I tried to update I got the following output:

Err:4 [url]http://downloads.metasploit.com/data/releases/metasploit-framework/apt[/url] lucid/main i386 Packages                   
  Hash Sum mismatch
  Hashes of expected file:
   - Filesize:429 [weak]
   - SHA256:02899db9c850f78edc1f5abfdfe485ffbf3b7d04a4695d0ef7ff912aedb1a492
   - SHA1:37419453a05e2a2586e63cf078f597514b919a17 [weak]
   - MD5Sum:b2dcab0962b2b53319f4715beedcb911 [weak]
  Hashes of received file:
   - SHA256:3ae2486b947d2db14add85154b39a4fc35e30dda695d4b628edea71365c846a4
   - SHA1:4672a8054e770556316417658f335ba31cb4160a [weak]
   - MD5Sum:27517729f2a9ed7ec35e051c08983491 [weak]
   - Filesize:428 [weak]
  Last modification reported: Sun, 12 Aug 2018 16:13:17 +0000
  Release file created at: Tue, 14 Aug 2018 11:21:02 +0000
Get:5 [url]http://downloads.metasploit.com/data/releases/metasploit-framework/apt[/url] lucid/main amd64 Packages [429 B]          
Err:5 [url]http://downloads.metasploit.com/data/releases/metasploit-framework/apt[/url] lucid/main amd64 Packages    

Err:13 [url]http://download.virtualbox.org/virtualbox/debian[/url] stretch/contrib i386 Packages                                  
  Hash Sum mismatch
  Hashes of expected file:
   - Filesize:1739 [weak]
   - SHA256:e9756829a27c807bf8d25a90a1001adce03a31fb87efc96b13e9854cba66eed8
   - SHA1:83539259fc124b4bbba5f77a1e6e835fe34deebf [weak]
   - MD5Sum:aa86cc0404bedfd33919ca5977f15a24 [weak]
  Hashes of received file:
   - SHA256:f84652d7ac0afe92cb8fa010056f4121551342cdecf7ae104cb9e03057da4167
   - SHA1:1a0de458cdc36a66e8b8bbf68c141a9111775c86 [weak]
   - MD5Sum:37678c5fd937ecd1c2634ba544001112 [weak]
   - Filesize:1727 [weak]
  Last modification reported: Tue, 17 Jul 2018 07:50:04 +0000
  Release file created at: Tue, 14 Aug 2018 16:13:46 +0000
 ......
Fetched 89.8 MB in 41s (2,143 kB/s)                                                                                                                                                                                                                                           
Reading package lists... Done
E: Failed to fetch [url]http://download.virtualbox.org/virtualbox/debian/dists/stretch/contrib/binary-i386/Packages.bz2[/url]  Hash Sum mismatch
   Hashes of expected file:
    - Filesize:1739 [weak]
    - SHA256:e9756829a27c807bf8d25a90a1001adce03a31fb87efc96b13e9854cba66eed8
    - SHA1:83539259fc124b4bbba5f77a1e6e835fe34deebf [weak]
    - MD5Sum:aa86cc0404bedfd33919ca5977f15a24 [weak]
   Hashes of received file:
    - SHA256:f84652d7ac0afe92cb8fa010056f4121551342cdecf7ae104cb9e03057da4167
    - SHA1:1a0de458cdc36a66e8b8bbf68c141a9111775c86 [weak]
    - MD5Sum:37678c5fd937ecd1c2634ba544001112 [weak]
    - Filesize:1727 [weak]
   Last modification reported: Tue, 17 Jul 2018 07:50:04 +0000
   Release file created at: Tue, 14 Aug 2018 16:13:46 +0000
E: Failed to fetch [url]http://downloads.metasploit.com/data/releases/metasploit-framework/apt/dists/lucid/main/binary-i386/Packages.gz[/url]  Hash Sum mismatch
   Hashes of expected file:
    - Filesize:429 [weak]
    - SHA256:02899db9c850f78edc1f5abfdfe485ffbf3b7d04a4695d0ef7ff912aedb1a492
    - SHA1:37419453a05e2a2586e63cf078f597514b919a17 [weak]
    - MD5Sum:b2dcab0962b2b53319f4715beedcb911 [weak]
   Hashes of received file:
    - SHA256:3ae2486b947d2db14add85154b39a4fc35e30dda695d4b628edea71365c846a4
    - SHA1:4672a8054e770556316417658f335ba31cb4160a [weak]
    - MD5Sum:27517729f2a9ed7ec35e051c08983491 [weak]
    - Filesize:428 [weak]
   Last modification reported: Sun, 12 Aug 2018 16:13:17 +0000
   Release file created at: Tue, 14 Aug 2018 11:21:02 +0000
E: Failed to fetch [url]http://downloads.metasploit.com/data/releases/metasploit-framework/apt/dists/lucid/main/binary-amd64/Packages.gz[/url]  
E: Some index files failed to download. They have been ignored, or old ones used instead.

What can be causing this? And also, how to solve?
Thanks in advance

Offline

#2 2018-08-15 13:23:44

GNUser
Member
Registered: 2017-03-16
Posts: 397  

Re: How to solve files hash sum mismatches when updating?

It seems that the repository's Packages, Packages.gz, and Packages.bz2 files recently changed but your system is still looking for the old version of these files because the repository metadata cached on your system is old.

Delete all repository metadata and try again with these commands:

# apt-get clean
# rm -rf /var/lib/apt/lists/*
# apt-get update

Hopefully that'll take care of it.

Last edited by GNUser (2018-08-15 13:26:27)

Offline

#3 2018-08-15 15:09:46

0xf4b10
Member
Registered: 2018-05-12
Posts: 27  

Re: How to solve files hash sum mismatches when updating?

yes, it did
thanks for the help

Offline

#4 2018-09-06 02:29:18

0xf4b10
Member
Registered: 2018-05-12
Posts: 27  

Re: How to solve files hash sum mismatches when updating?

strange thing, this error just happened again but now the proposed solution is not working anymore. Any tips?

Offline

Board footer