PDA

View Full Version : [ubuntu] Change repo mirros via command line



plr4ever
October 6th, 2009, 09:49 PM
I recently installed 9.10-server on a laptop i have lying around, and i noticed that the default repository server was still set to ubuntu.org.
Since i am a student at Georgia Tech, i wanted to switch the mirrors to the gtlib.gatech.edu site. However, without having a gui, the only way i can think to change all of the mirrors is to go through the sources.list file and edit it by hand. Is anyone aware of a script/cli tool that allows you to change ALL of the mirrors at once?

Thanks!

kanikilu
October 6th, 2009, 10:39 PM
I don't know of something already out there, but could you not just use sed to replace the current mirror with something else? Similar to how this page explains how to uncomment lines with sed:

https://help.ubuntu.com/community/Repositories/CommandLine#Enabling%20Repositories%20with%20a%20% 28non-interactive%29%20Script

Here's a similar thread with some other suggestions:

http://ubuntuforums.org/showthread.php?t=226299