最新消息:20210917 已从crifan.com换到crifan.org

【记录】给Ubuntu更换源(sources.list):从原始的us.archive.ubuntu.com换个支持13.04的速度更快的源

Ubuntu crifan 5638浏览 0评论

【问题】

折腾:

【已解决】Ubuntu中安装jre结果出错:openjdk-7-jre-headless : Depends: ca-certificates-java but it is not going to be installed

期间,发现,虽然之前换的163的源:

【记录】给Ubuntu更换成163的源(sources.list)

速度是快了,但是却会导致:

由于目前(2013-08-12),163的源,不支持13.04,最高只支持12.04,导致我在安装openjdk时出错,无法安装。

而最后是换到了原始的,us.archive.ubuntu.com,才解决了此问题的。

所以,现在要去:

换个,支持13.04的,且链接速度,比默认的us.archive.ubuntu.com要快的源。

【折腾过程】

1.通过Select Best Server,自己去找速度快的:

select best server to choose good speed server

 

2.最后选择了自己的母校的,中科大的源:

mirrors.ustc.edu.cn

finnally choose my ustc edu cn

 

3.保存:

use ustc for download from

4.再去update一下:

Ccrifan@ubuntu:openjdk-7-7u25-2.3.10$ sudo apt-get update
Get:1 http://mirrors.ustc.edu.cn raring Release.gpg [933 B]
Hit http://extras.ubuntu.com raring Release.gpg      
Get:2 http://mirrors.ustc.edu.cn raring-updates Release.gpg [933 B]
Get:3 http://mirrors.ustc.edu.cn raring-backports Release.gpg [933 B]
Hit http://extras.ubuntu.com raring Release           
Get:4 http://mirrors.ustc.edu.cn raring-security Release.gpg [933 B]
Get:5 http://mirrors.ustc.edu.cn raring Release [40.8 kB]
Hit http://extras.ubuntu.com raring/main Sources         
Get:6 http://mirrors.ustc.edu.cn raring-updates Release [40.8 kB]
Get:7 http://mirrors.ustc.edu.cn raring-backports Release [40.8 kB]
Get:8 http://mirrors.ustc.edu.cn raring-security Release [40.8 kB]
Get:9 http://mirrors.ustc.edu.cn raring/main Sources [963 kB]
Hit http://extras.ubuntu.com raring/main i386 Packages 
Get:10 http://mirrors.ustc.edu.cn raring/restricted Sources [5,987 B] 
Get:11 http://mirrors.ustc.edu.cn raring/universe Sources [5,838 kB]  
Get:12 http://mirrors.ustc.edu.cn raring/multiverse Sources [171 kB]               
Get:13 http://mirrors.ustc.edu.cn raring/main i386 Packages [1,168 kB]         
Get:14 http://mirrors.ustc.edu.cn raring/restricted i386 Packages [9,623 B]   
Get:15 http://mirrors.ustc.edu.cn raring/universe i386 Packages [5,405 kB]    
Ign http://extras.ubuntu.com raring/main Translation-en_US                          
Ign http://extras.ubuntu.com raring/main Translation-en                             
Get:16 http://mirrors.ustc.edu.cn raring/multiverse i386 Packages [131 kB]                                                                      
Get:17 http://mirrors.ustc.edu.cn raring/main Translation-en [673 kB]                                                                           
Get:18 http://mirrors.ustc.edu.cn raring/multiverse Translation-en [98.4 kB]                                                                    
Get:19 http://mirrors.ustc.edu.cn raring/restricted Translation-en [2,767 B]                                                                    
Get:20 http://mirrors.ustc.edu.cn raring/universe Translation-en [3,736 kB]                                                                     
Get:21 http://mirrors.ustc.edu.cn raring-updates/main Sources [57.8 kB]                                                                         
Get:22 http://mirrors.ustc.edu.cn raring-updates/restricted Sources [14 B]                                                                      
Get:23 http://mirrors.ustc.edu.cn raring-updates/universe Sources [68.6 kB]                                                                     
Get:24 http://mirrors.ustc.edu.cn raring-updates/multiverse Sources [1,825 B]                                                                   
Get:25 http://mirrors.ustc.edu.cn raring-updates/main i386 Packages [149 kB]                                                                    
Get:26 http://mirrors.ustc.edu.cn raring-updates/restricted i386 Packages [14 B]                                                                
Get:27 http://mirrors.ustc.edu.cn raring-updates/universe i386 Packages [134 kB]                                                                
Get:28 http://mirrors.ustc.edu.cn raring-updates/multiverse i386 Packages [3,612 B]                                                             
Get:29 http://mirrors.ustc.edu.cn raring-updates/main Translation-en [71.5 kB]                                                                  
Get:30 http://mirrors.ustc.edu.cn raring-updates/multiverse Translation-en [1,566 B]                                                            
Get:31 http://mirrors.ustc.edu.cn raring-updates/restricted Translation-en [14 B]                                                               
Get:32 http://mirrors.ustc.edu.cn raring-updates/universe Translation-en [70.9 kB]                                                              
Get:33 http://mirrors.ustc.edu.cn raring-backports/main Sources [14 B]                                                                          
Get:34 http://mirrors.ustc.edu.cn raring-backports/restricted Sources [14 B]                                                                    
Get:35 http://mirrors.ustc.edu.cn raring-backports/universe Sources [5,134 B]                                                                   
Get:36 http://mirrors.ustc.edu.cn raring-backports/multiverse Sources [1,403 B]                                                                 
Get:37 http://mirrors.ustc.edu.cn raring-backports/main i386 Packages [14 B]                                                                    
Get:38 http://mirrors.ustc.edu.cn raring-backports/restricted i386 Packages [14 B]                                                              
Get:39 http://mirrors.ustc.edu.cn raring-backports/universe i386 Packages [6,239 B]                                                             
Get:40 http://mirrors.ustc.edu.cn raring-backports/multiverse i386 Packages [1,345 B]                                                           
Get:41 http://mirrors.ustc.edu.cn raring-backports/main Translation-en [14 B]                                                                   
Get:42 http://mirrors.ustc.edu.cn raring-backports/multiverse Translation-en [1,040 B]                                                          
Get:43 http://mirrors.ustc.edu.cn raring-backports/restricted Translation-en [14 B]                                                             
Get:44 http://mirrors.ustc.edu.cn raring-backports/universe Translation-en [4,983 B]                                                            
Get:45 http://mirrors.ustc.edu.cn raring-security/main Sources [36.2 kB]                                                                        
Get:46 http://mirrors.ustc.edu.cn raring-security/restricted Sources [14 B]                                                                     
Get:47 http://mirrors.ustc.edu.cn raring-security/universe Sources [8,839 B]                                                                    
Get:48 http://mirrors.ustc.edu.cn raring-security/multiverse Sources [1,825 B]                                                                  
Get:49 http://mirrors.ustc.edu.cn raring-security/main i386 Packages [94.3 kB]                                                                  
Get:50 http://mirrors.ustc.edu.cn raring-security/restricted i386 Packages [14 B]                                                               
Get:51 http://mirrors.ustc.edu.cn raring-security/universe i386 Packages [32.9 kB]                                                              
Get:52 http://mirrors.ustc.edu.cn raring-security/multiverse i386 Packages [3,612 B]                                                            
Get:53 http://mirrors.ustc.edu.cn raring-security/main Translation-en [49.5 kB]                                                                 
Get:54 http://mirrors.ustc.edu.cn raring-security/multiverse Translation-en [1,566 B]                                                           
Get:55 http://mirrors.ustc.edu.cn raring-security/restricted Translation-en [14 B]                                                              
Get:56 http://mirrors.ustc.edu.cn raring-security/universe Translation-en [20.9 kB]                                                             
Ign http://mirrors.ustc.edu.cn raring/main Translation-en_US                                                                                    
Ign http://mirrors.ustc.edu.cn raring/multiverse Translation-en_US
Ign http://mirrors.ustc.edu.cn raring/restricted Translation-en_US
Ign http://mirrors.ustc.edu.cn raring/universe Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-updates/main Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-updates/multiverse Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-updates/restricted Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-updates/universe Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-backports/main Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-backports/multiverse Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-backports/restricted Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-backports/universe Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-security/main Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-security/multiverse Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-security/restricted Translation-en_US
Ign http://mirrors.ustc.edu.cn raring-security/universe Translation-en_US
Fetched 19.2 MB in 27s (711 kB/s)
Reading package lists... Done
crifan@ubuntu:openjdk-7-7u25-2.3.10$ 

