Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pacman response reading failed #163

Closed
jeroen opened this issue Feb 9, 2015 · 13 comments
Closed

Pacman response reading failed #163

jeroen opened this issue Feb 9, 2015 · 13 comments

Comments

@jeroen
Copy link
Contributor

jeroen commented Feb 9, 2015

I'm seeing a lot of these lately:

Jeroen@Jeroen-Windows ~
$ pacman -S mingw-w64-x86_64-postgresql
resolving dependencies...
looking for conflicting packages...

Packages (24) mingw-w64-x86_64-bzip2-1.0.6-2  mingw-w64-x86_64-expat-2.1.0-3  mingw-w64-x86_64-gcc-libs-4.9.2-2
              mingw-w64-x86_64-gdbm-1.10-1  mingw-w64-x86_64-gettext-0.19.3-1  mingw-w64-x86_64-gmp-6.0.0-2
              mingw-w64-x86_64-libffi-3.1-2  mingw-w64-x86_64-libgcrypt-1.6.2-1  mingw-w64-x86_64-libgnurx-2.5.1-2
              mingw-w64-x86_64-libgpg-error-1.16-2  mingw-w64-x86_64-libiconv-1.14-2
              mingw-w64-x86_64-libwinpthread-git-4.0.0.4328.a913346-1  mingw-w64-x86_64-libxml2-2.9.2-1
              mingw-w64-x86_64-libxslt-1.1.28-4  mingw-w64-x86_64-ncurses-5.9-3  mingw-w64-x86_64-openssl-1.0.1j-1
              mingw-w64-x86_64-python2-2.7.8-8  mingw-w64-x86_64-readline-6.2.005-3  mingw-w64-x86_64-tcl-8.6.2-2
              mingw-w64-x86_64-termcap-1.3.1-1  mingw-w64-x86_64-tk-8.6.2-2  mingw-w64-x86_64-xz-5.0.7-1
              mingw-w64-x86_64-zlib-1.2.8-5  mingw-w64-x86_64-postgresql-9.3.5-1

Total Download Size:     8.87 MiB
Total Installed Size:  215.77 MiB

:: Proceed with installation? [Y/n] y
:: Retrieving packages ...
error: failed retrieving file 'mingw-w64-x86_64-python2-2.7.8-8-any.pkg.tar.xz' from 148.251.42.38 : response reading failed
error: failed retrieving file 'mingw-w64-x86_64-python2-2.7.8-8-any.pkg.tar.xz' from downloads.sourceforge.net : Operation too slow. Less than 1 bytes/sec transferred the last 10 seconds
warning: failed to retrieve some files
error: failed to commit transaction (download library error)
Errors occurred, no packages were upgraded.

Is the pacman cache of the repository perhaps outdated? How do I sync the local repository index with the server?

@Alexpux
Copy link
Member

Alexpux commented Feb 9, 2015

This issue is discusses many times. You need firs update pacman mirrors:
pacman -Sy && pacman -S pacman-mirrors.

@Alexpux Alexpux closed this as completed Feb 9, 2015
@jeroen
Copy link
Contributor Author

jeroen commented Feb 9, 2015

Ok you might want to list this in pacman -h then because it is difficult to find this information.

@Alexpux
Copy link
Member

Alexpux commented Feb 9, 2015

This is permanent issue that is solved automatically once you update packages. It might take long time because pacman try mirrors one by one for every package download.
I don't want put it in pacman help because it is unnecessary information for the help.

@jeroen
Copy link
Contributor Author

jeroen commented Feb 9, 2015

After updating I am still getting:

