You are not logged in.

#1 2013-03-02 12:01:29

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

[SOLVED] pacman download library error

Hi everyone,

I've been using Arch without many problems for a couple of months now, but last night I suddenly became unable to update my system with pacman. When I type

 sudo pacman -Syu

I get output that looks like this:

error: failed retrieving file 'core.db' from mirror.bytemark.co.uk : Could not resolve host: (nil); Name or service not known
error: failed retrieving file 'core.db' from mirror.us.leaseweb.net : Could not resolve host: (nil); Name or service not known
error: failed retrieving file 'core.db' from mirror.de.leaseweb.net : Could not resolve host: (nil); Name or service not known
error: failed retrieving file 'core.db' from archlinux.polymorf.fr : Could not resolve host: (nil); Name or service not known

And so on for, as far as I can tell, all the mirrors in my mirrorlist and each of core.db, extra.db, community.db, and multilib.db (i.e. all the databases that I regularly access). I won't post the whole output here, unless someone requests it, since it is very, very long. The end looks like this:

error: failed retrieving file 'multilib.db' from mirrors.neusoft.edu.cn : Could not resolve host: (nil); Name or service not known
error: failed retrieving file 'multilib.db' from mirrors.stuhome.net : Could not resolve host: (nil); Name or service not known
error: failed to update multilib (download library error)
error: failed to synchronise any databases
error: failed to init transaction (download library error)

However I can ping the mirror sites just fine:

ping mirror.bytemark.co.uk
PING mirror.bytemark.co.uk (212.110.161.69) 56(84) bytes of data.
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=1 ttl=54 time=30.9 ms
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=2 ttl=54 time=30.6 ms
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=3 ttl=54 time=32.1 ms
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=4 ttl=54 time=30.7 ms

And in general my internet access is fine.

Any ideas, anyone, on what's going wrong?

All the best,
PaulE

Last edited by PaulE (2013-03-08 12:13:17)

Offline

#2 2013-03-02 15:47:59

falconindy
Developer
From: New York, USA
Registered: 2009-10-22
Posts: 4,111
Website

Re: [SOLVED] pacman download library error

Post your mirrorlist and pacman.conf

Offline

#3 2013-03-02 21:54:00

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

My pacman.conf:

# /etc/pacman.conf
#
# See the pacman.conf(5) manpage for option and repository directives

#
# GENERAL OPTIONS
#
[options]
# The following paths are commented out with their default values listed.
# If you wish to use different paths, uncomment and update the paths.
#RootDir     = /
#DBPath      = /var/lib/pacman/
#CacheDir    = /var/cache/pacman/pkg/
#LogFile     = /var/log/pacman.log
#GPGDir      = /etc/pacman.d/gnupg/
HoldPkg     = pacman glibc
# If upgrades are available for these packages they will be asked for first
SyncFirst   = pacman
#XferCommand = /usr/bin/curl -C - -f %u > %o
#XferCommand = /usr/bin/wget --passive-ftp -c -O %o %u
#CleanMethod = KeepInstalled
Architecture = auto

# Pacman won't upgrade packages listed in IgnorePkg and members of IgnoreGroup
#IgnorePkg   =
#IgnoreGroup =

#NoUpgrade   =
#NoExtract   =

# Misc options
#UseSyslog
#UseDelta
#TotalDownload
CheckSpace
#VerbosePkgLists

# By default, pacman accepts packages signed by keys that its local keyring
# trusts (see pacman-key and its man page), as well as unsigned packages.
#SigLevel = Optional TrustedOnly

# NOTE: You must run `pacman-key --init` before first using pacman; the local
# keyring can then be populated with the keys of all official Arch Linux
# packagers with `pacman-key --populate archlinux`.

#
# REPOSITORIES
#   - can be defined here or included from another file
#   - pacman will search repositories in the order defined here
#   - local/custom mirrors can be added here or in separate files
#   - repositories listed first will take precedence when packages
#     have identical names, regardless of version number
#   - URLs will have $repo replaced by the name of the current repo
#   - URLs will have $arch replaced by the name of the architecture
#
# Repository entries are of the format:
#       [repo-name]
#       Server = ServerName
#       Include = IncludePath
#
# The header [repo-name] is crucial - it must be present and
# uncommented to enable the repo.
#

# The testing repositories are disabled by default. To enable, uncomment the
# repo name header and Include lines. You can add preferred servers immediately
# after the header, and they will be used before the default mirrors.

#[testing]
#SigLevel = PackageRequired
#Include = /etc/pacman.d/mirrorlist

[core]
SigLevel = PackageRequired
Include = /etc/pacman.d/mirrorlist

[extra]
SigLevel = PackageRequired
Include = /etc/pacman.d/mirrorlist

#[community-testing]
#SigLevel = PackageRequired
#Include = /etc/pacman.d/mirrorlist

[community]
SigLevel = PackageRequired
Include = /etc/pacman.d/mirrorlist

# If you want to run 32 bit applications on your x86_64 system,
# enable the multilib repositories as required here.

#[multilib-testing]
#SigLevel = PackageRequired
#Include = /etc/pacman.d/mirrorlist

[multilib]
SigLevel = PackageRequired
Include = /etc/pacman.d/mirrorlist

# An example of a custom package repository.  See the pacman manpage for
# tips on creating your own repositories.
#[custom]
#SigLevel = Optional TrustAll
#Server = file:///home/custompkgs

Offline

#4 2013-03-02 21:56:27

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

And my pacman.d/mirrorlist:

##
## Arch Linux repository mirrorlist
## Sorted by mirror score from mirror status page
## Generated on 2012-12-01
##

Server = http://mirror.bytemark.co.uk/archlinux/$repo/os/$arch

## Score: 0.2, United States
Server = http://mirror.us.leaseweb.net/archlinux/$repo/os/$arch
## Score: 0.4, Germany
Server = http://mirror.de.leaseweb.net/archlinux/$repo/os/$arch
## Score: 0.4, France
Server = http://archlinux.polymorf.fr/$repo/os/$arch
## Score: 0.4, Netherlands
Server = http://mirror.nl.leaseweb.net/archlinux/$repo/os/$arch
## Score: 0.5, Germany
Server = http://archlinux.limun.org/$repo/os/$arch
## Score: 0.5, United States
Server = http://mirrors.cicku.me/archlinux/$repo/os/$arch
## Score: 0.6, United States
Server = http://hive.ist.unomaha.edu/archlinux/$repo/os/$arch
## Score: 0.7, United States
Server = http://lug.mtu.edu/archlinux/$repo/os/$arch
## Score: 0.7, Poland
Server = http://mirror.chmuri.net/archmirror/$repo/os/$arch
## Score: 0.7, Germany
Server = http://ftp.tuxdroid.org/archlinux/$repo/os/$arch
## Score: 0.9, United States
Server = http://mirrors.kernel.org/archlinux/$repo/os/$arch
## Score: 0.9, United States
Server = http://mirrors.liquidweb.com/archlinux/$repo/os/$arch
## Score: 0.9, United Kingdom
Server = http://mirror.bytemark.co.uk/archlinux/$repo/os/$arch
## Score: 0.9, Italy
Server = http://archlinux.openlabto.org/archlinux/$repo/os/$arch
## Score: 0.9, Netherlands
Server = http://arch.apt-get.eu/$repo/os/$arch
## Score: 0.9, United Kingdom
Server = http://archlinux.mirrors.uk2.net/$repo/os/$arch
## Score: 1.0, France
Server = http://miroir.ezvan.fr/archlinux/$repo/os/$arch
## Score: 1.0, United States
Server = http://archlinux.surlyjake.com/archlinux/$repo/os/$arch
## Score: 1.0, Germany
Server = http://mirror.selfnet.de/archlinux/$repo/os/$arch
## Score: 1.1, Germany
Server = http://ftp5.gwdg.de/pub/linux/archlinux/$repo/os/$arch
## Score: 1.1, Belarus
Server = http://mirror.datacenter.by/pub/archlinux/$repo/os/$arch
## Score: 1.1, Germany
Server = http://mirror.1favre.de/$repo/os/$arch
## Score: 1.1, Germany
Server = http://mirrors.n-ix.net/archlinux/$repo/os/$arch
## Score: 1.1, Netherlands
Server = http://fruk.org/archlinux/$repo/os/$arch
## Score: 1.2, Russian Federation
Server = http://mirror.yandex.ru/archlinux/$repo/os/$arch
## Score: 1.2, Denmark
Server = http://mirrors.dotsrc.org/archlinux/$repo/os/$arch
## Score: 1.2, United States
Server = http://mirror.mocker.org/archlinux/$repo/os/$arch
## Score: 1.2, United States
Server = http://mirror.ece.vt.edu/archlinux/$repo/os/$arch
## Score: 1.2, Norway
Server = http://mirror.archlinux.no/$repo/os/$arch
## Score: 1.2, Taiwan, Province of China
Server = http://ftp.tku.edu.tw/Linux/ArchLinux/$repo/os/$arch
## Score: 1.3, France
Server = http://distrib-coffee.ipsl.jussieu.fr/pub/linux/archlinux/$repo/os/$arch
## Score: 1.3, France
Server = http://mir.archlinux.fr/$repo/os/$arch
## Score: 1.3, Belarus
Server = http://ftp.byfly.by/pub/archlinux/$repo/os/$arch
## Score: 1.3, Germany
Server = http://mirror.michael-eckert.net/archlinux/$repo/os/$arch
## Score: 1.3, Switzerland
Server = http://archlinux.puzzle.ch/$repo/os/$arch
## Score: 1.3, Belgium
Server = http://archlinux.mirror.kangaroot.net/$repo/os/$arch
## Score: 1.3, United States
Server = http://mirror.rit.edu/archlinux/$repo/os/$arch
## Score: 1.3, United States
Server = http://www.gtlib.gatech.edu/pub/archlinux/$repo/os/$arch
## Score: 1.3, United States
Server = http://mirror.nexcess.net/archlinux/$repo/os/$arch
## Score: 1.3, Brazil
Server = http://archlinux.c3sl.ufpr.br/$repo/os/$arch
## Score: 1.4, Germany
Server = http://mirror.devnu11.net/archlinux/$repo/os/$arch
## Score: 1.4, Sweden
Server = http://ftp.lysator.liu.se/pub/archlinux/$repo/os/$arch
## Score: 1.4, United States
Server = http://cake.lib.fit.edu/archlinux/$repo/os/$arch
## Score: 1.4, Brazil
Server = http://www.las.ic.unicamp.br/pub/archlinux/$repo/os/$arch
## Score: 1.4, United States
Server = http://mirrors.cat.pdx.edu/archlinux/$repo/os/$arch
## Score: 1.4, Czech Republic
Server = http://mirror.vpsfree.cz/archlinux/$repo/os/$arch
## Score: 1.5, Chile
Server = http://mirror.archlinux.cl/$repo/os/$arch
## Score: 1.5, United States
Server = http://mirror.cc.columbia.edu/pub/linux/archlinux/$repo/os/$arch
## Score: 1.5, Germany
Server = http://ftp.neutrinopower.de/archlinux/$repo/os/$arch
## Score: 1.6, Norway
Server = http://arch.ping.uio.no/$repo/os/$arch
## Score: 1.6, Germany
Server = http://ftp.spline.inf.fu-berlin.de/mirrors/archlinux/$repo/os/$arch
## Score: 1.7, Macedonia, The Former Yugoslav Republic of
Server = http://arch.linux.net.mk/archlinux/$repo/os/$arch
## Score: 1.7, Canada
Server = http://archlinux.mirror.rafal.ca/$repo/os/$arch
## Score: 1.7, Brazil
Server = http://www.bitwave.com.br/downloads/archlinux/$repo/os/$arch
## Score: 1.7, Germany
Server = http://mirror.fluxent.de/archlinux/$repo/os/$arch
## Score: 1.7, Brazil
Server = http://pet.inf.ufsc.br/mirrors/archlinux/$repo/os/$arch
## Score: 1.8, Sweden
Server = http://ftp.portlane.com/pub/os/linux/archlinux/$repo/os/$arch
## Score: 1.8, Hungary
Server = http://ftp.mfa.kfki.hu/pub/mirrors/ftp.archlinux.org/$repo/os/$arch
## Score: 1.9, Latvia
Server = http://archlinux.goodsoft.lv/$repo/os/$arch
## Score: 1.9, United States
Server = http://mirror.umd.edu/archlinux/$repo/os/$arch
## Score: 1.9, South Africa
Server = http://ftp.wa.co.za/pub/archlinux/$repo/os/$arch
## Score: 2.0, Luxembourg
Server = http://archlinux.mirror.root.lu/$repo/os/$arch
## Score: 2.0, Finland
Server = http://mirror.archlinux.fi/archlinux/$repo/os/$arch
## Score: 2.0, United States
Server = http://mirror.jmu.edu/pub/archlinux/$repo/os/$arch
## Score: 2.1, United Kingdom
Server = http://mirror.cinosure.com/archlinux/$repo/os/$arch
## Score: 2.1, France
Server = http://mir1.archlinux.fr/archlinux/$repo/os/$arch
## Score: 2.1, Israel
Server = http://mirror.isoc.org.il/pub/archlinux/$repo/os/$arch
## Score: 2.1, Australia
Server = http://ftp.swin.edu.au/archlinux/$repo/os/$arch
## Score: 2.3, Germany
Server = http://ftp.hosteurope.de/mirror/ftp.archlinux.org/$repo/os/$arch
## Score: 2.3, Canada
Server = http://mirror.csclub.uwaterloo.ca/archlinux/$repo/os/$arch
## Score: 2.4, United Kingdom
Server = http://mirror.lividpenguin.com/pub/archlinux/$repo/os/$arch
## Score: 2.4, Germany
Server = http://ftp.halifax.rwth-aachen.de/archlinux/$repo/os/$arch
## Score: 2.4, Colombia
Server = http://www.laqee.unal.edu.co/archlinux/$repo/os/$arch
## Score: 2.5, Australia
Server = http://mirror.aarnet.edu.au/pub/archlinux/$repo/os/$arch
## Score: 2.6, Japan
Server = http://ftp.tsukuba.wide.ad.jp/Linux/archlinux/$repo/os/$arch
## Score: 2.7, Finland
Server = http://mirror.academica.fi/archlinux/$repo/os/$arch
## Score: 2.7, Serbia
Server = http://mirror.pmf.kg.ac.rs/archlinux/$repo/os/$arch
## Score: 2.8, Greece
Server = http://ftp.otenet.gr/linux/archlinux/$repo/os/$arch
## Score: 2.8, Japan
Server = http://ftp.jaist.ac.jp/pub/Linux/ArchLinux/$repo/os/$arch
## Score: 2.9, Netherlands
Server = http://mirror.i3d.net/pub/archlinux/$repo/os/$arch
## Score: 2.9, Norway
Server = http://archlinux.uib.no/$repo/os/$arch
## Score: 2.9, Estonia
Server = http://ftp.eenet.ee/pub/archlinux/$repo/os/$arch
## Score: 3.0, United States
Server = http://mirrors.gigenet.com/archlinux/$repo/os/$arch
## Score: 3.0, United States
Server = http://mirrors.rutgers.edu/archlinux/$repo/os/$arch
## Score: 3.0, United States
Server = http://mirror.ancl.hawaii.edu/linux/archlinux/$repo/os/$arch
## Score: 3.0, Greece
Server = http://ftp.ntua.gr/pub/linux/archlinux/$repo/os/$arch
## Score: 3.1, United States
Server = http://mirror.yellowfiber.net/archlinux/$repo/os/$arch
## Score: 3.1, Portugal
Server = http://ftp.rnl.ist.utl.pt/pub/archlinux/$repo/os/$arch
## Score: 3.2, Czech Republic
Server = http://archlinux.mirror.dkm.cz/pub/archlinux/$repo/os/$arch
## Score: 3.2, United States
Server = http://cosmos.cites.illinois.edu/pub/archlinux/$repo/os/$arch
## Score: 3.5, Greece
Server = http://ftp.cc.uoc.gr/mirrors/linux/archlinux/$repo/os/$arch
## Score: 3.5, New Caledonia
Server = http://archlinux.nautile.nc/archlinux/$repo/os/$arch
## Score: 3.6, Russian Federation
Server = http://mirror.rol.ru/archlinux/$repo/os/$arch
## Score: 3.6, Italy
Server = http://mirrors.prometeus.net/archlinux/$repo/os/$arch
## Score: 3.8, United States
Server = http://mirrors.lax1.thegcloud.com/arch/$repo/os/$arch
## Score: 3.8, Germany
Server = http://ftp-stud.hs-esslingen.de/pub/Mirrors/archlinux/$repo/os/$arch
## Score: 3.9, Korea, Republic of
Server = http://mirror.yongbok.net/archlinux/$repo/os/$arch
## Score: 3.9, France
Server = http://mirror.archlinux.ikoula.com/archlinux/$repo/os/$arch
## Score: 4.0, Ireland
Server = http://ftp.heanet.ie/mirrors/ftp.archlinux.org/$repo/os/$arch
## Score: 4.0, Singapore
Server = http://mirror.nus.edu.sg/archlinux/$repo/os/$arch
## Score: 4.1, Sweden
Server = http://ftp.df.lth.se/pub/archlinux/$repo/os/$arch
## Score: 4.1, United Kingdom
Server = http://www.mirrorservice.org/sites/ftp.archlinux.org/$repo/os/$arch
## Score: 4.4, China
Server = http://mirror6.bjtu.edu.cn/archlinux/$repo/os/$arch
## Score: 4.5, Turkey
Server = http://ftp.linux.org.tr/archlinux/$repo/os/$arch
## Score: 4.6, New Zealand
Server = http://mirror.xnet.co.nz/pub/archlinux/$repo/os/$arch
## Score: 4.7, Romania
Server = http://mirror.archlinux.ro/archlinux/$repo/os/$arch
## Score: 4.8, China
Server = http://mirror.bjtu.edu.cn/archlinux/$repo/os/$arch
## Score: 4.8, Bulgaria
Server = http://archlinux.igor.onlinedirect.bg/$repo/os/$arch
## Score: 4.9, Kazakhstan
Server = http://archlinux.kz/$repo/os/$arch
## Score: 5.0, France
Server = http://archlinux.mirrors.ovh.net/archlinux/$repo/os/$arch
## Score: 5.4, China
Server = http://mirrors.163.com/archlinux/$repo/os/$arch
## Score: 5.4, Australia
Server = http://mirror.optus.net/archlinux/$repo/os/$arch
## Score: 5.5, Viet Nam
Server = http://mirror-fpt-telecom.fpt.net/archlinux/$repo/os/$arch
## Score: 5.9, China
Server = http://mirrors.tuna.tsinghua.edu.cn/archlinux/$repo/os/$arch
## Score: 5.9, Sri Lanka
Server = http://mirror.learn.ac.lk/archlinux/$repo/os/$arch
## Score: 6.0, United States
Server = http://ftp.osuosl.org/pub/archlinux/$repo/os/$arch
## Score: 6.7, Taiwan, Province of China
Server = http://shadow.ind.ntou.edu.tw/archlinux/$repo/os/$arch
## Score: 6.9, Canada
Server = http://mirror.its.dal.ca/archlinux/$repo/os/$arch
## Score: 6.9, India
Server = http://mirror.cse.iitk.ac.in/archlinux/$repo/os/$arch
## Score: 7.2, United States
Server = http://mirrors.xmission.com/archlinux/$repo/os/$arch
## Score: 7.7, Spain
Server = http://sunsite.rediris.es/mirror/archlinux/$repo/os/$arch
## Score: 8.0, Kazakhstan
Server = http://mirror.neolabs.kz/archlinux/$repo/os/$arch
## Score: 8.5, Taiwan, Province of China
Server = http://archlinux.cs.nctu.edu.tw/$repo/os/$arch
## Score: 9.2, Ukraine
Server = http://ftp.linux.kiev.ua/pub/Linux/ArchLinux/$repo/os/$arch
## Score: 11.2, Australia
Server = http://mirror.internode.on.net/pub/archlinux/$repo/os/$arch
## Score: 11.7, Australia
Server = http://ftp.iinet.net.au/pub/archlinux/$repo/os/$arch
## Score: 12.5, Ukraine
Server = http://mirrors.mithril.org.ua/linux/archlinux/$repo/os/$arch
## Score: 12.5, United States
Server = http://archlinux.tserver.net/$repo/os/$arch
## Score: 12.7, Netherlands
Server = http://ftp.nluug.nl/pub/os/Linux/distr/archlinux/$repo/os/$arch
## Score: 12.8, Germany
Server = http://artfiles.org/archlinux.org/$repo/os/$arch
## Score: 13.1, Sweden
Server = http://ftp.ds.hj.se/pub/os/linux/archlinux/$repo/os/$arch
## Score: 13.2, Germany
Server = http://ftp.tu-chemnitz.de/pub/linux/archlinux/$repo/os/$arch
## Score: 13.3, Germany
Server = http://ftp.uni-kl.de/pub/linux/archlinux/$repo/os/$arch
## Score: 13.6, Slovakia
Server = http://mirror.lnx.sk/pub/linux/archlinux/$repo/os/$arch
## Score: 14.1, Korea, Republic of
Server = http://ftp.kaist.ac.kr/ArchLinux/$repo/os/$arch
## Score: 14.5, Uzbekistan
Server = http://mirrors.st.uz/archlinux/$repo/os/$arch
## Score: 14.7, Germany
Server = http://ftp.uni-bayreuth.de/linux/archlinux/$repo/os/$arch
## Score: 19.9, China
Server = http://mirrors6.ustc.edu.cn/archlinux/$repo/os/$arch
## Score: 20.5, China
Server = http://mirrors.ustc.edu.cn/archlinux/$repo/os/$arch
## Score: 23.7, China
Server = http://mirrors.neusoft.edu.cn/archlinux/$repo/os/$arch
## Score: 29.6, China
Server = http://mirrors.stuhome.net/archlinux/$repo/os/$arch