5.然后再去确认一把,是否可以正常安装openjdk:

然后狂爽,速度达到2,3MB/s,哈哈哈:

crifan@ubuntu:openjdk-7-7u25-2.3.10$ sudo apt-get install openjdk-7-jre-headless
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  ca-certificates-java icedtea-7-jre-jamvm java-common openjdk-7-jre-lib tzdata-java
Suggested packages:
  default-jre equivs sun-java6-fonts ttf-dejavu-extra fonts-ipafont-gothic fonts-ipafont-mincho ttf-telugu-fonts ttf-oriya-fonts
  ttf-kannada-fonts ttf-bengali-fonts
The following NEW packages will be installed:
  ca-certificates-java icedtea-7-jre-jamvm java-common openjdk-7-jre-headless openjdk-7-jre-lib tzdata-java
0 upgraded, 6 newly installed, 0 to remove and 11 not upgraded.
Need to get 44.4 MB of archives.
After this operation, 64.0 MB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://mirrors.ustc.edu.cn/ubuntu/ raring-updates/main openjdk-7-jre-lib all 7u25-2.3.10-1ubuntu0.13.04.2 [5,541 kB]
Get:2 http://mirrors.ustc.edu.cn/ubuntu/ raring/main ca-certificates-java all 20121112+nmu2 [13.6 kB]
Get:3 http://mirrors.ustc.edu.cn/ubuntu/ raring/main tzdata-java all 2013b-1ubuntu1 [141 kB]
Get:4 http://mirrors.ustc.edu.cn/ubuntu/ raring/main java-common all 0.43ubuntu4 [134 kB]
Get:5 http://mirrors.ustc.edu.cn/ubuntu/ raring-updates/main openjdk-7-jre-headless i386 7u25-2.3.10-1ubuntu0.13.04.2 [37.9 MB]
Get:6 http://mirrors.ustc.edu.cn/ubuntu/ raring-updates/main icedtea-7-jre-jamvm i386 7u25-2.3.10-1ubuntu0.13.04.2 [596 kB]                     
Fetched 41.0 MB in 17s (2,351 kB/s)        
......

 

【总结】

至此,终于:

将Ubuntu的源,从默认的us的,换成了ustc的;

且正常安装成功了jdk了:

sudo apt-get install openjdk-7-jre-headless

转载请注明:在路上 » 【记录】给Ubuntu更换源(sources.list):从原始的us.archive.ubuntu.com换个支持13.04的速度更快的源

发表我的评论
取消评论

表情

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址
89 queries in 0.195 seconds, using 20.27MB memory