error: failed retrieving file 'mingw-w64-i686-gcc-libs-4.9.2-4-any.pkg.tar.xz' from downloads.sourceforge.net : The requested URL returned error: 404
warning: failed to retrieve some files
error: failed retrieving file 'mingw-w64-i686-gcc-4.9.2-4-any.pkg.tar.xz' from downloads.sourceforge.net : The requested URL returned error: 404
warning: failed to retrieve some files
error: failed retrieving file 'mingw-w64-i686-gcc-ada-4.9.2-4-any.pkg.tar.xz' from downloads.sourceforge.net : The requested URL returned error: 404
warning: failed to retrieve some files
error: failed retrieving file 'mingw-w64-i686-gcc-libgfortran-4.9.2-4-any.pkg.tar.xz' from downloads.sourceforge.net : The requested URL returned error: 404
warning: failed to retrieve some files
error: failed retrieving file 'mingw-w64-i686-gcc-fortran-4.9.2-4-any.pkg.tar.xz' from downloads.sourceforge.net : The requested URL returned error: 404
warning: failed to retrieve some files
error: failed retrieving file 'mingw-w64-i686-gcc-objc-4.9.2-4-any.pkg.tar.xz' from downloads.sourceforge.net : The requested URL returned error: 404
warning: failed to retrieve some files
error: failed to commit transaction (unexpected error)
Errors occurred, no packages were upgraded.

@Alexpux
Copy link
Member

Alexpux commented Feb 9, 2015

Fixed.

@geraldstanje
Copy link

why is this?
$ pacman -Sy && pacman -S pacman-mirrors.
:: Synchronizing package databases...
error: failed retrieving file 'mingw32.db' from downloads.sourceforge.net : The requested URL returned error: 407
error: failed to update mingw32 (unexpected error)
error: failed retrieving file 'mingw64.db' from downloads.sourceforge.net : The requested URL returned error: 407
error: failed to update mingw64 (unexpected error)
error: failed retrieving file 'msys.db' from downloads.sourceforge.net : The requested URL returned error: 407
error: failed to update msys (unexpected error)
error: failed to synchronize any databases
error: failed to init transaction (unexpected error)

how to set the http proxy?

@elieux
Copy link
Member

elieux commented Apr 29, 2015

how to set the http proxy?

If you had searched the Internet before posting here, you could've saved us both a few minutes of time. Does this link help? http://stackoverflow.com/questions/29783065/msys2-pacman-cant-update-packages-through-corporate-firewall

@bbremen
Copy link

bbremen commented Jul 29, 2015

Hello

I have reinstalled msys2 and now I am seeing problems similar to ones described here.

I am behind corporate firewall and the solution described above was working for me (before reinstalation). I have checked that proxy settings used are still working with other program.

27.7.2015 I have tried "pacman -Sy" with following response:
mingw32 and mingw64 update files downloaded without problems, but msys update failed with message:
Operation too slow. Less than 1 bytes/sec transferred the last 10 seconds warning: failed to retrieve some files
error: failed to commit transaction (download library error)

Today I tried again. I have tried "pacman -Sy" and "pacman -s pacman-mirrors" with response
error: failed retrieving file 'mingw32.db' from downloads.sourceforge.net : Connection timed out after 10000 milliseconds
error: failed to update mingw32 (download library error)

Also pacman-mirrors says it is up-to-date and tries to update to version pacman-mirrors-20141223-1

I have found files mirrorlist.mingw32, mirrorlist.mingw64 and mirrorlist.msys at https://github.com/Alexpux/MSYS2-packages/blob/master/pacman-mirrors/ and update the files into my installed msys. It doesn't help, it fails on all three servers.

@Alexpux
Copy link
Member

Alexpux commented Jul 29, 2015

Show me your log from "pacman -Syuv --debug"

@bbremen
Copy link

bbremen commented Jul 29, 2015

