Avere un mirror Debian lento può essere frustrante e quindi è sempre meglio scegliere il mirror più vicino possibile alla tua posizione geografica. Anche la tua migliore ipotesi potrebbe non portare sempre buoni risultati. Fortunatamente netselect-apt
lo strumento della riga di comando è qui per aiutarti a trovare il mirror più veloce disponibile.
Ecco l'idea di base:

Come puoi vedere nell'immagine sopra, 87,0 kB/s è piuttosto deludente. Proviamo a cambiarlo usando
netselect-apt
strumento di localizzazione dello specchio più veloce. L'installazione è semplice: # apt-get install netselect-apt
Successivamente troveremo un mirror più veloce situato in Australia -c
, confronteremo i risultati di 15 siti -t
se disponibile, l'architettura deve essere amd64 -a
e la versione che stiamo cercando è in fase di test:
# netselect-apt -c australia -t 15 -a amd64 -n testing Using distribution testing. Retrieving the list of mirrors from www.debian.org... --2015-01-29 19:33:12-- http://www.debian.org/mirror/mirrors_full Resolving www.debian.org (www.debian.org)... 140.211.15.34, 128.31.0.62 Connecting to www.debian.org (www.debian.org)|140.211.15.34|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 353167 (345K) [text/html] Saving to: ‘/tmp/netselect-apt.vPhJid’ /tmp/netselect-apt.vPhJid 100%[===============>] 344.89K 445KB/s in 0.8s 2015-01-29 19:33:14 (445 KB/s) - ‘/tmp/netselect-apt.vPhJid’ saved [353167/353167] Choosing a main Debian mirror using netselect. (will filter only for mirrors in country australia) netselect: 8 (8 active) nameserver request(s)... Duplicate address 218.100.43.30 (http://mirror.waia.asn.au/debian/, http://ftp.au.debian.org/debian/); keeping only under first name. Running netselect to choose 15 out of 12 addresses. ............................................................................................................................. Only found 12 hosts out of 15 requested. The fastest 15 servers seem to be: http://debian.mirror.uber.com.au/debian/ http://debian.mirror.serversaustralia.com.au/debian/ http://mirror.optus.net/debian/ http://mirror.overthewire.com.au/debian/ http://mirror.crucial.com.au/debian/ http://mirror.eftel.com/debian/ http://mirror.as24220.net/pub/debian/ http://ftp.iinet.net.au/debian/debian/ http://mirror.waia.asn.au/debian/ http://ftp.monash.edu.au/pub/linux/debian/ http://mirror.cse.unsw.edu.au/debian/ http://mirror.linux.org.au/debian/ Of the hosts tested we choose the fastest valid for HTTP: http://debian.mirror.uber.com.au/debian/ Writing sources.list. Done.
Sulla base dell'output del comando precedente possiamo vedere che netselect-apt
trovato solo 12 mirror tra i quali la scelta migliore è http://debian.mirror.uber.com.au/debian/
. netselect-apt
ha anche creato un sources.list
file nella directory di lavoro corrente per la tua considerazione. Se netselect-apt
il comando viene eseguito dal /etc/apt/
effettivo directory produrrà il file dell'elenco delle fonti con un suffisso casuale come sources.list exists, moving to sources.list.1422520852
.
In alternativa puoi eseguire netselect-apt
comando con meno opzioni:
# netselect-apt testing
o semplicemente come:
# netselect-apt
nel qual caso la versione Debian predefinita sarà stable
. Una volta che hai il tuo sources.list
generato puoi includere il mirror risultante nel sources.list
del tuo sistema di:
# cp /etc/apt/sources.list /etc/apt/sources.list_backup # mv sources.list /etc/apt/sources.list
Oppure aggiungi solo la riga risultante al tuo /etc/apt/sources.list
corrente . Vediamo il risultato