Offline

#5 2013-03-03 00:32:49

the sad clown
Member
From: 192.168.0.X
Registered: 2011-03-20
Posts: 837

Re: [SOLVED] pacman download library error

Have you thought about using reflector to generate a more up to date (and local) list of mirrors?


I laugh, yet the joke is on me

Offline

#6 2013-03-03 12:02:38

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Thanks for the suggestion. I hadn't tried it before but just did now. No luck, I'm afraid:

[root@arch pacman.d]# reflector --verbose -l 200 -p http --sort rate --save /etc/pacman.d/mirrorlist
error: failed to retrieve mirror data: <urlopen error [Errno -2] Name or service not known>

By the way, I couldn't use "pacman -S" to install reflector--same trouble as before--but I was able to download the .tar.xz file directly from the Arch website and install it with "pacman -U". So pacman isn't wholly kaput. It just seems to be a matter of accessing the mirrors.

Offline

#7 2013-03-03 12:37:13

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Here's a thought. I've been googling this, of course, but with no success. But I just hit upon the following thread where a user of Arch Linux ARM seems to be having a similar problem:

http://archlinuxarm.org/forum/viewtopic.php?f=29&t=2621

The resolution reported there is the following:

well I guess I answered my own question. DNS entries were missing. switched back to DHCP and all is well. (could have just edited resolv.conf

I'm afraid I don't understand this, though. Can anyone interpret it for me? Would it help in my case? In case it helps, the information on my i3 status bar includes "DHCP: no".

Offline

#8 2013-03-03 12:54:54

Spider.007
Member
Registered: 2004-06-20
Posts: 1,176

Re: [SOLVED] pacman download library error

Pacman isn't able to connect to the mirrors, but your browser is? Did you configure a proxy or VPN or something like that? Do wget or curl work from the commandline? Also, why not configure a local mirror like ftp://ftp.heanet.ie/mirrors/ftp.archlinux.org/

Offline

#9 2013-03-03 16:04:48

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Thanks, Spider.007. I tried to add the Irish mirror site that you mentioned, but it didn't improve things. Following the instructions on the 'MIrrors' wiki site as well as I could, I added the address to the top of my mirrorlist, saved the file and ran

pacman -Syy

as root. Result:

warning: config file /etc/pacman.d/mirrorlist, line 8: directive 'ftp://ftp.heanet.ie/mirrors/ftp.archlinux.org/' in section 'core' not recognized.
warning: config file /etc/pacman.d/mirrorlist, line 11: directive 'http://mirror.bytemark.co.uk/archlinux/$repo/os/$arch' in section 'core' not recognized.
warning: config file /etc/pacman.d/mirrorlist, line 15: directive 'http://mirror.us.leaseweb.net/archlinux/$repo/os/$arch' in section 'core' not recognized.

and so on for all the rest of the sites in my mirrorlist.

I'll try out curl and wget in a moment and report back.

Offline

#10 2013-03-03 16:54:25

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

To respond to the rest of Spider.007's questions...

I have not (knowingly) set up a proxy or VPN.

wget and curl do not seem to work at all. As an experiment I tried to download dmenu from mirror.bytemark.co.uk. This is what I got for wget:

wget http://mirror.bytemark.co.uk/archlinux/community/os/x86_64/dmenu-4.5-3-x86_64.pkg.tar.xz
--2013-03-03 16:33:07--  http://mirror.bytemark.co.uk/archlinux/community/os/x86_64/dmenu-4.5-3-x86_64.pkg.tar.xz
Resolving mirror.bytemark.co.uk (mirror.bytemark.co.uk)... failed: Name or service not known.
wget: unable to resolve host address ‘mirror.bytemark.co.uk’

And here is curl:

curl http://mirror.bytemark.co.uk/archlinux/community/os/x86_64/dmenu-4.5-3-x86_64.pkg.tar.xz
curl: (6) Could not resolve host: (nil); Name or service not known

And it's not just these mirror sites. I tried to download another, non-Arch-related, document with wget and got a similar message to the one above.

And yet the weird thing is that I can ping mirror.bytemark.co.uk...

ping mirror.bytemark.co.uk
PING mirror.bytemark.co.uk (212.110.161.69) 56(84) bytes of data.
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=1 ttl=54 time=30.5 ms
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=2 ttl=54 time=30.7 ms
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=3 ttl=54 time=30.6 ms
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=4 ttl=54 time=31.1 ms
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=5 ttl=54 time=31.4 ms
64 bytes from mirror.bytemark.co.uk (212.110.161.69): icmp_seq=6 ttl=54 time=30.7 ms

... and I can download the file I was trying to get by simply navigating there with my browser, clicking on it, and pressing save:

user@arch Desktop]$ ls
dmenu-4.5-3-x86_64.pkg.tar.xz

So, to summarize, I can ping websites and navigate to them and download files from them with my browser but cannot use pacman, wget or curl to download files from them.

Offline

#11 2013-03-03 17:10:46

falconindy
Developer
From: New York, USA
Registered: 2009-10-22
Posts: 4,111
Website

Re: [SOLVED] pacman download library error

...which begs the question: what is in /etc/resolv.conf

Offline

#12 2013-03-03 20:13:33

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

/etc/resolv.conf:

# Generated by dhcpcd from wlan0
# /etc/resolv.conf.head can replace this line
nameserver 192.168.1.254
# /etc/resolv.conf.tail can replace this line

Offline

#13 2013-03-04 16:03:02

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Update. I found the following thread

https://bbs.archlinux.org/viewtopic.php?id=116607

which seems to describe a problem very similar to the one I have. There the solution was caused by a new version of gnutls. However, I've just downgraded to the previous version of gnutls, and nothing has changed. Depression again.

Edit: i.e. I used to have gnutls 3.1.9-1 and I downgraded it to 3.1.8-1.

Last edited by PaulE (2013-03-04 19:46:32)

Offline

#14 2013-03-04 17:50:17

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: [SOLVED] pacman download library error

What are the actual dns servers you are using? Try something like opendns or google dns.

Offline

#15 2013-03-04 19:43:28

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