$ pacman -Syuv --debug
debug: pacman v4.2.1-257-g3356d-dirty - libalpm v9.0.1
debug: config: attempting to read file /etc/pacman.conf
debug: config: new section 'options'
debug: config: HoldPkg: pacman
debug: config: arch: x86_64
debug: config: SigLevel: Required
debug: config: SigLevel: DatabaseOptional
debug: config: LocalFileSigLevel: Optional
debug: config: new section 'mingw32'
debug: config file /etc/pacman.conf, line 73: including /etc/pacman.d/mirrorlist.mingw32
debug: config: new section 'mingw64'
debug: config file /etc/pacman.conf, line 76: including /etc/pacman.d/mirrorlist.mingw64
debug: config: new section 'msys'
debug: config file /etc/pacman.conf, line 79: including /etc/pacman.d/mirrorlist.msys
debug: config: finished parsing /etc/pacman.conf
debug: setup_libalpm called
debug: option 'logfile' = /var/log/pacman.log
debug: option 'gpgdir' = /etc/pacman.d/gnupg/
debug: option 'cachedir' = /var/cache/pacman/pkg/
debug: registering sync database 'mingw32'
debug: database path for tree mingw32 set to /var/lib/pacman/sync/mingw32.db
debug: GPGME version: 1.5.4
debug: GPGME engine info: file=/usr/bin/gpg, home=/etc/pacman.d/gnupg/
debug: checking signature for /var/lib/pacman/sync/mingw32.db
debug: 1 signatures returned
debug: fingerprint: AD351C50AE085775EB59333B5F92EFC1A47D45A1
debug: summary: valid
debug: summary: green
debug: status: Success
debug: timestamp: 1431363688
debug: exp_timestamp: 0
debug: validity: full; reason: Success
debug: key: AD351C50AE085775EB59333B5F92EFC1A47D45A1, Alexey Pavlov (Alexpux) alexpux@gmail.com, owner_trust unknown, disabled 0
debug: signature is valid
debug: signature is fully trusted
debug: setting usage of 15 for mingw32 repository
debug: adding new server URL to database 'mingw32': http://repo.msys2.org/mingw/i686
debug: adding new server URL to database 'mingw32': http://downloads.sourceforge.net/project/msys2/REPOS/MINGW/i686
debug: adding new server URL to database 'mingw32': https://www2.futureware.at/~nickoe/msys2-mirror/mingw32
debug: registering sync database 'mingw64'
debug: database path for tree mingw64 set to /var/lib/pacman/sync/mingw64.db
debug: checking signature for /var/lib/pacman/sync/mingw64.db
debug: 1 signatures returned
debug: fingerprint: AD351C50AE085775EB59333B5F92EFC1A47D45A1
debug: summary: valid
debug: summary: green
debug: status: Success
debug: timestamp: 1431363455
debug: exp_timestamp: 0
debug: validity: full; reason: Success
debug: key: AD351C50AE085775EB59333B5F92EFC1A47D45A1, Alexey Pavlov (Alexpux) alexpux@gmail.com, owner_trust unknown, disabled 0
debug: signature is valid
debug: signature is fully trusted
debug: setting usage of 15 for mingw64 repository
debug: adding new server URL to database 'mingw64': http://downloads.sourceforge.net/project/msys2/REPOS/MINGW/x86_64
debug: registering sync database 'msys'
debug: database path for tree msys set to /var/lib/pacman/sync/msys.db
debug: checking signature for /var/lib/pacman/sync/msys.db
debug: 1 signatures returned
debug: fingerprint: AD351C50AE085775EB59333B5F92EFC1A47D45A1
debug: summary: valid
debug: summary: green
debug: status: Success
debug: timestamp: 1431416285
debug: exp_timestamp: 0
debug: validity: full; reason: Success
debug: key: AD351C50AE085775EB59333B5F92EFC1A47D45A1, Alexey Pavlov (Alexpux) alexpux@gmail.com, owner_trust unknown, disabled 0
debug: signature is valid
debug: signature is fully trusted
debug: setting usage of 15 for msys repository
debug: adding new server URL to database 'msys': http://downloads.sourceforge.net/project/msys2/REPOS/MSYS2/x86_64
Root : /
Conf File : /etc/pacman.conf
DB Path : /var/lib/pacman/
Cache Dirs: /var/cache/pacman/pkg/
Lock File : /var/lib/pacman/db.lck
Log File : /var/log/pacman.log
GPG Dir : /etc/pacman.d/gnupg/
Targets : None
:: Synchronizing package databases...
debug: url: http://repo.msys2.org/mingw/i686/mingw32.db
debug: maxsize: 26214400
debug: using time condition: 1431363688
debug: opened tempfile for download: /var/lib/pacman/sync/mingw32.db.part (wb)
debug: curl returned error 28 from transfer
error: failed retrieving file 'mingw32.db' from repo.msys2.org : Connection timed out after 10000 milliseconds
debug: url: http://downloads.sourceforge.net/project/msys2/REPOS/MINGW/i686/mingw32.db
debug: maxsize: 26214400
debug: using time condition: 1431363688
debug: opened tempfile for download: /var/lib/pacman/sync/mingw32.db.part (wb)
debug: curl returned error 28 from transfer
error: failed retrieving file 'mingw32.db' from downloads.sourceforge.net : Connection timed out after 10000 milliseconds
debug: url: https://www2.futureware.at/~nickoe/msys2-mirror/mingw32/mingw32.db
debug: maxsize: 26214400
debug: using time condition: 1431363688
debug: opened tempfile for download: /var/lib/pacman/sync/mingw32.db.part (wb)
debug: curl returned error 28 from transfer
error: failed retrieving file 'mingw32.db' from www2.futureware.at : Connection timed out after 10000 milliseconds
debug: failed to sync db: download library error
error: failed to update mingw32 (download library error)
debug: url: http://downloads.sourceforge.net/project/msys2/REPOS/MINGW/x86_64/mingw64.db
debug: maxsize: 26214400
debug: using time condition: 1431363454
debug: opened tempfile for download: /var/lib/pacman/sync/mingw64.db.part (wb)
debug: curl returned error 28 from transfer
error: failed retrieving file 'mingw64.db' from downloads.sourceforge.net : Connection timed out after 10000 milliseconds
debug: failed to sync db: download library error
error: failed to update mingw64 (download library error)
debug: url: http://downloads.sourceforge.net/project/msys2/REPOS/MSYS2/x86_64/msys.db
debug: maxsize: 26214400
debug: using time condition: 1431416285
debug: opened tempfile for download: /var/lib/pacman/sync/msys.db.part (wb)
debug: curl returned error 28 from transfer
error: failed retrieving file 'msys.db' from downloads.sourceforge.net : Connection timed out after 10000 milliseconds
debug: failed to sync db: download library error
error: failed to update msys (download library error)
error: failed to synchronize any databases
error: failed to init transaction (download library error)
debug: unregistering database 'local'
debug: unregistering database 'mingw32'
debug: unregistering database 'mingw64'
debug: unregistering database 'msys'

