SOS: I can connect to internet but cannot update or add new software from universe
Hai. I'm new in using Linux. I've installed Feisty Fawn in my computer and it was great. I can connect to the internet, I can update and add new software. However, after several times add new software from universe, I've got these messages:
W: Failed to fetch http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
W: Failed to fetch http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
W: Failed to fetch http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
I cannot update and add new software anymore even though I can access the Internet. Please help me. Thanks.
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- Ubuntu Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- haznizul
- Solved:
- Last query:
- Last reply:
Revision history for this message
|
#1 |
Hello,
Can you post the information in your ' /etc/apt/
So we can help you get apt working right.
Thank you,
Jeff
Revision history for this message
|
#2 |
My /etc/apt/
http://
http://
http://
http://
http://
Please click the links to see the sources.list info. Thanks for your quick response.
Revision history for this message
|
#3 |
Try this first,
'sudo apt-get update' from a terminal window.
It will retrieve the information for new servers and repositories, and show you that progress in the terminal.
Let me know how that works out.
Revision history for this message
|
#4 |
I've applied the command in terminal and this is the message that I've got:
zul@zul-desktop:~$ sudo apt-get update
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Err http://
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Failed to fetch http://
Reading package lists... Done
W: Some index files failed to download, they have been ignored, or old ones used instead.
Revision history for this message
|
#5 |
Hello,
For some reason apt-get tries to connect to your own computer (localhost on port 4001) instead of the real target. Could you check your proxy settings, maybe they are wrong.
Revision history for this message
|
#6 |
(which you can find under System --> Preferences --> network proxy)
Revision history for this message
|
#7 |
My proxy setting is dynamic, I believe this is the default setting. I don't do any changes to the setting.
Thanks everybody for your support. I've solved my problem, by reinstalling Ubuntu. I've reinstall it not only because this updating problem. But also because I've installed Ubuntu in my second physical hard disk (slave). I've Ms Windows on the master hard disk. Therefore, I need to use both hard disk all the time. I cannot disconnect the second hard disk and connect another hard disk to my computer. If I did i, I'll get Grub error message. So, I've reinstalled Ubuntu in the master disk. Thanks again.
Revision history for this message
|
#8 |
I believe I've found the factor that create this problem. The NVDIA driver. I've a NVDIA FX 5200 graphic card. Last time, I've installed the restricted driver for NVDIA to switch on the Desktop Effect. After that my computer was unable to connect to ubuntu server.
Then I reformat and reinstalled Ubuntu on my computer and try to download and install the NVDIA driver again. As a result, my computer faced the same problem. I've uninstalled the driver, but another problem occurred. After I restart my computer, I can see white screen only, not the nice GUI desktop of Ubuntu. I've resolved the problem by reinstalling Ubuntu again.
Revision history for this message
|
#9 |
Only one of my machines did similar. I tested the above steps and I discovered that it is not a problem with proxies (at least how I understand them) but with the loopback interface (LO) being the only option and I am not sure why. Even less, am not sure how to get back my network card on my media server. In attempting to troubleshoot this thing, I am not able to PING that machine from another one, nor can I ping its own address. What I can do is have the machine PING itself, but only on localhost. Yet, it can see the printserver. The machine is a Dell GX110 with standard video and Creative Labs SB LIVE! card.
Revision history for this message
|
#10 |
this is a common whenever there's a proxy set-up
ensure that any proxy packages like anon-proxy, proxify etc are completely removed not just purged via synaptic package manager or adept
also verify network proxy settings to have no proxies set up
reboot ....things shld be fine
Revision history for this message
|
#11 |
Exactly the same thing happened to me. I installed Ubuntu on a Dell laptop, (Latitude D600) and the install was successful, but I got this message when using the update manager :W: Failed to fetch http://
I checked the network settings( as they recommended) and found that the system was set up for a proxy. Apparently it did this automatically on setup!). After setting "direct connection to internet", I was able to proceed normally. Thanks for the excellent advice, it solved a VERY puzzling problem! ;-) Robert
Revision history for this message
|
#12 |
Hi All,
I am having the same problem:
Could not connect to localhost:4001 (127.0.0.1). - connect (111 Connection refused)
...when trying to update. However, my settings already say "direct connection to the internet"
I too have a Dell D600. It seems that this began after my 1st update a week or so ago.
If anyone can give me some advice, I would appreciate it.
I'm running latest Ubuntu:
2.6.24-19-generic #1 SMP Wed Aug 20 22:56:21 UTC 2008 i686 GNU/Linux
Thanks in advance
Revision history for this message
|
#13 |
@rwb1959
Please don't append a new question on a marked as solved question.
Please make new question from here: https:/
you will get better chance to get right answer on a fresh tagged "open" question.
Solved question are usually not read from answering people.
Thank you
Revision history for this message
|
#14 |
Please Try it
Hi, with the help of many others I've been able to fix this problem for good.
First bring up a terminal (shell prompt) with something like "Konsole" found under "System Tools" in the applications bar. Second, completely purge anon-proxy with the following command:
sudo apt-get purge anon-proxy
<AND ENTER YOUR PASSWORD>
(The above command works on my Ubuntu 7.10 OS)
(OR if you are running a system that does not do the sudo thing type the following:
su
<ENTER YOUR ROOT PASSWORD>
apt-get purge anon-proxy
PART TWO
Then type the following:
export HTTP_PROXY=
export http_proxy=
<and you are done!>
Note: To save yourself trouble like this simply don't install anon-proxy; it just messes things up. Use something like Tor instead if you need an anonymous proxy route to the Internet. It is located at http://
If this still doesn't work then also try what Movius posted on http://
PostPosted: 2007-11-11 13:57 Post subject: Another thing Reply with quote
Another thing you have to do is look with the "ifconfig" if the lo {loopback} is activated,
in affirmative case
gedit /etc/network/
and then
delete or put a # in the lines to make it like this :
# The loopback network interface
# auto lo
# iface lo inet loopback
Good luck
If you do choose to use Movius' suggestion make sure that you ONLY put the # sign in front of text; if you delete it and you want to change it back to what it was you may not remember what used to be printed there. The number sign (#) simply "comments out" the instructions, so that the instructions for the computer are translated to be simply notes to the computer operator rather than actual commands to act on. Following these instructions will fix your problem. It worked for me. But DO NOT do what Movius has said to do UNLESS Part One and Part Two combined are unsuccessful. Part#1+Part#2 should work on most every system. Use Movius' suggestion only if Part#1 and Part#2 do not work for you.
Anyhow, I'm apt-getting away now. Yay! L8r
P.S. Regarding Movius' post: You can replace gedit with whatever text editor you want. The command runs a text editor which opens the file /etc/network/
Revision history for this message
|
#15 |
I had the same issue after doing a distribution upgrade from Jaunty (9.04) to Karmic (9.10). None of the above helped.
Looking through /etc/apt directory I found a file called 01proxy in the apt.conf.d sub-directory that seemed to relate so in terminal I:
sudo gedit /etc/apt/
and commented out the line that referred to localhost (using // not # - as other files in the sub-directory commented in this manner) - only 1 line in the file anyway.
Sure enough, after a restart, problem solved - update manager works like usually :)