Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have a Lucid Server (10.04) set up and I would like to change the mirror from US (or any other country) to the Main Ubuntu Mirror.

For example my two first entries in sources.list are:

deb http://us.archive.ubuntu.com/ubuntu/ lucid main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ lucid main restricted

In a Desktop environment I would select the main mirror like this:

Software Sources

But how do I do that from the terminal as I don't have a graphical environment installed!

share|improve this question
add comment

1 Answer 1

up vote 19 down vote accepted

Open your source.list using your favorite text editor, ie

sudo nano /etc/apt/sources.list

locate http://us.archive.ubuntu.com/ubuntu and replace it with http://archive.ubuntu.com/ubuntu.

share|improve this answer
    
I've figured this would do the trick but when I did as you suggested but it gave me a 404 error for the repository. I've checked again now and it seems to be okay. It seemed to be a problem with my network connection. Thank you very much for the answer. –  Sorin-Mihai Oprea Feb 16 '12 at 11:10
    
is there a secure way like with the GUI. I mean, not replacing it manually and avoiding typos or whatever. –  logoff Jan 10 at 11:24
    
Maybe something like this: askubuntu.com/questions/20414/… @logoff –  Luke Stanley Feb 28 at 0:39
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.