Chinaunix首页 | 论坛 | 博客
  • 博客访问: 339678
  • 博文数量: 74
  • 博客积分: 2705
  • 博客等级: 少校
  • 技术积分: 590
  • 用 户 组: 普通用户
  • 注册时间: 2007-11-05 15:13
个人简介

鱼!

文章分类

全部博文(74)

文章存档

2014年(12)

2013年(10)

2012年(4)

2011年(11)

2010年(7)

2009年(12)

2008年(16)

2007年(2)

我的朋友

分类: LINUX

2010-08-07 08:28:40

apt-get update或aptitude update来更新源列表
sudo apt-get update
sudo apt-get dist-upgrade
debian通过下面的命令来从debian源上自动下载和安装软件。
apt-get或aptitude
apt-get update更新源列表
apt-cache search xxx,在源中搜索xxx软件
apt-get install xxx,从源中安装xxx软件
apt-get download xxx,从源中下载xxx debian deb包
apt-get source xxx,从源中下载xxx的源码包
apt-get remove xxx删除包
建议使用更高级的工具aptitude
aptitude 不仅能用命令行包管理还有图像界面
aptitude update
aptitude get xxx
aptitude search xxx
aptitude remove xxx
aptitude purge xxx
aptitude download xxx

`apt-spy'会根据站点回应时间和带宽自动创建`sources.list'。
#apt-get install apt-spy
#mv sources.list sources.list.bak //backup
#man apt-spy //获取详细的使用方法
#apt-spy update //更新您的镜像列表文件 /var/lib/apt-spy/mirrors.txt
# apt-spy -d testing -a Asia
//在亚洲区寻找速度最快的testing版镜像,并生成 sources.list文件,也可使用 -o 参数指定写入文件

设置DNS,直接写/etc/resolv.conf即可

设置IP,可以直接编辑/etc/network/interfaces这个文件,固定IP这样写:
auto lo eth0

iface lo inet loopback

iface eth0 inet static
address 192.168.2.2
netmask 255.255.255.0
broadcast 192.168.2.255
gateway 192.168.2.1
里面把地址和网关设好即可。用DHCP时后一段是这样:

auto eth0
iface eth0 inet dhcp

这个文件改动之后,应该重启网络:

/etc/init.d/networking restart
阅读(2088) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~