They seem to belong to Eircom, the Irish communications company that provides my internet access:

Primary DNS Server
	159.134.0.1
dns1.eircom.net

Secondary DNS Server
	159.134.0.2
dns2.eircom.net

I got that information by typing the IP address in my resolv.conf into a web browser and looking at what came up. That's right, isn't it?

Offline

#16 2013-03-04 23:01:36

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Another update. I've just discovered that wget and curl work perfectly when I feed them raw IP addresses:

wget 192.168.1.254
--2013-03-04 22:52:31--  http://192.168.1.254/
Connecting to 192.168.1.254:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: ‘index.html’

    [ <=>                                                                                             ] 640         --.-K/s   in 0.005s  

2013-03-04 22:52:31 (114 KB/s) - ‘index.html’ saved [640]

I've just googled around for this problem, and it seems that it is often caused by 'dns' not figuring in the 'hosts' line in /etc/nsswitch.conf. But 'dns' does figure in mine. My nsswitch.conf:

# Begin /etc/nsswitch.conf

passwd: files
group: files
shadow: files

publickey: files

hosts: files dns
networks: files

protocols: files
services: files
ethers: files
rpc: files

netgroup: files

# End /etc/nsswitch.conf

I guess I'm getting somewhere, but I'm not sure where. Any further advice gratefully accepted. Thanks to those who have posted so far.

Offline

#17 2013-03-05 09:10:50

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: [SOLVED] pacman download library error

@ PaulE,

Try adding myhostname to hosts field of /etc/nsswitch.conf, like

hosts: files dns myhostname

Offline

#18 2013-03-05 12:38:45

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Thanks, x33a, but I don't think that can be at the bottom of things. My hosts line in nsswitch.conf actually did contain 'myhostname', just as you have it, when the problem developed. I took it out because I saw some example hosts lines on various forums and wiki sites that did not include it, so I took it out in the hope that that might improve things. I should have mentioned that. Sorry.

Offline

#19 2013-03-05 12:47:03

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Success! Of a sort. My previous posts were made at home in Dublin. I am now in my office in London, with the same laptop, and pacman, wget, and curl all work here. (Don't ask why I live in Dublin and work in London. It's a long, sad, story.)

I'm not sure I can pinpoint the exact change that is relevant, but one obvious thing is that my /etc/resolv.conf has changed:

# Generated by dhcpcd from eth0
# /etc/resolv.conf.head can replace this line
domain arts.qmul.ac.uk
nameserver 138.37.6.1
nameserver 138.37.66.253
# /etc/resolv.conf.tail can replace this line

Perhaps this was the issue. But I still don't know why wget and curl suddenly packed up and died on me in Dublin. After all, they'd been working there perfectly well for two months. Nor do I know that they will work in a couple of days when I get back to Dublin, in fact. So any comments are still very welcome.

Offline

#20 2013-03-05 16:21:25

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: [SOLVED] pacman download library error

So maybe do try changing the dns servers to opendns in dublin and see if it fixes things.

Offline

#21 2013-03-05 17:41:53

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Thanks a lot. I'll certainly try that if wget et al. still don't work in Dublin when I get back there. Fingers crossed.

Offline

#22 2013-03-08 12:15:56

PaulE
Member
From: Dublin
Registered: 2012-12-20
Posts: 27

Re: [SOLVED] pacman download library error

Back home in Dublin now. Pacman et al. still did not work here, so I tried switching to OpenDNS, as x33a suggested. Success! Pacman and wget and curl work perfectly now.

Thanks very much to x33a and everyone else who posted. I'll mark this as SOLVED.

Offline

Board footer

Powered by FluxBB