@Alexpux
Copy link
Member

Alexpux commented Jul 29, 2015

Seems this is something with your internet connection. I have no troubles with repo.msys2.org server.

@bbremen
Copy link

bbremen commented Jul 29, 2015

Thats strange, becuase it worked before (first half of July) and I have no other problems with internet or any aplication using it.

@bbremen
Copy link

bbremen commented Jul 29, 2015

OK, it is working now. The problem was at my side (bad copy-paste of export http_proxy=...) Sorry for the troubles.

Still, there is one problem. On "pacman -Sy" msys update failed with message:
Operation too slow. Less than 1 bytes/sec transferred the last 10 seconds warning: failed to retrieve some files
error: failed to commit transaction (download library error)
And pacman-mirrors says it is up-to-date and tries to update to version pacman-mirrors-20141223-1
Here I have to update mirrorlist.msys manually. Then things works fine.
But if I manually update mirrorlist.mingw32 or update mirrorlists by "pacman -S pacman-mirrors", then next call of "pacman -Sy" will end up with:

:: Synchronizing package databases...
mingw32 191.2 KiB 9.83M/s 00:00 [###########################################################] 100%
mingw32.sig 96.0 B 0.00B/s 00:00 [###########################################################] 100%
error: mingw32: signature from "Alexey Pavlov (Alexpux) alexpux@gmail.com" is invalid
error: failed to update mingw32 (invalid or corrupted database (PGP signature))
mingw64 193.2 KiB 12.6M/s 00:00 [###########################################################] 100%
mingw64.sig 96.0 B 0.00B/s 00:00 [###########################################################] 100%
msys is up to date
error: database 'mingw32' is not valid (invalid or corrupted database (PGP signature))

I google-found some solution for this problem, but wasn't able to execute it without msys updates executed before.

So the solution for me is to handle mirrorlists manually. Maybe this will help someone else.

Anyway, thank you for your time.

bors added a commit to rust-lang/rust that referenced this issue Aug 29, 2015
Encountered an issue with `pacman` while going through the guide for installing the `mingw` toolchain on Windows with `msys2`, after some googling I found the [solution](msys2/MSYS2-packages#163 (comment)).

I thought it would be good to update the README so people don't get frustrated. 😃 

r? @steveklabnik
ebraminio added a commit to harfbuzz/harfbuzz that referenced this issue Sep 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants