LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1823|回复: 7

如何编写apt source.lst文件?

[复制链接]
发表于 2007-8-6 21:56:53 | 显示全部楼层 |阅读模式
大家好。
我是从red hat过来的,刚刚安装了Debian4.0,可是不会写apt的source.lst文件,到网上找了很久,可是没有解释该文件的具体写法和具体含义,谁能给我一个教育网内的source.lst的写法和这个文件的具体含义呢?最好是能用的,先谢过大家了。
发表于 2007-8-6 23:04:36 | 显示全部楼层
Post by dan_chaos
大家好。
我是从red hat过来的,刚刚安装了Debian4.0,可是不会写apt的source.lst文件,到网上找了很久,可是没有解释该文件的具体写法和具体含义,谁能给我一个教育网内的source.lst的写法和这个文件的具体含义呢?最好是能用的,先谢过大家了。


注意,我的例子里 unstable 是Debian的版本,你需要根据自己使用的版本名称进行替换。

编辑文件如下:
vi /etc/apt/sources.list
  1. #*** this is my debian cdrom install source
  2. #deb cdrom:[Debian GNU/Linux 3.0 r1 _Woody_ - Official i386 Binary-2 (20021218)]/ untesting contrib main non-US/contrib non-US/main
  3. #deb cdrom:[Debian GNU/Linux 3.0 r1 _Woody_ - Official i386 Binary-1 (20021218)]/ untesting contrib main non-US/contrib non-US/main
  4. #*** this is my debian stable install source
  5. deb http://www.debian-multimedia.org/ unstable main
  6. deb     http://debian.cn99.com/debian unstable main non-free contrib
  7. deb-src http://debian.cn99.com/debian unstable main non-free contrib
复制代码
回复 支持 反对

使用道具 举报

发表于 2007-8-6 23:24:31 | 显示全部楼层
4.0,  就是Etch, 或者叫做Stable。


把我的这个, 里面所有的Sarge,改成Etch,就可以了。


#
# Debian sources list:
#

deb http://security.debian.org/ sarge/updates main contrib
deb http://http.us.debian.org/debian sarge main contrib non-free
deb http://non-us.debian.org/debian-non-US sarge/non-US main contrib non-free
deb http://debian.cn99.com/debian sarge main non-free contrib
deb http://debian.cn99.com/debian-security sarge/updates main contrib non-free
deb-src http://debian.cn99.com/debian sarge main non-free contrib
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-8-7 00:18:27 | 显示全部楼层
Post by Macolex
4.0,  就是Etch, 或者叫做Stable。


把我的这个, 里面所有的Sarge,改成Etch,就可以了。


#
# Debian sources list:
#

deb http://security.debian.org/ sarge/updates main contrib
deb http://http.us.debian.org/debian sarge main contrib non-free
deb http://non-us.debian.org/debian-non-US sarge/non-US main contrib non-free
deb http://debian.cn99.com/debian sarge main non-free contrib
deb http://debian.cn99.com/debian-security sarge/updates main contrib non-free
deb-src http://debian.cn99.com/debian sarge main non-free contrib


大家好。很感谢各位的关注和帮忙。
能否具体解释一下具体的意义?
具体地说就是:deb http://http.us.debian.org/debian sarge main contrib non-free 中,“deb”是什么意思?“http://http.us.debian.org/debian”又是什么意思?最主要的是希望大家能帮忙解释一下“sarge main contrib non-free”这一串是什么意思?是不是规定一定要这么写的?它是怎样和服务器上的目录对应上的?
呵呵,好像很菜的问题,不过我确实不知道,希望各位帮忙具体解释一下,再次谢谢啦!
回复 支持 反对

使用道具 举报

发表于 2007-8-7 09:50:46 | 显示全部楼层
置顶贴
置顶贴
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-8-7 11:30:55 | 显示全部楼层
大家都过来看看啊,帮忙解释一下那个文件各个部分的含义啦,谢谢啦!
回复 支持 反对

使用道具 举报

发表于 2007-8-7 15:54:03 | 显示全部楼层
man sources.list
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-8-8 11:36:44 | 显示全部楼层
好的,谢谢啦!
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表