Debian

来自开放百科 - 灰狐
(版本间的差异)
跳转到: 导航, 搜索
(Debian发行版)
 
(未显示5个用户的197个中间版本)
第1行: 第1行:
== Debian基础知识 ==
+
Debian GNU/Linux
=== Debian 是什么? ===
+
[[Image:Debian.jpg]] Debian 是一套为了您的计算机所设计的自由操作系统 (OS)。操作系统是使计算机运行的基本程序和工具的集合。Debian 使用 Linux 核心(操作系统的最重要部份),但大部份的基本工具则来自 GNU 计划,因此我们称为 GNU/Linux。
+
  
Debian GNU/Linux 不单是个操作系统,它也包含多过 15490 个软件包,它们是一些经已编译的软件,并包装成一个容易安装的格式。
+
[[Image:Debian-100.gif|right]]
=== Debian 是什么? ===
+
[[文件:LAMP-stack.png|right|LAMP]]
Debian 是一套为了您的计算机所设计的自由操作系统 (OS)。操作系统是使计算机运行的基本程序和工具的集合。Debian 使用 Linux 核心(操作系统的最重要部份),但大部份的基本工具则来自 GNU 计划,因此我们称为 GNU/Linux。
+
 
 +
==简介==
 +
Debian是最重要Linux发行版,根据Distrowatch统计,在323款目前仍然活跃的发行版中,128款是基于Debian,74款是基于[[Ubuntu]],换句话说,所有发行版中有63%是源于Debian。相比之下,50款(15%)是基于[[Fedora]]或[[Red Hat]],28款(9%)是基于[[Slackware]],还有12款(4%)是基于[[Gentoo]]。([http://itmanagement.earthweb.com/osrc/article.php/3926941/Linux-Leaders-Debian-and-Ubuntu-Derivative-Distros.htm March 3, 2011])
 +
 
 +
==新闻==
 +
[[文件:Debian-Women-Project.png|right|[https://www.debian.org/women/ Debian Women Project]]]
 +
*[http://www.theregister.co.uk/2016/03/09/microsoft_sonic_debian/ Microsoft has released a Debian Linux switch OS. Repeat, a Debian Linux switch operating system]
 +
<rss>https://planet.debian.org/atom.xml|short|date|max=10</rss>
 +
 
 +
==Debian 是什么==
 +
[[Image:Debian-50.png]] 是Linux发行版当中最自由的一种。由位于世界各地上千名的自愿者不断开发和维护。它不属于任何的商业公司,完全由开源社区所有。是一套为了您的计算机所设计的自由操作系统 (OS)。操作系统是使计算机运行的基本程序和工具的集合。Debian 使用 Linux 核心(操作系统的最重要部份),但大部份的基本工具则来自 GNU 计划,因此我们称为 GNU/Linux
 +
 
 +
Sarge经过三年多的开发于2005年6月6日正式发布,替代Woody成为最新的Stable。testing的代号改为etch,unstable的代号还是sid。
 +
 
 +
Debian于2006年6月底停止对旧Stable版本Woody的支持。
 +
 
 +
Debian中代号为Sarge的发行版已获得开放源码发展实验室(OSDL)的电信运营商等级Linux(CGL)规格认证。
  
 
Debian GNU/Linux 不单是个操作系统,它也包含多过 15490 个软件包,它们是一些经已编译的软件,并包装成一个容易安装的格式。
 
Debian GNU/Linux 不单是个操作系统,它也包含多过 15490 个软件包,它们是一些经已编译的软件,并包装成一个容易安装的格式。
  
=== 相关链接 ===
+
现在就和微软说再见!http://goodbye-microsoft.com/ 在Windows XP下安装Debian
==== 官方正式链接 ====
+
[[Image:Huihoo-debian.gif|right]]
*官方网站 [http://www.debian.org/ www.debian.org] ''了解debian,从这里开始''
+
*新闻中心 [http://www.us.debian.org/News/ www.us.debian.org/News] ''包括升级通告,安装更新等重要新闻''
+
*软件包搜索站 [http://www.debian.org/distrib/packages www.debian.org/distrib/packages] ''提供各个版本的软件包搜索,下载,并提供详细的软件包信息''
+
*开发者中心 [http://www.debian.org/devel/ www.debian.org/devel] ''想成为debian开发者中正式一员?来这里''
+
*获得debian [http://www.debian.org/distrib/ www.debian.org/distrib] ''提供网络下载、CD购买,以及正式的安装文档''
+
*文档中心 [http://www.us.debian.org/doc/ www.debian.org/doc] ''包括 用户手册、开发人员手册、HOWTO以及通用FAQ文档等,你不能错过''
+
  
==== 民间组织、社区、个人站点 ====
+
[[Huihoo Debian Enterprise Guide]] - 灰狐Debian企业指南, 并逐步发展成 HDEL :)
 +
 
 +
==DEX==
 +
[https://wiki.debian.org/DEX DEX]致力于让 Debian 及其派生发行版能更加紧密的进行协作。
 +
 
 +
==版本==
 +
[[文件:debian-lts.jpeg|right]]
 +
[https://wiki.debian.org/LTS Debian Long Term Support]
 +
* Debian Bookworm (Debian 12)
 +
* Debian Bullseye (Debian 11)
 +
* Debian Buster (Debian 10)
 +
* Debian Stretch (Debian 9)
 +
* Debian Jessie (Debian 8)
 +
* [[Debian Wheezy]] (Debian 7)
 +
* Debian Squeeze (Debian 6.0)
 +
* [[Debian Lenny]] (Debian 5.0)
 +
* [[Debian Etch]] (Debian 4.0)
 +
* [[Debian Sarge]] (Debian 3.1)
 +
* [[Debian Woody]] (Debian 3.0)
 +
 
 +
==Cloud==
 +
*[http://cdimage.debian.org/cdimage/openstack/current/ Debian pre-built OpenStack images]
 +
*[[KVM on Debian]]
 +
*[[Xen on Debian]]
 +
*[http://www.debian.org/News/2012/20120425 Deploy your own cloud with Debian Wheezy] [[OpenStack]] + XCP on Debian
 +
 
 +
==Debian 11==
 +
[https://ostechnix.com/upgrade-to-debian-11-bullseye-from-debian-10-buster/ How To Upgrade To Debian 11 Bullseye From Debian 10 Buster]
 +
 
 +
==Debian 10==
 +
 
 +
==Debian 9==
 +
[http://mirrors.163.com/.help/debian.html Debian镜像使用帮助]
 +
 
 +
[https://computingforgeeks.com/how-to-install-php-7-3-on-debian-9-debian-8/ How To Install PHP 7.3 on Debian 9 / Debian 8]
 +
 
 +
==Debian 8==
 +
[[文件:debian8-jessie.png|right]]
 +
[https://bits.debian.org/2015/04/jessie-released.html Debian 8.0 Jessie 已经发布],并提供预构建的 [[OpenStack]] 镜像。(2015.04.25)
 +
 
 +
deb http://mirrors.163.com/debian/ jessie main non-free contrib
 +
deb http://mirrors.163.com/debian/ jessie-updates main non-free contrib
 +
deb http://mirrors.163.com/debian/ jessie-backports main non-free contrib
 +
deb-src http://mirrors.163.com/debian/ jessie main non-free contrib
 +
deb-src http://mirrors.163.com/debian/ jessie-updates main non-free contrib
 +
deb-src http://mirrors.163.com/debian/ jessie-backports main non-free contrib
 +
deb http://mirrors.163.com/debian-security/ jessie/updates main non-free contrib
 +
deb-src http://mirrors.163.com/debian-security/ jessie/updates main non-free contrib
 +
 
 +
==Debian 7==
 +
[http://lists.debian.org/debian-news/2011/msg00038.html Debian 7“Wheezy”将支持Multiarch]。Multiarch(多架构)允许一个系统能安装和运行有多个不同二进制文件的应用程序,例如i386-linux-gnu程序能运行在amd64-linux-gnu系统上。多架构简化了跨架构编译,这将大大增强了Debian实现通用操作系统承诺的能力,加强了新的64位系统对32位应用程序的支持。
 +
 
 +
deb http://mirrors.163.com/debian/ wheezy main
 +
deb-src http://mirrors.163.com/debian/ wheezy main
 +
 
 +
deb http://security.debian.org/ wheezy/updates main
 +
deb-src http://security.debian.org/ wheezy/updates main
 +
 
 +
==Debian 6==
 +
Debian 6.0 "Squeeze" 已[http://www.debian.org/News/2011/20110205a 正式发行],除了常见的 Debian GNU/Linux,这次还引入了 Debian GNU/kFreeBSD 作"技术预览"。
 +
 
 +
# main repo
 +
deb http://ftp.debian.org/debian/ squeeze main
 +
deb-src http://ftp.debian.org/debian/ squeeze main
 +
deb http://security.debian.org/ squeeze/updates main
 +
deb-src http://security.debian.org/ squeeze/updates main
 +
 
 +
Debian将AMD64和Intel64都称作“amd64”
 +
 
 +
==Debian 5==
 +
Debian GNU/Linux 5.0.0 was released February 14th, 2009.
 +
 
 +
Debian GNU/Linux 5.0 updated                            [email protected]
 +
April 11th, 2009                http://www.debian.org/News/2009/20090411
 +
-------------------------------------------------------------------------
 +
deb http://volatile.debian.org/debian-volatile lenny/volatile main
 +
deb-src http://volatile.debian.org/debian-volatile lenny/volatile main
 +
 
 +
#在后来添加
 +
deb http://ftp.tw.debian.org/debian/ lenny main
 +
deb-src http://ftp.tw.debian.org/debian/ lenny main
 +
deb http://ftp.tw.debian.org/debian/ lenny contrib
 +
deb-src http://ftp.tw.debian.org/debian/ lenny contrib
 +
deb http://ftp.tw.debian.org/debian/ lenny non-free
 +
deb-src http://ftp.tw.debian.org/debian/ lenny non-free
 +
or
 +
deb http://mirrors.163.com/debian/ lenny main non-free contrib
 +
deb-src http://mirrors.163.com/debian/ lenny main non-free contrib
 +
若出现 W: Failed to fetch http://ftp.at.debian.org/debian/dists/lenny/main/source/Sources.gz  Sub-process gzip returned an error code 类似错误
 +
可能这个源没你需要的软件包, 如AMD-64 处理方法: 换一个源并且 clean /var/lib/apt/lists and trying again
 +
 
 +
==Debian 4==
 +
大家可试着刻录并安装  [http://ftp.wa.au.debian.org/debian-cd/4.0_r0/i386/iso-cd/debian-40r0-i386-xfce-CD-1.iso  debian-40r0-i386-xfce-CD-1.iso] , 安装时可以选择非网络安装,这样就可以把光盘上带的 400 多个软件包装上,包括 xfce 4 桌面系统,安装的整个过程还是字符方式,但安装完重新启动 Debian 后就能顺利的进入 xfce 桌面
 +
接着 修改 /etc/apt/sources.list
 +
 
 +
Etch 国内源
 +
deb http://mirrors.163.com/debian/ etch main
 +
deb-src http://mirrors.163.com/debian/ etch main
 +
 
 +
Sarge国内源
 +
deb http://mirrors.163.com/debian/ sarge main non-free contrib
 +
deb-src http://mirrors.163.com/debian/ sarge main non-free contrib
 +
 
 +
aptitude update
 +
aptitude upgrade
 +
 +
安装字体
 +
aptitude install ttf-bitstream-vera ttf-arphic-uming xfonts-wqy 
 +
dpkg-reconfigure locales 选择默认locale为中文的,如zh_CN.UTF-8
 +
安装 [https://fcitx-im.org/ fcitx] 小企鹅输入法
 +
apt-get install fcitx-pinyin im-switch
 +
im-switch -s fcitx -z all_ALL
 +
修改/etc/X11/xinit/xinput.d/fcitx,为:
 +
XIM=fcitx
 +
XIM_PROGRAM=/usr/bin/fcitx
 +
XIM_ARGS=""
 +
GTK_IM_MODULE=fcitx
 +
QT4_IM_MODULE=fcitx
 +
DEPENDS="fcitx"
 +
[http://wiki.ubuntu.com.cn/Fcitx 英文环境下 Fcitx配置]
 +
Xfce:
 +
# touch /etc/X11/Xsession.d/95input
 +
在这个文件中写入如下内容: <bash>
 +
export LANG=zh_CN.UTF-8
 +
export LC_CTYPE=zh_CN.UTF-8
 +
export LC_ALL=
 +
export XMODIFIERS=@im=fcitx
 +
fcitx &
 +
或者
 +
vi ~/.xinitrc,输入:
 +
export LC_ALL=zh_CN.UTF-8
 +
export LANG=zh_CN.UTF-8
 +
export XMODIFIERS=@im=fcitx
 +
fcitx &
 +
 
 +
包管理
 +
apt-get install synaptic // 通过 Synaptic 进行包管理
 +
参考: [http://www.debsir.org/main/?q=node/141 Debian etch 简要安装指南]
 +
 
 +
debian的中文美化 - http://colding.bokee.com/4293814.html
 +
 
 +
using gnome-screensaver in XFCE and NOT xscreensaver
 +
#apt-get remove xscreensaver
 +
#apt-get install gnome-screensaver
 +
To auto-start gnome-screensaver, add it as an Autostarted Application:
 +
 
 +
Xfce menu > Settings > Autostarted Applications
 +
 
 +
The command for starting the gnome-screensaver daemon is:
 +
gnome-screensaver
 +
 
 +
modify the file /usr/bin/xflock4:
 +
cp /usr/bin/xflock4 /usr/bin/xflock4.orig
 +
#xscreensaver-command -lock || xlock $*
 +
gnome-screensaver-command --lock
 +
exit 0
 +
调整显示器亮度
 +
 
 +
安装 GNOME
 +
#apt-get install x-window-system-core
 +
#apt-get install gnome
 +
安装 KDE
 +
#apt-get install kde
 +
安装声卡
 +
#apt-get install alsa-base alsa-utils
 +
# alsaconf
 +
http://www.debian.ha.cn/htmldata/8/2006_03/article_896_1.html
 +
 
 +
[[Image:looking-glass.jpg|thumb|right|Sun Looking glass Desktop]]
 +
Java 3D Desktop: Sun Looking glass Desktop
 +
vi /etc/apt/sources.list
 +
deb http://javadesktop.org/lg3d/debian stable contrib
 +
apt-get update
 +
sudo apt-get install lg3d-core
 +
Success. LG has been added as a gdm session.
 +
重启并选择 Looking Glass session, 成功进入 3D 桌面 :)
 +
 
 +
==常用包命令==
 +
#useradd -s /bin/bash -m allen
 +
finger allen
 +
#useradd allen
 +
#passwd allen
 +
# userdel -r allen
 +
http://www.debian.org/doc/manuals/reference/ch-package.zh-cn.html
 +
*dpkg      – Debian 包安装工具
 +
*apt-get  – APT 的命令行前端
 +
*aptitude  – APT 的高级的字符和命令行前端
 +
*synaptic  – 图形界面的 APT 前端
 +
*dselect  – 使用菜单界面的包管理工具
 +
*tasksel  – Task 安装工具
 +
 
 +
*dpkg-reconfigure  - 重新配置已安装的软件包(如果它是使用 debconf 进行配置的)
 +
*dpkg-source      - 管理源码包
 +
*dpkg-buildpackage - 自动生成包文件
 +
*apt-cache        - 在本地缓冲区检查包文件
 +
 
 +
*apt-get  check          # 更新缓冲区并检查损坏的软件包
 +
*apt-cache search  pattern # 按文本描述搜索软件包,看有哪些包可供选择
 +
*apt-cache policy  package # 软件包的 priority/dists 信息
 +
*apt-cache show -a package # 显示所有 dists 中软件包描述信息
 +
*apt-cache showsrc package # 显示相应源码包的信息
 +
*apt-cache showpkg package # 软件包调试信息
 +
*dpkg  --audit|-C          # 搜索未完成安装的软件包
 +
*dpkg {-s|--status} package ... # 已安装软件包描述
 +
*dpkg -l package ...      # 已安装软件包的状态(每个占一行)
 +
*dpkg -L package ...      # 列出软件包安装的文件的名称
 +
 
 +
==Debian Live==
 +
The Debian Live project aims to create Debian Live images for CDs, DVDs, USB sticks and tarballs for netboot for the Etch release (and newer).
 +
*http://debian-live.alioth.debian.org/
 +
*http://live.debian.net/
 +
*http://wiki.debian.org/DebianLive/
 +
==常用命令==
 +
netstat -ntulp
 +
 
 +
查看当前目录下文件的个数 ls -l | grep "^-" | wc -l
 +
  
 +
查看当前目录下文件的个数,包括子目录里的 ls -lR| grep "^-" | wc -l
 +
  
 +
查看某目录下文件夹(目录)的个数,包括子目录里的 ls -lR| grep "^d" | wc -l
 +
 
 +
sudo find / -name "scala" -print
 +
 
 +
==GCC==
 +
http://lists.debian.org/debian-gcc/
 +
 
 +
# apt-get install build-essential
 +
# cat /proc/version // 确定核心是什么版本gcc编译的
 +
# apt-get -u install gcc-2.95 g++-2.95 make
 +
# export CC=/usr/bin/gcc-2.95
 +
# export CXX=/usr/bin/g++-2.95
 +
 
 +
http://www.debian.org/doc/manuals/reference/ch-program.zh-cn.html // 编程
 +
# apt-get install glibc-doc manpages-dev libc6-dev gcc
 +
 
 +
$ /usr/bin/gcc-2.95 -Wall -g -o run_example example.c -lm
 +
$ ./run_example
 +
 
 +
关联/usr/bin/gcc-2.95 和 gcc
 +
ln -sf /usr/bin/gcc-2.95 /usr/bin/gcc
 +
$ gcc -Wall -g -o run_example example.c -lm
 +
 
 +
==安装指南==
 +
* [[winxp,solaris10,linux,freebsd install in a system]]
 +
* [[打造自己的Debian]]
 +
 
 +
Debian的安装 大体要 经过三个步骤
 +
 
 +
===一,安装基本部分===
 +
通过安装光盘或自己制作引导软盘
 +
 
 +
基础安装部分可参考 - http://www.huihoo.com/gnu_linux/debian/tutorial/Debian-Install-Guide-4.html
 +
 
 +
===二,安装,配制网络===
 +
PPPCONFIG 通过它来配制基本项
 +
 
 +
NUMBER 86 755 25100572
 +
User ...
 +
password
 +
Speed 115200
 +
COM /dev/ttyS1
 +
Method PAP
 +
 
 +
PPPOEConf 测试
 +
 
 +
在/etc/resolv.conf加入一个nameserver
 +
如;nameserver 202.96.134.133
 +
 
 +
$ sudo apt-get install net-tools
 +
$ ifconfig -a
 +
 
 +
bash: ping: command not found 
 +
 
 +
apt-get install iputils-ping
 +
 
 +
netstat -nr
 +
 
 +
/usr/bin/pon dsl-provider (启动adsl)
 +
 
 +
/usr/bin/poff dsl-provider (关闭adsl)
 +
 
 +
route add default gw ip (获得的动态IP)
 +
 
 +
nslookup www.huihoo.com (OK)
 +
 
 +
假如某台机器的eth0使用DHCP动态IP地址连接Internet,eth1连接LAN,则其/etc/network/interfaces的设置如下(适用于Woody及后继版本)
 +
 
 +
auto lo
 +
iface lo inet loopback
 +
   
 +
auto eth0
 +
iface eth0 inet dhcp
 +
   
 +
auto eth1
 +
iface eth1 inet static
 +
address 192.168.18.100
 +
gateway 192.168.18.1
 +
netmask 255.255.255.0
 +
 
 +
/etc/resolv.conf
 +
nameserver 202.96.128.86
 +
nameserver 202.96.128.68
 +
nameserver 202.96.199.133
 +
 
 +
设置服务启动项,enable & disable daemon
 +
apt-get install rcconf
 +
rcconf
 +
 
 +
更多细节:https://wiki.debian.org/NetworkConfiguration
 +
 
 +
===三. apt-get 安装方式===
 +
通过HTTP,FTP等方式 用APT方式进行其余部件的 安装。这点很吸引人
 +
apt-get install xxx.deb
 +
 
 +
vi /etc/apt/sources.list
 +
加入 deb http://http.us.debian.org/debian woody main contrib non-free
 +
deb http://non-us.debian.org/debian-non-US woody/non-US main contrib non-free
 +
 
 +
sid 换成woody
 +
 
 +
apt-get update
 +
 
 +
apt-get dist-upgrade
 +
 
 +
运行 dselect
 +
 
 +
光标在 Update上 按 enter
 +
 
 +
完了再 Select,什么都不用改,直接enter返回到前选项单里,因为它已经预订了基本需要的东西.
 +
 
 +
Install, 是否安装 enter,等下完后开始配置,会问你问题.
 +
 
 +
完成后回问是否删除下载的.deb文件,随你便,默认删除.
 +
 
 +
debian server 192.168.1.6
 +
 
 +
安装ssh
 +
 
 +
apt-get install ssh
 +
 
 +
===输入法===
 +
*[https://pinyin.sogou.com/linux/ 搜狗输入法 for linux]
 +
*[https://fcitx-im.org Fcitx]
 +
 
 +
===终端===
 +
sudo add-apt-repository ppa:gnome-terminator
 +
sudo apt-get update
 +
sudo apt-get install terminator
 +
 
 +
==Firefox==
 +
[http://www.captain.at/howto-run-firefox-3-debian-etch.php Running Firefox 3 on Debian Etch with GTK 2.10]
 +
 
 +
Download [http://ftp.gnome.org/pub/GNOME/sources/gtk+/2.10/gtk+-2.10.14.tar.bz2 GTK+ 2.10] from gtk.org and do this:
 +
# cd /opt
 +
# tar xjf gtk+-2.10.14.tar.bz2
 +
# mkdir gtk210
 +
# cd gtk+-2.10.14
 +
# ./configure --prefix=/opt/gtk210
 +
# make
 +
# make install
 +
Now create the start script "firefox.sh":
 +
#!/bin/sh
 +
export LD_LIBRARY_PATH="/opt/gtk210/lib"
 +
/path-to-firefox-3/firefox $*
 +
==问题集==
 +
*ldconfig: Writing of cache data failed: No space left on device
 +
rm -f /var/cache/apt/archives/*.deb
 +
apt-get clean
 +
du -h / --max-depth=1
 +
du -s /var/cache/*
 +
*locate: can not stat () `/var/lib/mlocate/mlocate.db': No such file or directory
 +
如果出现此错误,请执行updatedb
 +
 
 +
磁盘出问题,无法启动。
 +
 
 +
进入 [[BusyBox]] 模式,运行 fsck /dev/sda1 进行磁盘修复,然后重启成功。
 +
 
 +
==官方链接==
 +
*[http://www.debian.org/ 官方网站] ''了解debian,从这里开始''
 +
*[http://www.us.debian.org/News/ 新闻中心] ''包括升级通告,安装更新等重要新闻''
 +
*[http://www.debian.org/distrib/packages 软件包搜索站] ''提供各个版本的软件包搜索,下载,并提供详细的软件包信息''
 +
*[http://www.debian.org/devel/ 开发者中心] ''想成为debian开发者中正式一员?来这里''
 +
*[http://www.debian.org/distrib/ 获得debian] ''提供网络下载、CD购买,以及正式的安装文档''
 +
*[http://www.us.debian.org/doc/ 文档中心] ''包括 用户手册、开发人员手册、HOWTO以及通用FAQ文档等,你不能错过''
 +
 
 +
==民间组织、社区、个人站点==
  
 
*Debian星球 [http://www.debianplanet.org/ www.debianplanet.org] ''历史悠久的国际化Debian社区''
 
*Debian星球 [http://www.debianplanet.org/ www.debianplanet.org] ''历史悠久的国际化Debian社区''
第26行: 第419行:
 
* Debian Wiki [http://wiki.debian.org/ http://wiki.debian.org]
 
* Debian Wiki [http://wiki.debian.org/ http://wiki.debian.org]
  
== 应用技巧 ==
+
==Debian发行版==
 +
[[文件:aims-desktop-logo.png|right|AIMS Desktop]]
 +
[[文件:mobian-logo.jpg|right|Mobian]]
 +
[[文件:VyOS-logo.png|right|VyOS]]
 +
[[文件:apertis-logo.png|right|Apertis]]
 +
[https://www.debian.org/derivatives/ Debian 衍生发行版]
 +
 
 +
[https://wiki.debian.org/DebianPureBlends Debian Pure Blends] 是为有特定需要的人群提供的一套[https://www.debian.org/blends/ 解决方案]
 +
 
 +
基于 Debian 已经衍生了 [https://distrowatch.com/search.php?basedon=Debian&status=All 400] 多个操作系统分发版,其中仍有 [https://distrowatch.com/search.php?basedon=Debian 120] 个还在活跃中,一个真正强大的 OS 生态系统。
 +
 
 +
主要的 Debian 分发版:
 +
*[[Ubuntu]]: 大家最熟悉
 +
*[https://desktop.aims.ac.za/ AIMS Desktop] African Institute for Mathematical Sciences
 +
*[https://grml.org/ Grml] 面向系统管理员的 live 系统
 +
*[[Kali Linux]]: 安全审计和渗透测试
 +
*[https://pureos.net/ PureOS] 获得 FSF 认可,专注于隐私、安全和便捷
 +
*[https://tails.boum.org/ Tails] 保护隐私和保持匿名
 +
*[https://wiki.deepin.org/zh/%E5%85%B3%E4%BA%8EDeepin/Deepin%E4%BB%8B%E7%BB%8D 深度操作系统] 基于 [[Qt]] 开发了深度桌面环境、深度控制中心和一系列应用。
 +
*[https://github.com/vyos/ VyOS] Open-source router and firewall platform
 +
*[https://www.apertis.org/ Apertis] Collaborative OS platform for products, Production Friendly + Frequent Releases + Developer Ready
 +
 
 +
*[https://github.com/armbian Armbian] Minimal Debian based Linux for single board computers
 +
*[https://mobian.org/ Mobian] Bringing Debian to mobile devices
 +
*[[Adamantix]] - A distribution focusing on security.
 +
*[[Ubuntu]] - Linux for Human Beings - http://www.ubuntulinux.org/
 +
*[[Debian GNU/Hurd]] - http://www.debian.org/ports/hurd/
 +
*[[Debian GNU/NetBSD]] - http://www.debian.org/ports/netbsd/
 +
*[[Debian GNU/kFreeBSD]] - http://www.debian.org/ports/kfreebsd-gnu/
 +
*[[Skolelinux]] – a Custom Debian Distribution - http://www.skolelinux.org
 +
*[[Custom Debian]] - http://wiki.debian.org/CustomDebian
 +
 
 +
==项目==
 +
*[https://github.com/go-debos/debos debos] - Debian OS images builder
 +
 
 +
==链接==
 +
*http://download.huihoo.com/debian/
 +
*http://docs.huihoo.com/debian/
 +
*[http://docs.huihoo.com/ubuntu/13.04/serverguide/index.html Ubuntu Server Guide]
 +
*[http://www.unixmen.com/setting-forwarding-dns-server-debian/ Setting Up a Forwarding DNS Server On Debian]
 +
 
 +
==Debian Mirrors==
 +
建立 Debian mirror 的脚本, 如:debian-mirror.sh
 +
#!/bin/bash
 +
SRC=rsync://debian.ethz.ch/debian
 +
DST=/var/mirrors/debian/
 +
rsync -vzrltopg --progress --delete $SRC $DST
 +
建立 Debian ISO mirror 脚本,如: debian-iso.sh
 +
#!/bin/bash
 +
SRC=rsync://debian.ethz.ch/debian-cd
 +
DST=/var/mirrors/debian-cd/
 +
rsync -vzrltopg --progress --delete $SRC $DST
 +
更多 Debian Mirrors: http://www.debian.org/mirror/list
 +
==开发相关==
 +
*[https://salsa.debian.org/ Debian GitLab]
 +
*Debian Forge: http://alioth.debian.org/
 +
*http://www.debian.org/devel/
 +
*http://wiki.debian.org/DebianDevelopment
 +
*http://lintian.debian.org
 +
*http://git.debian.org/
 +
*[http://www.debian.org/distrib/packages Debian Packages]
 +
*[https://dep-team.pages.debian.net/ DEP - Debian Enhancement Proposals]
 +
 
 +
==相关计划==
 +
*[[Huihoo Debian Enterprise Guide]]
 +
*[[Huihoo Debian Media Server]]
 +
*[[DebianGis]]
 +
*[[Huihoo PHP Applications]]
 +
*[[Huihoo Python Applications]]
 +
*[[Huihoo Ruby Applications]]
 +
*[[Huihoo Geronimo Applications]]
 +
*[[Huihoo JOnAS Applications]]
 +
==图集==
 +
[https://screenshots.debian.net/ screenshots.debian.net]
  
=== 开发相关 ===
+
<gallery>
 +
image:debian-9-and-8.png|Debian 9
 +
image:apertis-functional-view.png|Apertis平台
 +
image:apertis-infrastructure.png|Apertis基础设施
 +
image:apertis-search-flow.png|Apertis搜索
 +
</gallery>
  
*如何最快的从源码包制作 debian 包?
+
==链接==
<code><pre>
+
*[https://meetings-archive.debian.net/pub/debian-meetings/ Debian Meetings]
$dh_make -e you@mail -s
+
$debuild
+
</pre></code>
+
  
== 精彩图集 ==
+
[[category:operating system]]
[[category:Linux发行版]]
+
[[category:GNU]]
 +
[[category:linux]]
 +
[[category:debian]]
 +
[[category:Huihoo Foundation]]

2022年12月12日 (一) 08:42的最后版本

Debian GNU/Linux

Debian-100.gif
LAMP

目录

[编辑] 简介

Debian是最重要Linux发行版,根据Distrowatch统计,在323款目前仍然活跃的发行版中,128款是基于Debian,74款是基于Ubuntu,换句话说,所有发行版中有63%是源于Debian。相比之下,50款(15%)是基于FedoraRed Hat,28款(9%)是基于Slackware,还有12款(4%)是基于Gentoo。(March 3, 2011)

[编辑] 新闻

Debian Women Project

自https://planet.debian.org/atom.xml加载RSS失败或RSS源被墙

[编辑] Debian 是什么

Debian-50.png 是Linux发行版当中最自由的一种。由位于世界各地上千名的自愿者不断开发和维护。它不属于任何的商业公司,完全由开源社区所有。是一套为了您的计算机所设计的自由操作系统 (OS)。操作系统是使计算机运行的基本程序和工具的集合。Debian 使用 Linux 核心(操作系统的最重要部份),但大部份的基本工具则来自 GNU 计划,因此我们称为 GNU/Linux

Sarge经过三年多的开发于2005年6月6日正式发布,替代Woody成为最新的Stable。testing的代号改为etch,unstable的代号还是sid。

Debian于2006年6月底停止对旧Stable版本Woody的支持。

Debian中代号为Sarge的发行版已获得开放源码发展实验室(OSDL)的电信运营商等级Linux(CGL)规格认证。

Debian GNU/Linux 不单是个操作系统,它也包含多过 15490 个软件包,它们是一些经已编译的软件,并包装成一个容易安装的格式。

现在就和微软说再见!http://goodbye-microsoft.com/ 在Windows XP下安装Debian

Huihoo-debian.gif

Huihoo Debian Enterprise Guide - 灰狐Debian企业指南, 并逐步发展成 HDEL :)

[编辑] DEX

DEX致力于让 Debian 及其派生发行版能更加紧密的进行协作。

[编辑] 版本

Debian-lts.jpeg

Debian Long Term Support

[编辑] Cloud

[编辑] Debian 11

How To Upgrade To Debian 11 Bullseye From Debian 10 Buster

[编辑] Debian 10

[编辑] Debian 9

Debian镜像使用帮助

How To Install PHP 7.3 on Debian 9 / Debian 8

[编辑] Debian 8

Debian8-jessie.png

Debian 8.0 Jessie 已经发布,并提供预构建的 OpenStack 镜像。(2015.04.25)

deb http://mirrors.163.com/debian/ jessie main non-free contrib
deb http://mirrors.163.com/debian/ jessie-updates main non-free contrib
deb http://mirrors.163.com/debian/ jessie-backports main non-free contrib
deb-src http://mirrors.163.com/debian/ jessie main non-free contrib
deb-src http://mirrors.163.com/debian/ jessie-updates main non-free contrib
deb-src http://mirrors.163.com/debian/ jessie-backports main non-free contrib
deb http://mirrors.163.com/debian-security/ jessie/updates main non-free contrib
deb-src http://mirrors.163.com/debian-security/ jessie/updates main non-free contrib

[编辑] Debian 7

Debian 7“Wheezy”将支持Multiarch。Multiarch(多架构)允许一个系统能安装和运行有多个不同二进制文件的应用程序,例如i386-linux-gnu程序能运行在amd64-linux-gnu系统上。多架构简化了跨架构编译,这将大大增强了Debian实现通用操作系统承诺的能力,加强了新的64位系统对32位应用程序的支持。

deb http://mirrors.163.com/debian/ wheezy main
deb-src http://mirrors.163.com/debian/ wheezy main
deb http://security.debian.org/ wheezy/updates main
deb-src http://security.debian.org/ wheezy/updates main

[编辑] Debian 6

Debian 6.0 "Squeeze" 已正式发行,除了常见的 Debian GNU/Linux,这次还引入了 Debian GNU/kFreeBSD 作"技术预览"。

# main repo
deb http://ftp.debian.org/debian/ squeeze main
deb-src http://ftp.debian.org/debian/ squeeze main
deb http://security.debian.org/ squeeze/updates main
deb-src http://security.debian.org/ squeeze/updates main

Debian将AMD64和Intel64都称作“amd64”

[编辑] Debian 5

Debian GNU/Linux 5.0.0 was released February 14th, 2009.
Debian GNU/Linux 5.0 updated                             [email protected]
April 11th, 2009                 http://www.debian.org/News/2009/20090411

deb http://volatile.debian.org/debian-volatile lenny/volatile main
deb-src http://volatile.debian.org/debian-volatile lenny/volatile main
#在后来添加
deb http://ftp.tw.debian.org/debian/ lenny main
deb-src http://ftp.tw.debian.org/debian/ lenny main
deb http://ftp.tw.debian.org/debian/ lenny contrib
deb-src http://ftp.tw.debian.org/debian/ lenny contrib
deb http://ftp.tw.debian.org/debian/ lenny non-free
deb-src http://ftp.tw.debian.org/debian/ lenny non-free

or

deb http://mirrors.163.com/debian/ lenny main non-free contrib
deb-src http://mirrors.163.com/debian/ lenny main non-free contrib 

若出现 W: Failed to fetch http://ftp.at.debian.org/debian/dists/lenny/main/source/Sources.gz Sub-process gzip returned an error code 类似错误

可能这个源没你需要的软件包, 如AMD-64 处理方法: 换一个源并且 clean /var/lib/apt/lists and trying again

[编辑] Debian 4

大家可试着刻录并安装 debian-40r0-i386-xfce-CD-1.iso , 安装时可以选择非网络安装,这样就可以把光盘上带的 400 多个软件包装上,包括 xfce 4 桌面系统,安装的整个过程还是字符方式,但安装完重新启动 Debian 后就能顺利的进入 xfce 桌面 接着 修改 /etc/apt/sources.list

Etch 国内源

deb http://mirrors.163.com/debian/ etch main
deb-src http://mirrors.163.com/debian/ etch main

Sarge国内源

deb http://mirrors.163.com/debian/ sarge main non-free contrib
deb-src http://mirrors.163.com/debian/ sarge main non-free contrib
aptitude update
aptitude upgrade

安装字体

aptitude install ttf-bitstream-vera ttf-arphic-uming xfonts-wqy  
dpkg-reconfigure locales 选择默认locale为中文的,如zh_CN.UTF-8

安装 fcitx 小企鹅输入法

apt-get install fcitx-pinyin im-switch 
im-switch -s fcitx -z all_ALL 

修改/etc/X11/xinit/xinput.d/fcitx,为:

XIM=fcitx
XIM_PROGRAM=/usr/bin/fcitx
XIM_ARGS=""
GTK_IM_MODULE=fcitx
QT4_IM_MODULE=fcitx
DEPENDS="fcitx" 

英文环境下 Fcitx配置 Xfce:

# touch /etc/X11/Xsession.d/95input

在这个文件中写入如下内容: <bash>

export LANG=zh_CN.UTF-8
export LC_CTYPE=zh_CN.UTF-8
export LC_ALL=
export XMODIFIERS=@im=fcitx
fcitx &

或者

vi ~/.xinitrc,输入:
export LC_ALL=zh_CN.UTF-8
export LANG=zh_CN.UTF-8
export XMODIFIERS=@im=fcitx
fcitx &

包管理

apt-get install synaptic // 通过 Synaptic 进行包管理

参考: Debian etch 简要安装指南

debian的中文美化 - http://colding.bokee.com/4293814.html

using gnome-screensaver in XFCE and NOT xscreensaver

#apt-get remove xscreensaver
#apt-get install gnome-screensaver

To auto-start gnome-screensaver, add it as an Autostarted Application:

Xfce menu > Settings > Autostarted Applications

The command for starting the gnome-screensaver daemon is:

gnome-screensaver

modify the file /usr/bin/xflock4:

cp /usr/bin/xflock4 /usr/bin/xflock4.orig
#xscreensaver-command -lock || xlock $*
gnome-screensaver-command --lock
exit 0 

调整显示器亮度

安装 GNOME

#apt-get install x-window-system-core
#apt-get install gnome

安装 KDE

#apt-get install kde

安装声卡

#apt-get install alsa-base alsa-utils
# alsaconf 

http://www.debian.ha.cn/htmldata/8/2006_03/article_896_1.html

Sun Looking glass Desktop

Java 3D Desktop: Sun Looking glass Desktop

vi /etc/apt/sources.list
deb http://javadesktop.org/lg3d/debian stable contrib
apt-get update
sudo apt-get install lg3d-core
Success. LG has been added as a gdm session.

重启并选择 Looking Glass session, 成功进入 3D 桌面 :)

[编辑] 常用包命令

#useradd -s /bin/bash -m allen
finger allen
#useradd allen
#passwd allen
# userdel -r allen

http://www.debian.org/doc/manuals/reference/ch-package.zh-cn.html

  • dpkg – Debian 包安装工具
  • apt-get – APT 的命令行前端
  • aptitude – APT 的高级的字符和命令行前端
  • synaptic – 图形界面的 APT 前端
  • dselect – 使用菜单界面的包管理工具
  • tasksel – Task 安装工具
  • dpkg-reconfigure - 重新配置已安装的软件包(如果它是使用 debconf 进行配置的)
  • dpkg-source - 管理源码包
  • dpkg-buildpackage - 自动生成包文件
  • apt-cache - 在本地缓冲区检查包文件
  • apt-get check # 更新缓冲区并检查损坏的软件包
  • apt-cache search pattern # 按文本描述搜索软件包,看有哪些包可供选择
  • apt-cache policy package # 软件包的 priority/dists 信息
  • apt-cache show -a package # 显示所有 dists 中软件包描述信息
  • apt-cache showsrc package # 显示相应源码包的信息
  • apt-cache showpkg package # 软件包调试信息
  • dpkg --audit|-C # 搜索未完成安装的软件包
  • dpkg {-s|--status} package ... # 已安装软件包描述
  • dpkg -l package ... # 已安装软件包的状态(每个占一行)
  • dpkg -L package ... # 列出软件包安装的文件的名称

[编辑] Debian Live

The Debian Live project aims to create Debian Live images for CDs, DVDs, USB sticks and tarballs for netboot for the Etch release (and newer).

[编辑] 常用命令

netstat -ntulp

查看当前目录下文件的个数 ls -l | grep "^-" | wc -l    查看当前目录下文件的个数,包括子目录里的 ls -lR| grep "^-" | wc -l    查看某目录下文件夹(目录)的个数,包括子目录里的 ls -lR| grep "^d" | wc -l

sudo find / -name "scala" -print

[编辑] GCC

http://lists.debian.org/debian-gcc/

  1. apt-get install build-essential
  2. cat /proc/version // 确定核心是什么版本gcc编译的
  3. apt-get -u install gcc-2.95 g++-2.95 make
  4. export CC=/usr/bin/gcc-2.95
  5. export CXX=/usr/bin/g++-2.95

http://www.debian.org/doc/manuals/reference/ch-program.zh-cn.html // 编程

  1. apt-get install glibc-doc manpages-dev libc6-dev gcc

$ /usr/bin/gcc-2.95 -Wall -g -o run_example example.c -lm $ ./run_example

关联/usr/bin/gcc-2.95 和 gcc ln -sf /usr/bin/gcc-2.95 /usr/bin/gcc $ gcc -Wall -g -o run_example example.c -lm

[编辑] 安装指南

Debian的安装 大体要 经过三个步骤

[编辑] 一,安装基本部分

通过安装光盘或自己制作引导软盘

基础安装部分可参考 - http://www.huihoo.com/gnu_linux/debian/tutorial/Debian-Install-Guide-4.html

[编辑] 二,安装,配制网络

PPPCONFIG 通过它来配制基本项

NUMBER 86 755 25100572
User ...
password
Speed 115200
COM /dev/ttyS1
Method PAP
PPPOEConf 测试

在/etc/resolv.conf加入一个nameserver

如;nameserver 202.96.134.133
$ sudo apt-get install net-tools
$ ifconfig -a

bash: ping: command not found

apt-get install iputils-ping

netstat -nr

/usr/bin/pon dsl-provider (启动adsl)

/usr/bin/poff dsl-provider (关闭adsl)

route add default gw ip (获得的动态IP)

nslookup www.huihoo.com (OK)

假如某台机器的eth0使用DHCP动态IP地址连接Internet,eth1连接LAN,则其/etc/network/interfaces的设置如下(适用于Woody及后继版本)

auto lo
iface lo inet loopback
    
auto eth0
iface eth0 inet dhcp
    
auto eth1
iface eth1 inet static
address 192.168.18.100
gateway 192.168.18.1
netmask 255.255.255.0

/etc/resolv.conf

nameserver 202.96.128.86
nameserver 202.96.128.68
nameserver 202.96.199.133

设置服务启动项,enable & disable daemon

apt-get install rcconf
rcconf

更多细节:https://wiki.debian.org/NetworkConfiguration

[编辑] 三. apt-get 安装方式

通过HTTP,FTP等方式 用APT方式进行其余部件的 安装。这点很吸引人

apt-get install xxx.deb

vi /etc/apt/sources.list

加入 deb http://http.us.debian.org/debian woody main contrib non-free
deb http://non-us.debian.org/debian-non-US woody/non-US main contrib non-free

sid 换成woody

apt-get update

apt-get dist-upgrade

运行 dselect

光标在 Update上 按 enter

完了再 Select,什么都不用改,直接enter返回到前选项单里,因为它已经预订了基本需要的东西.

Install, 是否安装 enter,等下完后开始配置,会问你问题.

完成后回问是否删除下载的.deb文件,随你便,默认删除.

debian server 192.168.1.6

安装ssh

apt-get install ssh

[编辑] 输入法

[编辑] 终端

sudo add-apt-repository ppa:gnome-terminator
sudo apt-get update
sudo apt-get install terminator

[编辑] Firefox

Running Firefox 3 on Debian Etch with GTK 2.10

Download GTK+ 2.10 from gtk.org and do this:

# cd /opt
# tar xjf gtk+-2.10.14.tar.bz2 
# mkdir gtk210
# cd gtk+-2.10.14
# ./configure --prefix=/opt/gtk210
# make
# make install

Now create the start script "firefox.sh":

#!/bin/sh
export LD_LIBRARY_PATH="/opt/gtk210/lib"
/path-to-firefox-3/firefox $*

[编辑] 问题集

  • ldconfig: Writing of cache data failed: No space left on device
rm -f /var/cache/apt/archives/*.deb
apt-get clean
du -h / --max-depth=1
du -s /var/cache/*
  • locate: can not stat () `/var/lib/mlocate/mlocate.db': No such file or directory

如果出现此错误,请执行updatedb

磁盘出问题,无法启动。

进入 BusyBox 模式,运行 fsck /dev/sda1 进行磁盘修复,然后重启成功。

[编辑] 官方链接

  • 官方网站 了解debian,从这里开始
  • 新闻中心 包括升级通告,安装更新等重要新闻
  • 软件包搜索站 提供各个版本的软件包搜索,下载,并提供详细的软件包信息
  • 开发者中心 想成为debian开发者中正式一员?来这里
  • 获得debian 提供网络下载、CD购买,以及正式的安装文档
  • 文档中心 包括 用户手册、开发人员手册、HOWTO以及通用FAQ文档等,你不能错过

[编辑] 民间组织、社区、个人站点

[编辑] Debian发行版

AIMS Desktop
Mobian
VyOS
Apertis

Debian 衍生发行版

Debian Pure Blends 是为有特定需要的人群提供的一套解决方案

基于 Debian 已经衍生了 400 多个操作系统分发版,其中仍有 120 个还在活跃中,一个真正强大的 OS 生态系统。

主要的 Debian 分发版:

  • Ubuntu: 大家最熟悉
  • AIMS Desktop African Institute for Mathematical Sciences
  • Grml 面向系统管理员的 live 系统
  • Kali Linux: 安全审计和渗透测试
  • PureOS 获得 FSF 认可,专注于隐私、安全和便捷
  • Tails 保护隐私和保持匿名
  • 深度操作系统 基于 Qt 开发了深度桌面环境、深度控制中心和一系列应用。
  • VyOS Open-source router and firewall platform
  • Apertis Collaborative OS platform for products, Production Friendly + Frequent Releases + Developer Ready

[编辑] 项目

  • debos - Debian OS images builder

[编辑] 链接

[编辑] Debian Mirrors

建立 Debian mirror 的脚本, 如:debian-mirror.sh

#!/bin/bash
SRC=rsync://debian.ethz.ch/debian
DST=/var/mirrors/debian/
rsync -vzrltopg --progress --delete $SRC $DST

建立 Debian ISO mirror 脚本,如: debian-iso.sh

#!/bin/bash
SRC=rsync://debian.ethz.ch/debian-cd
DST=/var/mirrors/debian-cd/
rsync -vzrltopg --progress --delete $SRC $DST

更多 Debian Mirrors: http://www.debian.org/mirror/list

[编辑] 开发相关

[编辑] 相关计划

[编辑] 图集

screenshots.debian.net

[编辑] 链接

分享您的观点
个人工具
名字空间

变换
操作
导航
工具箱