So che c'è una GUI in Ubuntu Software & Updatesper abilitare i canali di aggiornamento
- aggiornamenti
- proposto
- backport
- sicurezza
come mostrato in questo screenshot:
Sto cercando un modo semplice per farlo da un terminale usando comandi come
sudo apt-add-update enable updates
sudo apt-add-update enable proposed
sudo apt-add-update enable backports
sudo apt-add-update enable security
sudo apt-add-update disable updates
sudo apt-add-update disable proposed
sudo apt-add-update disable backports
sudo apt-add-update disable security
e un'altra cosa
sudo apt-add-update enable default
sudo apt-add-update disable default
Alcuni esempi per una migliore comprensione
Un vuoto
sources.listcat /etc/apt/sources.list<empty>sudo apt-add-update enable security<empty>
Un repository abilitato (
main)cat /etc/apt/sources.listdeb http://archive.ubuntu.com/ubuntu wily mainsudo apt-add-update enable securitydeb http://archive.ubuntu.com/ubuntu wily main deb http://archive.ubuntu.com/ubuntu wily-security main
Due o più repository abilitati in una o due righe
cat /etc/apt/sources.listdeb http://archive.ubuntu.com/ubuntu wily main universeo
deb http://archive.ubuntu.com/ubuntu wily main deb http://archive.ubuntu.com/ubuntu wily universesudo apt-add-update enable securitydeb http://archive.ubuntu.com/ubuntu wily main universe deb http://archive.ubuntu.com/ubuntu wily-security main universeo
deb http://archive.ubuntu.com/ubuntu wily main deb http://archive.ubuntu.com/ubuntu wily-security main deb http://archive.ubuntu.com/ubuntu wily universe deb http://archive.ubuntu.com/ubuntu wily-security universe
Con
deb-srcvocicat /etc/apt/sources.listdeb http://archive.ubuntu.com/ubuntu wily main universe deb-src http://archive.ubuntu.com/ubuntu wily main universesudo apt-add-update enable securitydeb http://archive.ubuntu.com/ubuntu wily main universe deb-src http://archive.ubuntu.com/ubuntu wily main universe deb http://archive.ubuntu.com/ubuntu wily-security main universe deb-src http://archive.ubuntu.com/ubuntu wily-security main universe
Con
deb-srcvoci inattivecat /etc/apt/sources.listdeb http://archive.ubuntu.com/ubuntu wily main universe # deb-src http://archive.ubuntu.com/ubuntu wily main universesudo apt-add-update enable securitydeb http://archive.ubuntu.com/ubuntu wily main universe # deb-src http://archive.ubuntu.com/ubuntu wily main universe deb http://archive.ubuntu.com/ubuntu wily-security main universe
La
defaultcosacat /etc/apt/sources.listdeb http://archive.ubuntu.com/ubuntu wily-security universesudo apt-add-update enable defaultdeb http://archive.ubuntu.com/ubuntu wily universe deb http://archive.ubuntu.com/ubuntu wily-security universe
Solo una voce e l'
disableazionecat /etc/apt/sources.listdeb http://archive.ubuntu.com/ubuntu wily-security universesudo apt-add-update disable security<empty>
Server diversi o uguali per server diversi o diversi, rispettano ciascun server
cat /etc/apt/sources.listdeb http://archive.ubuntu.com/ubuntu wily universe deb http://us.archive.ubuntu.com/ubuntu wily mainsudo apt-add-update enable securitydeb http://archive.ubuntu.com/ubuntu wily universe deb http://us.archive.ubuntu.com/ubuntu wily main deb http://archive.ubuntu.com/ubuntu wily-security universe deb http://us.archive.ubuntu.com/ubuntu wily-security main
Diverse versioni di Ubuntu per diversi repository, rispettano ciascuna versione
cat /etc/apt/sources.listdeb http://archive.ubuntu.com/ubuntu wily main universe deb http://archive.ubuntu.com/ubuntu trusty mainsudo apt-add-update enable securitydeb http://archive.ubuntu.com/ubuntu wily main universe deb http://archive.ubuntu.com/ubuntu trusty main deb http://archive.ubuntu.com/ubuntu wily-security main universe deb http://archive.ubuntu.com/ubuntu trusty-security main
PPA o altre fonti di pacchetto (non canonico) nel
sources.list?Ignorare!
Non modificare i protocolli, ad esempio
https,http,tor, ...



