Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 10-12-2010, 09:30 PM   #1
LQ Newbie
Registered: Aug 2009
Posts: 5

Rep: Reputation: 0
Cannot download packages with apt

I have a new installation of Ubuntu 9.10 karmic, but apt-get update gives error messages "Failed to fetch....; Could not resolve..." for all the packages in the sources.list file. The computer is talking to the network and the webserver is working. I can ping external websites. Is there a setting that must be changed to make downloads function?
Old 10-12-2010, 09:49 PM   #2
LQ Addict
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,908

Rep: Reputation: 354Reputation: 354Reputation: 354Reputation: 354
Take a look at file /etc/apt/sources.list. It lists the repositories for Ubuntu. It lists both the binary and the source code files. Unless you have a need to compile source code yourself, you don't need the sources. So, comment out the lines that refer to source code repositories and the error messages should go away.

Then run apt-get update again. When the update finishes, run apt-get upgrade to get and install the upgrades for your installed software.

The advice given above assumes that Ubuntu still supports version 9.10.
1 members found this post helpful.
Old 10-13-2010, 02:29 AM   #3
LQ Newbie
Registered: Aug 2009
Posts: 5

Original Poster
Rep: Reputation: 0
Thanks for suggestion. Have commented out the source files, but still get messages like this when I use apt-get update:

W: Failed to fetch Could not resolve ‚€˜‚€™
Old 10-13-2010, 04:36 AM   #4
LQ Newbie
Registered: Jul 2005
Distribution: Debian
Posts: 20

Rep: Reputation: 2
Did the web browser work fine?

or run
to check the output.

May be it need to modify /etc/resolve.conf to configure DNS servers. e.g.,

Last edited by longbow0; 10-13-2010 at 04:38 AM.
1 members found this post helpful.
Old 10-13-2010, 08:23 PM   #5
LQ Newbie
Registered: Aug 2009
Posts: 5

Original Poster
Rep: Reputation: 0
Thanks a million longbow0 you have put me on the right track. There is no /etc/resolve.conf file - but there is a /etc/resolv.conf of zero bytes. When I modify with the nameserver addresses, the system starts downloading packages like crazy. A appreciate your help greatly.



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Download packages with apt but don't install them yb99 Linux - General 5 02-25-2010 11:15 PM
LXer: Apt-Cacher-NG - HTTP download proxy for software packages LXer Syndicated Linux News 0 02-24-2009 11:50 PM
apt-get trying to download wrong packages. Why? *Dark Dragon* Linux - Software 4 04-29-2005 02:01 PM
Making apt-get download unstable packages sduffy89 Debian 4 08-28-2004 01:01 PM
apt-get to download packages... mahamkali Linux - Software 3 12-11-2003 10:25 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:46 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration