1.6. /etc

这是你系统的神经中枢,它包含所有系统相关的配置文件,位于此目录或其子目录中。“配置文件”被定义为用于控制程序操作的本地文件;它必须是静态的,不能是可执行的二进制文件。因此,定期备份此目录是一个好主意。如果您重新安装或丢失当前安装,它绝对可以在以后为您节省大量的重新配置工作。通常,不应该或不在此处放置任何二进制文件。

/etc/X11/

此目录树包含 X Window 系统的所有配置文件。用户应注意,此目录中的许多文件实际上是指向 /usr/X11R6 目录树的符号链接。因此,这些文件是否在此位置存在是不确定的。

/etc/X11/XF86Config, /etc/X11/XF86Config-4

“X”配置文件。大多数现代发行版都拥有硬件自动检测系统,可以自动创建有效的文件。如果自动检测失败,也可以手动创建配置文件,前提是您对系统有足够的了解。从头到尾键入文件被认为是不明智的。相反,应使用常见的配置实用程序(如 xf86config、XF86Setup 和 xf86cfg)来创建可用的模板。然后,使用合适的文档,通过直觉和/或试错法开始优化。可以通过此文件配置的选项包括启动时要加载的 X 模块、键盘、鼠标、显示器和图形芯片组类型。通常,商业发行版会包含自己的 X 配置实用程序,例如 Mandrake 上的 XDrake 和 Redhat 上的 Xconfiguration。以下是参考系统中的 X 配置文件示例

### BEGIN DEBCONF SECTION
# XF86Config-4 (XFree86 server configuration file) generated by dexconf, the
# Debian X Configuration tool, using values from the debconf database.
#
# Edit this file with caution, and see the XF86Config-4 manual page.
# (Type "man XF86Config-4" at the shell prompt.)
#
# If you want your changes to this file preserved by dexconf, only 
# make changes
# before the "### BEGIN DEBCONF SECTION" line above, and/or after the
# "### END DEBCONF SECTION" line below.
#
# To change things within the debconf section, run the command:
#   dpkg-reconfigure xserver-xfree86
# as root.  Also see "How do I add custom sections to a dexconf-
# generated
# XF86Config or XF86Config-4 file?" in /usr/share/doc/xfree86-
# common/FAQ.gz.

Section "Files"
        FontPath        "unix/:7100"                        
# local font server
        # if the local font server has problems, 
# we can fall back on these
        FontPath        "/usr/lib/X11/fonts/misc"
        FontPath        "/usr/lib/X11/fonts/cyrillic"
        FontPath        "/usr/lib/X11/fonts/100dpi/:unscaled"
        FontPath        "/usr/lib/X11/fonts/75dpi/:unscaled"
        FontPath        "/usr/lib/X11/fonts/Type1"
        FontPath        "/usr/lib/X11/fonts/Speedo"
        FontPath        "/usr/lib/X11/fonts/100dpi"
        FontPath        "/usr/lib/X11/fonts/75dpi"
EndSection

Section "Module"
        Load        "GLcore"
        Load        "bitmap"
        Load        "dbe"
        Load        "ddc"
        Load        "dri"
        Load        "extmod"
        Load        "freetype"
        Load        "glx"
        Load        "int10"
        Load        "pex5"
        Load        "record"
        Load        "speedo"
        Load        "type1"
        Load        "vbe"
        Load        "xie"
EndSection

Section "InputDevice"
        Identifier        "Generic Keyboard"
        Driver                "keyboard"
        Option                "CoreKeyboard"
        Option                "XkbRules"        "xfree86"
        Option                "XkbModel"        "pc104"
        Option                "XkbLayout"        "us"
EndSection

Section "InputDevice"
        Identifier        "Configured Mouse"
        Driver                "mouse"
        Option                "CorePointer"
        Option                "Device"                "/dev/psaux"
        Option                "Protocol"                "NetMousePS/2"
        Option                "Emulate3Buttons"        "true"
        Option                "ZAxisMapping"                "4 5"
EndSection

Section "InputDevice"
        Identifier        "Generic Mouse"
        Driver                "mouse"
        Option                "SendCoreEvents"        "true"
        Option                "Device"                "/dev/input/mice"
        Option                "Protocol"                "ImPS/2"
        Option                "Emulate3Buttons"        "true"
        Option                "ZAxisMapping"                "4 5"
EndSection

Section "Device"
        Identifier        "Generic Video Card"
        Driver                "nv"
#        Option                "UseFBDev"                "true"
        Option                "UseFBDev"                "false"
EndSection

Section "Monitor"
        Identifier        "Generic Monitor"
        HorizSync        30-38
        VertRefresh        43-95
        Option                "DPMS"
EndSection

Section "Screen"
        Identifier        "Default Screen"
        Device                "Generic Video Card"
        Monitor                "Generic Monitor"
        DefaultDepth        16
        SubSection "Display"
                Depth                1
                Modes                "800x600" "640x480"
        EndSubSection
        SubSection "Display"
                Depth                4
                Modes                "800x600" "640x480"
        EndSubSection
        SubSection "Display"
                Depth                8
                Modes                "800x600" "640x480"
        EndSubSection
        SubSection "Display"
                Depth                15
                Modes                "800x600" "640x480"
        EndSubSection
        SubSection "Display"
                Depth                16
                Modes                "800x600" "640x480"
        EndSubSection
        SubSection "Display"
                Depth                24
                Modes                "800x600" "640x480"
        EndSubSection
EndSection

Section "ServerLayout"
        Identifier        "Default Layout"
        Screen                "Default Screen"
        InputDevice        "Generic Keyboard"
        InputDevice        "Configured Mouse"
        InputDevice        "Generic Mouse"
EndSection

Section "DRI"
        Mode        0666
EndSection

### END DEBCONF SECTION

如您所见,文件的布局非常简单,并且在大多数发行版中都相当标准。顶部是 X 的各种字体文件的位置(注意 - 如果您不指定有效的字体,X 将无法启动),接下来是“Modules”部分。它详细说明了启动时要加载哪些模块。最著名的扩展可能是 GLX(3D 图形和游戏渲染所需)和 Xinerama,它允许用户将桌面扩展到多个显示器上。接下来是描述您拥有的硬件类型的各种“Device”部分。这些子部分的配置不当可能会导致痛苦和折磨,例如按键错位、鼠标失灵以及 X 尝试在有时永无止境的循环中重新启动时不断闪烁。在大多数情况下,当所有其他方法都失败时,vesa 驱动程序似乎能够初始化大多数现代显卡。在“Screen”部分中,可以更改默认启动分辨率和颜色深度。通常,可以使用 alt-ctrl-+ 或 alt-ctrl- 组合键即时更改这些属性。最后是“ServerLayout”和“DRI”部分。用户几乎永远不会接触“DRI”部分,只有那些希望使用 Xinerama 扩展的用户才需要更改任何 ServerLayout 选项。

/etc/X11/Xmodmap

通常,您的默认键盘映射来自您的 X 服务器设置。如果此设置不足,并且您不希望经历重新配置的过程,和/或您不是超级用户,则需要使用 xmodmap 程序。这是该实用程序的全局配置文件。

/etc/X11/xkb/

X 服务器支持的各种符号、类型、键盘布局的几何图形都可以在此目录树中找到。

/etc/X11/lbxproxy/

低带宽 X (LBX) 代理服务器配置文件。希望利用 X 的低带宽扩展 (LBX) 的应用程序必须将其连接到 lbxproxy。这些应用程序无需了解任何关于 LBX 的信息,它们只需连接到 lbxproxy,就好像它是一个普通的 X 服务器一样。lbxproxy 接受客户端连接,将它们多路复用到与 X 服务器的单个连接上,并对 X 协议执行各种优化,使其在低带宽和/或高延迟连接上更快。应该注意的是,这种压缩不会大大提高渲染速度。其主要目的是减少网络负载,从而减少整体网络延迟。一个名为 DXPC(差分 X 协议压缩)的竞争项目已被发现在这项任务上更有效率。研究表明,在几乎所有情况下,X 的 ssh 隧道都会产生比任何这些专用软件更好的结果。

/etc/X11/proxymngr/

X 代理服务管理器初始化文件。proxymngr 负责解析来自 xfindproxy(在 xbase-clients 包中)和其他类似客户端的请求,在适当的时候启动新的代理,并跟踪所有可用的代理服务。

/etc/X11/xdm/

X 显示管理器配置文件。xdm 管理一组 X 服务器,这些服务器可能位于本地主机或远程机器上。它提供的服务类似于基于字符的终端上的 init、getty 和 login 提供的服务:提示输入登录名和密码、验证用户身份以及运行会话。xdm 支持 XDMCP(X 显示管理器控制协议),也可以用于运行选择器进程,该进程向用户呈现一个提供 XDMCP 显示管理的主机菜单。如果安装了 xutils 包,xdm 可以使用 sessreg 实用程序将登录会话注册到系统 utmp 文件;但是,这对于 xdm 的功能来说不是必需的。

/etc/X11/xdm/xdm-config

这是主要的“xdm”配置文件。它确定所有其他“xdm”配置文件的位置。它几乎肯定不会被打扰。

/etc/X11/gdm/

GNOME 显示管理器配置文件。gdm 为 X 显示提供等效于“login:”提示符的功能——它弹出一个登录窗口并启动一个 X 会话。它提供 xdm 的所有功能,包括用于管理远程显示器的 XDMCP 支持。问候窗口是使用 GNOME 库编写的,因此看起来像一个 GNOME 应用程序——甚至支持主题!默认情况下,出于安全考虑,问候程序以非特权用户身份运行。

/etc/X11/gdm/gdm.conf

这是 GDM 的主要配置文件。通过它,用户可以指定他们是否希望系统自动以特定用户身份登录、背景启动图像,以及他们是否希望通过使用 XDMCP 协议将他们的机器作为某种终端服务器运行。

/etc/X11/fonts

xfs 字体的家目录。

/etc/X11/fs/

X 字体服务器配置文件。xfs 是一个守护进程,它监听网络端口并为 X 服务器(以及 X 客户端)提供 X 字体。所有 X 服务器都能够为自己提供本地安装的字体,但 xfs 使将这项工作从 X 服务器卸载成为可能,和/或在运行 xfs 的联网机器上拥有一个中央字体存储库,以便网络上运行 X 服务器的所有机器都不需要自己的字体集。用户也可以调用 xfs,例如,使用户帐户中不可用于 X 服务器或已运行的系统 xfs 的 X 字体可用。

/etc/X11/fs/config

这是“xfs”初始化文件。它指定允许在任何给定时间连接到“xfs”服务器的客户端数量、日志文件的位置、默认分辨率、字体的位置等。

	
# font server configuration file
# $Xorg: config.cpp,v 1.3 2000/08/17 19:54:19 cpqbld Exp $

# allow a maximum of 10 clients to connect to this font server
client-limit = 10
# when a font server reaches its limit, start up a new one
clone-self = on
# log messages to /var/log/xfs.log (if syslog is not used)
error-file = /var/log/xfs.log
# log errors using syslog
use-syslog = on
# turn off TCP port listening (Unix domain connections are still permitted)
no-listen = tcp
# paths to search for fonts
catalogue = /usr/lib/X11/fonts/misc/,/usr/lib/X11/fonts/cyrillic/,
/usr/lib/X11/fonts/100dpi/:unscaled,/usr/lib/X11/fonts/75dpi/:unscaled,
/usr/lib/X11/fonts/Type1/,/usr/lib/X11/fonts/CID,
/usr/lib/X11/fonts/Speedo/,/usr/lib/X11/fonts/100dpi/,
/usr/lib/X11/fonts/75dpi/
# in decipoints
default-point-size = 120
# x1,y1,x2,y2,...
default-resolutions = 100,100,75,75

# font cache control, specified in kB
cache-hi-mark = 2048
cache-low-mark = 1433
cache-balance = 70

/etc/X11/twm

twm 配置文件的家目录。最初的选项卡式窗口管理器。

/etc/X11/xinit/

xinit 配置文件。“xinit”是一种启动 X 会话的配置方法,旨在用作脚本的一部分。通常,这在较大的站点中用作定制登录过程的一部分。

/etc/X11/xinit/xinitrc

全局 xinitrc 文件,由 xinit (startx) 启动的所有 X 会话使用。当然,它的使用会被用户主目录中的 .xinitrc 文件覆盖。

/etc/adduser.conf

“adduser”配置。adduser 命令可以创建新用户、组,并将现有用户添加到现有组。使用 adduser 添加用户比手动添加用户容易得多。Adduser 将选择合适的 UID 和 GID 值,创建主目录,从 /etc/skel 复制骨架用户配置,允许您设置初始密码和 GECOS 字段。可选地,可以在这些命令之后执行自定义脚本。有关完整文档,请参阅 adduser(8) 和 adduser.conf(5)。

/etc/adjtime

包含参数以帮助调整软件(内核)时间,使其与 RTC 匹配。

/etc/aliases

这是别名文件 - 它说明了谁为谁接收邮件。它最初由“eximconfig”(Debian 发行版附带的 exim 包的一部分)生成,但可以由邮件系统管理员编辑。有关此处可以配置的内容的详细信息,请参阅 exim 信息部分。别名数据库文件 (aliases.db) 是由 newaliases 实用程序从别名文件中的条目构建的。

/etc/alternatives

单个系统上可以同时安装多个执行相同或相似功能的程序。例如,许多系统同时安装了多个文本编辑器。这为系统的用户提供了选择,允许每个人使用不同的编辑器(如果需要),但如果用户没有指定特定的偏好,程序很难选择合适的编辑器来调用。

备用系统旨在解决此问题。文件系统中一个通用名称由所有提供可互换功能的文件共享。备用系统和系统管理员共同确定此通用名称引用的实际文件。例如,如果系统上同时安装了文本编辑器 ed(1) 和 nvi(1),则备用系统将使通用名称 /usr/bin/editor 默认引用 /usr/bin/nvi。系统管理员可以覆盖此设置,使其引用 /usr/bin/ed,并且在明确要求这样做之前,备用系统不会更改此设置。

通用名称不是指向所选备用项的直接符号链接。相反,它是指向备用目录中名称的符号链接,而备用目录中的名称又是指向所引用实际文件的符号链接。这样做是为了使系统管理员的更改可以限制在 /etc 目录中。

/etc/apt

这是 Debian 的下一代 dpkg 包管理器的前端。它提供了 apt-get 实用程序和 APT dselect 方法,提供了一种更简单、更安全的方式来安装和升级软件包。APT 具有完整的安装顺序、多源功能和一些其他独特的功能,请参阅 /usr/share/doc/apt/guide.text.gz 中的用户指南

/etc/apt/sources.list

deb cdrom:[Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-7 (20020718)]/
          unstable contrib main non-US/contrib non-US/main
deb cdrom:[Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-6 (20020718)]/
          unstable contrib main non-US/contrib non-US/main
deb cdrom:[Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-5 (20020718)]/
          unstable contrib main non-US/contrib non-US/main
deb cdrom:[Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-4 (20020718)]/
          unstable contrib main non-US/contrib non-US/main
deb cdrom:[Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-3 (20020718)]/ 
          unstable contrib main non-US/contrib non-US/main
deb cdrom:[Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-2 (20020718)]/ 
          unstable contrib main non-US/contrib non-US/main
deb cdrom:[Debian GNU/Linux 3.0 r0 _Woody_ - Official i386 Binary-1 (20020718)]/ 
          unstable contrib main non-US/contrib non-US/main

# deb http://security.debian.org/ stable/updates main

包含 apt 源列表,可以通过 APT 从中安装软件包。

/etc/asound.conf

ALSA(高级 Linux 声音架构)配置文件。它通常通过 alsactl 或其他第三方声音配置实用程序创建,这些实用程序可能特定于发行版,例如 Redhat 的 sndconfig。

/etc/at.deny

拒绝访问 at 守护进程的用户。“at”命令允许用户在任意时间执行程序。

/etc/autoconf

autoconf 的配置文件。“autoconf”创建脚本以使用模板配置源代码包。要从 configure.in 创建 configure,请在不带参数的情况下运行 autoconf 程序。autoconf 使用 m4 宏处理器处理 configure.ac,使用 Autoconf 宏。如果您为 autoconf 提供参数,它将读取该文件而不是 configure.ac,并将配置脚本写入标准输出而不是 configure。如果您为 autoconf 提供参数 -,它将读取标准输入而不是 configure.ac,并将配置脚本写入标准输出。

Autoconf 宏在多个文件中定义。一些文件与 Autoconf 一起分发;autoconf 首先读取它们。然后,它在包含分发的 Autoconf 宏文件的目录中查找可选文件 acsite.m4,并在当前目录中查找可选文件 aclocal.m4。这些文件可以包含您的站点或包自己的 Autoconf 宏定义。如果宏在 autoconf 读取的多个文件中定义,则它读取的最后一个定义将覆盖较早的定义。

/etc/bash.bashrc

交互式 bash shell 的系统范围的函数和别名文件。

/etc/bash_completion

bash 2.05a 的可编程补全函数。

/etc/chatscripts/provider

这是用于拨号连接到您的默认服务提供商的 chat 脚本。

/etc/cron.d, /etc/cron.daily, /etc/cron.weekly, /etc/cron.monthly

这些目录包含 cron 守护程序定期执行的脚本。

/etc/crontab

“cron”配置文件。此文件用于 cron 表,以设置系统例程的自动运行。也可以为单个用户建立 cron 表。用户 cron 表文件的位置将在稍后解释。

# /etc/crontab: system-wide crontab
# Unlike any other crontab you don't have to run the `crontab'
# command to install the new version when you edit this file.
# This file also has a username field, that none of the other crontabs do.

SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin

# m h dom mon dow user command
25 6 * * * root test -e /usr/sbin/anacron || run-parts --report /etc/cron.daily
47 6 * * 7 root test -e /usr/sbin/anacron || run-parts --report /etc/cron.weekly
52 6 1 * * root test -e /usr/sbin/anacron || run-parts --report /etc/cron.monthly
#

/etc/csh.login

csh(1) 的系统范围的 .login 文件。此文件在 shell 的所有调用中都被源化。它包含登录时要执行的命令,有时也包含别名。

/etc/csh.logout

csh(1) 的系统范围的 .logout 文件。此文件在 shell 的所有调用中都被源化。它包含注销时要执行的命令。

/etc/csh.cshrc

csh(1) 的系统范围的 .cshrc 文件。此文件在 shell 的所有调用中都被源化。此文件应包含设置命令搜索路径以及其他重要环境变量的命令。此文件不应包含产生输出或假定 shell 连接到 tty 的命令。

/etc/cups

通用 UNIX 打印系统 (CUPS) 的配置文件。此处的文件用于定义特定于客户端的参数,例如默认服务器或默认加密设置。

/etc/deluser.conf

“deluser”配置文件。deluser 命令可以删除用户和组,并将用户从给定组中删除。Deluser 可以选择删除和备份用户的主目录和邮件池,或系统上他拥有的所有文件。可选地,也可以在每个命令之后执行自定义脚本。

/etc/devfs

此守护程序设置 /dev 文件系统以供使用。它在 /dev 中创建所需的符号链接,并且还创建(如果已配置,默认情况下是这样)指向设备“旧”名称的符号链接。

/etc/devfs/conf.d/

“devfsd”配置文件。此守护程序设置 /dev 文件系统以供使用。它在 /dev 中创建所需的符号链接,并且还创建(如果已配置,默认情况下是这样)指向设备“旧”名称的符号链接。

/etc/dhclient.conf, /etc/dhclient-script

分别为“dhclient”配置文件和“dhclient”脚本文件。它配置您的系统,使其可以在基于 DHCP 的网络上充当客户端。如今,连接到互联网至关重要。

/etc/dict.conf

#  /etc/dict.conf Written by Bob Hilliard <hilliard@debian.org>
#  1998/03/20.  Last revised Sun, 22 Nov 1998 18:10:04 -0500 This is
#  the configuration file for /usr/bin/dict.  In most cases only the
#  server keyword need be specified.  

#  This default configuration will try to access a dictd server on
#  the local host, failing that, it will try the public server.  In
#  many cases this will be slow, so you should comment out the line 
#  for the server that you don't want to use. To use any other 
#  server, enter its IP address in place of "dict.org".  

#  Refer to the dict manpage (man dict) for other options that could
#  be inserted in here.

server localhost 
server dict.org

dict 是字典服务器协议 (DICT) 的客户端,DICT 是一种基于 TCP 事务的查询/响应协议,它提供对一组自然语言字典数据库的字典定义的访问。

/etc/dosemu.conf

Linux DOS 模拟器的配置文件。DOSEMU 是一个 PC 模拟器应用程序,它允许 Linux 在虚拟 x86 机器中运行 DOS 操作系统。这允许您运行许多 DOS 应用程序。它包括 FreeDOS 内核、彩色文本和通过终端的完整键盘模拟(通过热键)、内置 X 支持、IBM 字符集字体、控制台图形功能(使用大多数兼容的显卡)、DPMI 支持(因此您可以运行 DOOM)、CDROM 支持、内置 IPX 和 pktdrvr 支持。注意 - “dosemu”只是 Corel 自己的 PC-DOS 的移植版本。

/etc/email-addresses

exim 包的一部分。此文件包含用于传出邮件的电子邮件地址。此处没有的任何本地部分将像往常一样由系统域限定。它应包含以下形式的行

  user: someone@isp.com
  otheruser: someoneelse@anotherisp.com
  

Exim 是一个 MTA,它被认为比 smail 或 sendmail 更容易配置。它是 sendmail、mailq 和 rsmtp 的直接替代品。高级功能包括拒绝来自已知垃圾邮件站点的连接的能力,以及极其高效的队列处理算法。

/etc/esound.conf

ESD 配置文件。Enlightened 声音守护程序旨在将多个数字音频流混合在一起,以便单个设备播放。与 nasd、artsd 和 rplay 类似,它也具有远程播放声音的功能。

/etc/exports

希望通过 NFS 访问系统的系统控制列表,以及您希望共享的目录列表以及每个共享上分配的权限。

  # /etc/exports: the access control list for filesystems which may be
  # exported to NFS clients.  See exports(5).
  ## LTS-begin ##

  #
  # The lines between the 'LTS-begin' and the 'LTS-end' were added
  # on: Sun Feb 23 05:54:17 EST 2003 by the ltsp installation script.
  # For more information, visit the ltsp homepage
  # at http://www.ltsp.org
  #

  /opt/ltsp/i386                  192.168.0.0/255.255.255.0(ro,no_root_squash)
  /var/opt/ltsp/swapfiles         192.168.0.0/255.255.255.0(rw,no_root_squash)

  #
  # The following entries need to be uncommented if you want
  # Local App support in ltsp
  #
  #/home                  192.168.0.0/255.255.255.0(rw,no_root_squash)

  ## LTS-end ##

/etc/fdprm

软盘参数表。描述不同的软盘格式是什么样的。由 setfdprm 使用。

/etc/fstab

“mount”和现在的“supermount”的配置文件。它列出了由 mount -a 命令(在 /etc/rc 或等效的启动文件中)在启动时自动挂载的文件系统。在 Linux 下,还包含有关 swapon -a 自动使用的交换区域的信息。

  # /etc/fstab: static file system information.
  #
  # The following is an example. Please see fstab(5) for further details.
  # Please refer to mount(1) for a complete description of mount options.
  #
  # Format:
  # <file system> <mount point> <type> <options> <dump> <pass>
  #
  # dump(8) uses the <dump> field to determine which file systems need
  # to be dumped. fsck(8) uses the <pass> column to determine which file
  # systems need to be checked--the root file system should have a 1 in 
  # this field, other file systems a 2, and any file systems that should
  # not be checked (such as MS-DOS or NFS file systems) a 0.
  #
  # The `sw' option indicates that the swap partition is to be activated
  # with `swapon -a'.
  /dev/hda2 none swap sw 0 0
  # The `bsdgroups' option indicates that the file system is to be mounted
  # with BSD semantics (files inherit the group ownership of the directory
  # in which they live). `ro' can be used to mount a file system read-only.
  /dev/hda3 / ext2 defaults 0 1 
  /dev/hda5 /home ext2 defaults 0 2
  /dev/hda6 /var ext2 defaults 0 2
  /dev/hda7 /usr ext2 defaults,ro 0 2
  /dev/hda8 /usr/local ext2 defaults,bsdgroups 0 2
  # The `noauto' option indicates that the file system should not be mounted
  # with `mount -a'. `user' indicates that normal users are allowed to mount
  # the file system.
  /dev/cdrom /cdrom iso9660 defaults,noauto,ro,user 0 0
  /dev/fd0 /floppy minix defaults,noauto,user 0 0
  /dev/fd1 /floppy minix defaults,noauto,user 0 0
  # NFS file systems: server:
  /export/usr /usr nfs defaults 0 0
  # proc file system:
  proc /proc proc defaults 0 0
  

/etc/ftpaccess

确定谁可以获得对您机器的 ftp 访问权限。

/etc/ftpchroot

需要 chroot 的 ftp 用户列表。

/etc/ftpuser

不允许的 ftp 用户列表。

/etc/gateways

列出“routed”的网关。

/etc/gettydefs

配置控制台登录。

/etc/gnome-vfs-mime-magic

Gnome VFS 库使用的 MIME magic 模式。

/etc/group

类似于 /etc/passwd。它列出了配置的用户组以及谁属于这些组。

/etc/group-

旧的 /etc/group 文件。

/etc/gshadow

包含组密码的加密形式。

/etc/gshadow-

旧的 /etc/gshadow 文件。

/etc/hostname

包含您机器的主机名(可以是完全限定的,也可以不是)。

/etc/host.conf

确定查找的搜索顺序(通常是 hosts bind,即“首先检查 /etc/hosts,然后查找 DNS”)。

/etc/hosts

此文件用于定义具有特定 IP 地址的系统名称和域组合。如果机器连接到网络,则此文件始终需要包含 IP 地址的条目。

  ### etherconf DEBCONF AREA. DO NOT EDIT THIS AREA OR INSERT TEXT BEFORE IT.
  127.0.0.1 localhost ::1 localhost
  ip6-localhost ip6-loopback
  fe00::0 ip6-localnet
  ff00::0 ip6-mcastprefix
  ff02::1 ip6-allnodes
  ff02::2 ip6-allrouters
  ff02::3 ip6-allhosts
  192.168.0.99 debian.localdomain.com debian
  ### END OF DEBCONF AREA. PLACE YOUR EDITS BELOW; THEY WILL BE PRESERVED.
  192.168.0.1 ws001
  

/etc/hosts.allow

tcp-wrappers 系统的一部分,用于控制对您机器服务的访问。它列出了允许访问系统和特定守护程序的主机。

  # /etc/hosts.allow: list of hosts that are allowed to access the
  # system.
  # See the manual pages hosts_access(5), hosts_options(5)
  # and /usr/doc/netbase/portmapper.txt.gz
  #
  # Example: ALL: LOCAL @some_netgroup
  # ALL: .foobar.edu EXCEPT terminalserver.foobar.edu
  #
  # If you're going to protect the portmapper use the name "portmap"
  # for the daemon name. Remember that you can only use the keyword
  # "ALL" and IP addresses (NOT host or domain names) for the
  # portmapper. See portmap(8) and /usr/doc/portmap/portmapper.txt.gz
  # for further information.
  bootpd: 0.0.0.0 in.tftpd: 192.168.0.
  portmap: 192.168.0.
  rpc.mountd: 192.168.0.
  rpc.nfsd: 192.168.0.
  gdm: 192.168.0.
  nasd: 192.168.0.
  

/etc/hosts.deny

tcp-wrappers 系统的一部分,用于控制对您机器服务的访问。它列出了不允许访问系统的主机。

  # Example: ALL: some.host.name, .some.domain
  # ALL EXCEPT in.fingerd: other.host.name, .other.domain
  #
  # If you're going to protect the portmapper use the name "portmap"
  # for the daemon name. Remember that you can only use the keyword
  # "ALL" and IP addresses (NOT host or domain names) for the
  # portmapper. See portmap(8) and /usr/doc/portmap/portmapper.txt.gz
  # for further information.
  #
  # The PARANOID wildcard matches any host whose name does not match
  # its address. You may wish to enable this to ensure any programs
  # that don't validate looked up hostnames still leave understandable
  # logs. In past versions of Debian this has been the default.
  # ALL: PARANOID
  

/etc/httpd

Apache 配置文件。Apache 是一款功能强大、高性能的 HTTP 服务器。作为世界上最受欢迎的服务器,Apache 具有模块化设计,并支持在运行时动态选择扩展模块。它的优点在于其可能的定制范围、服务器进程数量的动态调整以及各种可用的模块,包括许多身份验证机制、服务器解析的 HTML、服务器端包含、访问控制、CERN httpd 元文件模拟、代理缓存等。Apache 还支持多个虚拟主机。

/etc/identd.conf

TCP/IP IDENT 协议服务器。它实现了 TCP/IP 建议的标准 IDENT 用户身份识别协议 (RFC 1413)。identd 通过查找特定的 TCP/IP 连接并返回拥有该连接的进程的用户名来操作。它还可以返回用户名以外的其他信息。

  # /etc/identd.conf - an example configuration file


  #-- The syslog facility for error messages
  # syslog:facility = daemon


  #-- User and group (from passwd database) to run as
  server:user = nobody

  #-- Override the group id
  # server:group = kmem

  #-- What port to listen on when started as a daemon or from /etc/inittab
  # server:port = 113

  #-- The socket backlog limit
  # server:backlog = 256

  #-- Where to write the file containing our process id
  # server:pid-file = "/var/run/identd/identd.pid"

  #-- Maximum number of concurrent requests allowed (0 = unlimited)
  # server:max-requests = 0

  #-- Enable some protocol extensions like "VERSION" or "QUIT"
  protocol:extensions = enabled

  #-- Allow multiple queries per connection
  protocol:multiquery = enabled

  #-- Timeout in seconds since connection or last query. Zero = disable
  # protocol:timeout = 120

  #-- Maximum number of threads doing kernel lookups
  # kernel:threads = 8

  #-- Maximum number of queued kernel lookup requests
  # kernel:buffers = 32

  #-- Maximum number of time to retry a kernel lookup in case of failure
  # kernel:attempts = 5



  #-- Disable username lookups (only return uid numbers)
  # result:uid-only = no

  #-- Enable the ".noident" file
  # result:noident = enabled

  #-- Charset token to return in replies
  # result:charset = "US-ASCII"

  #-- Opsys token to return in replies
  # result:opsys = "UNIX"

  #-- Log all request replies to syslog (none == don't)
  # result:syslog-level = none


  #-- Enable encryption (only available if linked with a DES library)
  # result:encrypt = no

  #-- Path to the DES key file (only available if linked with a DES library)
  # encrypt:key-file = "/usr/local/etc/identd.key"


  #-- Include a machine local configuration file
  # include = /etc/identd.conf
  

/etc/inetd.conf

由 INETD TCP/IP 超级服务器启动的服务的配置。“inetd”现在已弃用。“xinetd”已取而代之。有关更多详细信息,请参阅 /etc/xinet.conf。

  # /etc/inetd.conf:  see inetd(8) for further information.
  #
  # Internet server configuration database
  #
  #
  # Lines starting with "#:LABEL:" or "#<off>#" should not
  # be changed unless you know what you are doing!
  #
  # If you want to disable an entry so it isn't touched during
  # package updates just comment it out with a single '#' character.
  #
  # Packages should modify this file by using update-inetd(8)
  #
  # <service_name> <sock_type> <proto> 
  # <flags> <user> <server_path>
  # <args>
  #
  #:INTERNAL: Internal services
  #echo	stream	tcp nowait root	internal
  #echo	dgram	udp wait root internal
  #chargen stream tcp	nowait root internal
  #chargen dgram udp	wait root internal
  discard stream tcp nowait root internal
  discard dgram	udp wait root internal
  daytime stream tcp nowait root internal
  #daytime dgram udp wait root internal
  time stream tcp nowait root internal
  #time dgram udp wait root internal

  #:STANDARD: These are standard services.
  ftp stream tcp nowait	root /usr/sbin/tcpd /usr/sbin/in.ftpd	
  telnet stream	tcp nowait telnetd.telnetd /usr/sbin/tcpd 
                                           /usr/sbin/in.telnetd

  #:MAIL: Mail, news and uucp services.
  smtp stream tcp nowait mail /usr/sbin/exim exim -bs
  imap2  stream  tcp nowait root /usr/sbin/tcpd /usr/sbin/imapd
  imap3  stream  tcp nowait root /usr/sbin/tcpd /usr/sbin/imapd

  #:INFO: Info services
  ident	stream tcp wait	identd /usr/sbin/identd	identd
  finger stream	tcp nowait nobody /usr/sbin/tcpd 
                                  /usr/sbin/in.fingerd

  #:BOOT: Tftp service is provided primarily for booting.  
  #Most sites run this only on machines acting as "boot servers."
  tftp dgram udp wait nobody /usr/sbin/tcpd 
                             /usr/sbin/in.tftpd -s /tftpboot
  

/etc/init.d

Order of scripts run in /etc/rc?.d
==================================

0. Overview.

   All scripts executed by the init system are located in /etc/init.d.
   The directories /etc/rc?.d (? = S, 0 .. 6) contain relative links to
   those scripts. These links are named S<2-digit-number><
   original-name> or K<2-digit-number><original-name>.

   If a scripts has the ".sh" suffix it is a bourne shell script and
   MAY be handled in an optimized manner. The behaviour of executing the
   script in an optimized way will not differ in any way from it being
   forked and executed in the regular way.

   The following runlevels are defined:

   N       System bootup (NONE).
   S       Single user mode (not to be switched to directly)
   0       halt
   1       single user mode
   2 .. 5  multi user mode
   6       reboot

1. Boot.

   When the systems boots, the /etc/init.d/rcS script is executed. It
   in turn executes all the S* scripts in /etc/rcS.d in alphabetical
   (and thus numerical) order. The first argument passed to the
   executed scripts is "start". The runlevel at this point is
   "N" (none).

   Only things that need to be run once to get the system in a consistent
   state are to be run. The rcS.d directory is NOT meant to replace rc.local.
   One should not start daemons in this runlevel unless absolutely
   necessary. Eg, NFS might need the portmapper, so it is OK to start it
   early in the boot process. But this is not the time to start the
   squid proxy server.

2. Going multiuser.

   After the rcS.d scripts have been executed, init switches to the
   default runlevel as specified in /etc/inittab, usually "2".

   Init then executes the /etc/init.d/rc script which takes care of
   starting the services in /etc/rc2.d.

   Because the previous runlevel is "N" (none) the /etc/rc2.d/KXXxxxx
   scripts will NOT be executed - there is nothing to stop yet,
   the system is busy coming up.

   If for example there is a service that wants to run in runlevel 4
   and ONLY in that level, it will place a KXXxxxx script in
   /etc/rc{2,3,5}.d to stop the service when switching out of runlevel 4.
   We do not need to run that script at this point.
   
   The /etc.rc2.d/SXXxxxx scripts will be executed in alphabetical
   order, with the first argument set to "start".

3. Switching runlevels.

   When one switches from (for example) runlevel 2 to runlevel 3,
   /etc/init.d/rc will first execute in alphabetical order all K
   scripts for runlevel 3 (/etc/rc3.d/KXXxxxx) with as first argument
   "stop" and then all S scripts for runlevel 3 (/etc/rc3.d/SXXxxxx)
   with as first argument "start".

   As an optimization, a check is made for each "service" to see if
   it was already running in the previous runlevel. If it was, and there
   is no K (stop) script present for it in the new runlevel, there is
   no need to start it a second time so that will not be done.

   On the other hand, if there was a K script present, it is assumed the
   service was stopped on purpose first and so needs to be restarted.

   We MIGHT make the same optimization for stop scripts as well-
   if no S script was present in the previous runlevel, we can assume
   that service was not running and we don't need to stop it either.
   In that case we can remove the "coming from level N" special case
   mentioned above in 2). But right now that has not been implemented.

4. Single user mode.

   Switching to single user mode is done by switching to runlevel 1.
   That will cause all services to be stopped (assuming they all have
   a K script in /etc/rc1.d). The runlevel 1 scripts will then switch
   to runlevel "S" which has no scripts - all it does is spawn
   a shell directly on /dev/console for maintenance.

5. Halt/reboot

   Going to runlevel 0 or 6 will cause the system to be halted or rebooted,
   respectively. For example, if we go to runlevel 6 (reboot) first
   all /etc/rc6.d/KXXxxxx scripts will be executed alphabetically with
   "stop" as the first argument.

   Then the /etc/rc6.d/SXXxxxx scripts will be executed alphabetically
   with "stop" as the first argument as well. The reason is that there
   is nothing to start any more at this point - all scripts that are
   run are meant to bring the system down.

   In the future, the /etc/rc6.d/SXXxxxx scripts MIGHT be moved to
   /etc/rc6.d/K1XXxxxx for clarity.

/etc/inittab

启动时系统配置/初始化脚本。告诉 init 如何处理运行级别。它设置默认运行级别。这是第一个运行的,除非在紧急 (-b) 模式下启动。它还允许用户在外部设备(如串行端口)上启动 getty 会话。要向系统添加终端或拨入调制解调器线路,只需向 /etc/inittab 添加更多行,每行对应一个终端或拨入线路。有关更多详细信息,请参阅手册页 init、inittab 和 getty。如果命令在启动时失败,并且 init 配置为重新启动它,它将使用大量系统资源:init 启动它,它失败,init 启动它,它失败,依此类推。为了防止这种情况,init 将跟踪它重新启动命令的频率,如果频率变得太高,它将在再次重新启动之前延迟五分钟。/etc/inittab 还具有一些特殊功能,允许 init 对特殊情况做出反应。powerwait 允许 init 在电源故障时关闭系统。这假设使用了 UPS 和监视 UPS 并通知 init 电源已关闭的软件。ctrlaltdel 允许 init 在用户在控制台键盘上按下 ctrl-alt-del 时重新启动系统。请注意,系统管理员可以将对 ctrl-alt-del 的反应配置为其他内容,例如,如果系统位于公共场所,则忽略它。sysinit 系统启动时要运行的命令。例如,此命令通常会清理 /tmp。上面的列表并非详尽无遗。有关所有可能性以及如何使用上面的列表的详细信息,请参阅您的 inittab 手册页。设置(或重置)初始终端颜色。以下 shell 脚本应该适用于 VGA 控制台:for n in 1 2 4 5 6 7 8; do setterm -fore yellow -bold on -back blue -store > /dev/tty$n done 替换您喜欢的颜色,并将 /dev/ttyS$n 用于串行终端。为了确保在人们注销时重置它们(如果它们已被更改),请将 /etc/inittab 中对 getty(或 mingetty 或 uugetty 或其他任何内容)的引用替换为对 /sbin/mygetty 的引用。#!/bin/sh setterm -fore yellow -bold on -back blue -store > $1 exec /sbin/mingetty $@ 下面提供了一个 /etc/inittab 示例。

  # /etc/inittab: init(8) configuration.
  # $Id: etc.xml,v 1.10 2004/02/03 21:42:57 binh Exp $
  # The default runlevel. id:2:initdefault:
  # Boot-time system configuration/initialization script.
  # This is run first except when booting in emergency (-b) mode.
  si::sysinit:/etc/init.d/rcS
  # What to do in single-user mode.
  ~~:S:wait:/sbin/sulogin
  # /etc/init.d executes the S and K scripts upon change
  # of runlevel.
  #
  # Runlevel 0 is halt.
  # Runlevel 1 is single-user.
  # Runlevels 2-5 are multi-user.
  # Runlevel 6 is reboot.
  l0:0:wait:/etc/init.d/rc 0 l1:1:wait:/etc/init.d/rc 1
  l2:2:wait:/etc/init.d/rc 2 l3:3:wait:/etc/init.d/rc 3
  l4:4:wait:/etc/init.d/rc 4 l5:5:wait:/etc/init.d/rc 5
  l6:6:wait:/etc/init.d/rc 6
  # Normally not reached, but fallthrough in case of emergency.
  z6:6:respawn:/sbin/sulogin
  # What to do when CTRL-ALT-DEL is pressed.
  ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now
  # Action on special keypress (ALT-UpArrow).
  #kb::kbrequest:/bin/echo "Keyboard Request
  #--edit /etc/inittab to let this work."
  # What to do when the power fails/returns.
  pf::powerwait:/etc/init.d/powerfail start
  pn::powerfailnow:/etc/init.d/powerfail now
  po::powerokwait:/etc/init.d/powerfail stop
  # /sbin/getty invocations for the runlevels.
  #
  # The "id" field MUST be the same as the last
  # characters of the device (after "tty").
  #
  # Format:
  # <id>:<runlevels>:<action>:<process>
  #
  # Note that on most Debian systems tty7 is used by the X Window System,
  # so if you want to add more getty's go ahead but skip tty7 if you run X.
  #
  1:2345:respawn:/sbin/getty 38400 tty1 2:23:respawn:/sbin/getty 38400 tty2
  3:23:respawn:/sbin/getty 38400 tty3 4:23:respawn:/sbin/getty 38400 tty4
  5:23:respawn:/sbin/getty 38400 tty5 6:23:respawn:/sbin/getty 38400 tty6
  # Example how to put a getty on a serial line (for a terminal)
  #
  #T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100 
  #T1:23:respawn:/sbin/getty -L ttyS1 9600 vt100
  # Example how to put a getty on a modem line.
  #
  #T3:23:respawn:/sbin/mgetty -x0 -s 57600 ttyS3

  Undocumented features
  
  The letters A-C can be used to spawn a daemon listed in /etc/inittab. For
  example, assuming you want to start getty on a port to receive a call, but
  only after receiving a voice call first (and not all the time). Furthermore,
  you want to be able to receive a data or a fax call and that when you get
  the voice message you'll know which you want. You insert two new lines
  in /etc/inittab, each with its own ID, and each with a runlevel such as A
  for data and B for fax. When you know which you need, you simply spawn the
  appropriate daemon by calling 'telinit A' or 'telinit B'.
  The appropriate getty is put on the line until the first call is received.
  When the caller terminates the connection, the getty drops because, by
  definition, on demand will not respawn. The other two letters, S and Q, are
  special. S brings you system to maintenance mode and is the same as changing
  state to runlevel 1. The Q is used to tell init to reread inittab. The
  /etc/inittab file can be changed as often as required, but will only be read
  under certain circumstances: -One of its processes dies (do you need to
  respawn another?) -On a powerful signal from a power daemon (or a command
  line) -When told to change state by telinit The Q argument tells init to
  reread the /etc/inittab file. Even though it is called the System V runlevel
  system runlevels 7-9 are legitimate runlevels that can be used if necessary.
  The administrator must remember to alter the inittab file though and also to
  create the required rc?.d files.

/etc/inputrc

libreadline 的全局 inputrc。Readline 是一个从用户获取行并自动编辑它的函数。

/etc/isapnp.conf

基于 ISA 的卡的配置文件。此标准在新系统中实际上是多余的。“isapnptools”ISA 即插即用配置实用程序套件用于配置此类设备。这些程序适用于所有系统,无论它们是否包含 PnP BIOS。事实上,PnP BIOS 增加了一些复杂性,因为它可能已经激活了一些卡,以便驱动程序可以找到它们,而这些工具可以取消配置它们,或更改它们的设置,从而导致各种不良影响。

/etc/isdn

ISDN 配置文件。

/etc/issue

getty 在登录提示符之前的输出。通常包含对系统的简短描述或欢迎消息。内容由系统管理员决定。Debian GNU/\s 3.0 \n \l

/etc/issue.net

向远程登录到您机器的用户显示欢迎屏幕(而 /etc/issue 确定本地用户在登录时看到的内容)。Debian GNU/%s 3.0 %h

/etc/kde

KDE 初始化脚本和 KDM 配置。

/etc/kde/kdm

K 桌面管理器文件的位置。kdm 管理一组 X 服务器,这些服务器可能位于本地主机或远程机器上。它提供的服务类似于基于字符的终端上的 init、getty 和 login 提供的服务:提示输入登录名和密码、验证用户身份以及运行会话。kdm 支持 XDMCP(X 显示管理器控制协议),也可以用于运行选择器进程,该进程向用户呈现一个提供 XDMCP 显示管理的主机菜单。

/etc/kderc

系统范围的 KDE 初始化脚本。每次加载 KDE 环境时都会执行此处的命令。它是指向 /etc/kde2/system.kdeglobals 的链接

  [Directories]
  dir_config=/etc/kde2
  dir_html=/usr/share/doc/kde/HTML
  dir_cgi=/usr/lib/cgi-bin
  dir_apps=/usr/share/applnk
  dir_mime=/usr/share/mimelnk
  dir_services=/usr/share/services
  dir_servicetypes=/usr/share/servicetypes
  [General]
  TerminalApplication=x-terminal-emulator
  

/etc/ld.so.conf, /etc/ld.so.cache

/etc/ld.so.conf 是一个文件,其中包含以冒号、空格、制表符、换行符或逗号分隔的目录列表,用于搜索库。/etc/ld.so.cache 包含 /etc/ld.so.conf 中指定的目录中找到的库的有序列表。此文件不是人类可读的格式,也不打算进行编辑。

“ldconfig”创建必要的链接和缓存(供运行时链接器 ld.so 使用),以链接到在命令行、/etc/ld.so.conf 文件以及受信任目录(/usr/lib 和 /lib)中指定的目录中找到的最新共享库。“ldconfig”检查它遇到的库的标头和文件名,以确定哪些版本的链接应该更新。ldconfig 在扫描库时忽略符号链接。

“ldconfig”将尝试根据库链接的 C 库(如果有)来推断 ELF 库的类型(即 libc5 或 libc6/glibc),因此在制作动态库时,明智的做法是显式链接到 libc(使用 -lc)。

一些现有的库没有包含足够的信息来允许推断它们的类型,因此 /etc/ld.so.conf 文件格式允许指定预期类型。这仅用于我们无法解决的那些 ELF 库。格式类似于“dirname=TYPE”,其中 type 可以是 libc4、libc5 或 libc6。(此语法也适用于命令行)。不允许使用空格。另请参阅 -p 选项。

包含 = 的目录名称不再合法,除非它们也具有预期的类型说明符。

“ldconfig”通常应由超级用户运行,因为它可能需要对某些 root 拥有的目录和文件的写入权限。它通常在启动时自动运行,或在安装新的共享库时手动运行。

/usr/X11R6/lib

X 库。

/usr/local/lib

本地库。

/etc/lilo.conf

Linux 引导加载程序“lilo”的配置文件。“lilo”是原始的 OS 加载程序,可以加载 Linux 和其他操作系统。“lilo”包通常包含 lilo(安装程序)和引导记录映像,用于安装 Linux、OS/2、DOS 和其他操作系统的通用引导扇区。您可以使用 Lilo 来管理您的主引导记录(使用简单的文本屏幕、文本菜单或彩色启动图形),或者从其他引导加载程序调用“lilo”以快速启动 Linux 内核。

  Prompt #Prompt user to select
  OS choice at boot timeout=300  # Amount of time to wait before default OS
                                 # started (in ms)
  default=Debian4 #Default OS to be loaded
  vga=normal #VGA mode
  boot=/dev/had #location of MBR
  map=/boot/map #location of kernel
  install=/boot/boot-bmp.b #File to be installed as boot sector
  bitmap=/boot/debian.bmp #LILO boot image 
  bmp-table=30p,100p,1,10 #Colours
  selectable bmp-colors=13,,0,1,,0 #Colours chosen
  lba32 #Required on most new systems to overcome
        #1024 cylinder problem
  image=/vmlinuz #name of kernel
  image label=Debian #a label
  read-only #file system to be mounted read only
  root=/dev/hda6 #location of root filesystem
  
  image=/boot/bzImage
  label=Debian4
  read-only
  root=/dev/hda6

  image=/mnt/redhat/boot/vmlinuz
  label=Redhat
  initrd=/mnt/redhat/boot/initrd-2.4.18-14.img
  read-only
  root=/dev/hda5
  vga=788
  append=" hdc=ide-scsi hdd=ide-scsi"
  
  image=/mnt/mandrake/boot/vmlinuz
  label="Mandrake"
  root=/dev/hda7
  initrd=/mnt/mandrake/boot/initrd.img
  append="devfs=mount hdc=ide-scsi
  acpi=off quiet"
  vga=788
  read-only

  other=/dev/hda2
  table=/dev/hda
  loader=/boot/chain.b
  label=FBSD
  other=/dev/hda1
  label=Windows
  table=/dev/hda
  
  other=/dev/fd0
  label=floppy unsafe
  

/etc/local.gen

此文件列出了您希望构建的区域设置。您可以在 /usr/share/i18n/SUPPORTED 中找到有效的受支持区域设置列表。其他组合是可能的,但可能没有经过充分测试。如果您更改此文件,则需要重新运行 locale-gen。

/etc/locale.alias

区域设置名称别名数据库。

/etc/login.defs

登录包的配置控制定义。可以通过此单个文件更改大量属性,例如邮件的位置、登录失败后的延迟秒数、启用失败日志信息的显示、未知用户名登录失败的显示、shell 环境变量等。

/etc/logrotate.conf

logrotate 实用程序旨在简化在生成大量日志文件的系统上管理日志文件。Logrotate 允许自动轮换、压缩、删除和邮寄日志文件。可以将 Logrotate 设置为每天、每周、每月或当日志文件达到一定大小时处理日志文件。通常,logrotate 作为每日 cron 作业运行。

  # see "man logrotate" for details
  # rotate log files weekly
  weekly

  # keep 4 weeks worth of backlogs
  rotate 4

  # create new (empty) log files after rotating old ones
  create

  # uncomment this if you want your log files compressed
  #compress

  # packages drop log rotation information into this directory
  include /etc/logrotate.d

  # no packages own wtmp, or btmp -- we'll rotate them here
  /var/log/wtmp {
      monthly
      create 0664 root utmp
      rotate 1
  }

  /var/log/btmp {
      missingok
      monthly
      create 0664 root utmp
      rotate 1
  }

  # system-specific logs may be configured here

/etc/ltrace.conf

ltrace(库调用跟踪器)的配置文件。它跟踪动态链接程序中的运行时库调用。“ltrace”是一个调试程序,它运行指定的命令直到退出。当命令正在执行时,ltrace 拦截并记录由执行进程调用的动态库调用以及该进程接收到的信号。它还可以拦截并打印程序执行的系统调用。要跟踪的程序不需要为此重新编译,因此您可以在您没有源的二进制文件上使用它。如果您需要一个用于跟踪进程执行情况的系统管理工具,则应安装 ltrace。

/etc/magic

file(1) 命令的 Magic 本地数据和配置文件。包含各种文件格式的描述,文件根据这些描述猜测文件类型。在此处插入您的本地 magic 数据。格式在 magic(5) 中描述。

/etc/mail.rc

“mail”的初始化文件。“mail”是一个智能邮件处理系统,其命令语法让人联想到 ed,行被消息替换。它基本上是 Microsoft Outlook 的命令行版本。

/etc/mailcap

'metamail' 功能文件。metamail 程序读取 mailcap 文件,以确定如何在本地站点显示非文本内容。mailcap 文件的语法非常简单,至少与 termcap 文件相比是这样。任何以 "#" 开头的行都是注释。空白行将被忽略。否则,每一行都为一个内容类型定义一个 mailcap 条目。长行可以用反斜杠字符 \ 结尾来继续。每个单独的 mailcap 条目都包含一个内容类型规范、一个要执行的命令以及(可能)一组可选的“标志”值。

/etc/mailcap.order

mailcap 排序规范。可以通过编辑 /etc/mailcap.order 文件来更改 /etc/mailcap 文件中条目的顺序。该文件的每一行都指定一个软件包和一个可选的 mime 类型。匹配的 Mailcap 条目将按照此文件的顺序排列。不匹配的条目将稍后放置。

/etc/mailname

邮件服务器主机名。通常与主机名相同。

/etc/menu, /etc/menu-methods

menu 软件包的灵感来自旧 fvwm2 软件包中的 install-fvwm2-menu 程序。但是,menu 尝试为菜单构建提供更通用的接口。通过此软件包中的 update-menus 命令,每个软件包都不需要再次为每个 X 窗口管理器进行修改,并且它为文本和面向 X 的程序提供了统一的接口。

当想要向菜单树添加内容的软件包被安装时,它将在其 postinstall 脚本中运行 update-menus。Update-menus 然后读取 /etc/menu/ /usr/lib/menu 和 /usr/lib/menu/default 中的所有菜单文件,并将所有已安装软件包的菜单条目存储在内存中。完成此操作后,它将运行 /etc/menu-methods/* 中的 menu-methods,并将有关菜单条目的信息通过 stdout 管道传输到 menu-methods,以便 menu-methods 可以读取此信息。每个想要拥有 debian 菜单树的窗口管理器或其他程序,都将在 /etc/menu-methods/ 中提供一个 menu-method 脚本。然后,此 menu-method 知道如何为该窗口管理器生成启动文件。为了方便窗口管理器维护人员完成此任务,menu 提供了一个 install-menu 程序。该程序可以为几乎每个窗口管理器生成启动文件。

/etc/mgetty+sendfax

用于将 mgetty 用作串行端口接口的配置文件。mgetty 例程特殊例程具有处理诸如拨号连接和传真连接等事物的特殊功能。

/etc/mime.types

MIME 类型以及表示它们的扩展名。此文件是 "mime-support" 软件包的一部分。注意:像 "gzip"、"bzip" 和 "compress" 这样的压缩方案实际上不是 "mime 类型"。它们是 "编码",因此 _不_ 必须在此文件中包含条目来映射它们的扩展名。编码文件的 "mime 类型" 指的是已被编码的数据类型,而不是编码的类型。

/etc/minicom

'minicom' 配置文件。'minicom' 是一个通信程序,它在某种程度上类似于共享软件程序 TELIX,但它是免费的,带有源代码,并且可以在大多数类 Unix 系统下运行。功能包括带有自动重拨的拨号目录、对串行设备上 UUCP 风格的锁定文件的支持、一个单独的脚本语言解释器、捕获到文件、具有单独配置的多个用户等等。

/etc/modules

启动时要加载的模块列表。

  # /etc/modules: kernel modules to load at boot time.
  #
  # This file should contain the names of kernel modules that are
  # to be loaded at boot time, one per line. Comments begin with
  # a "#", and everything on the line after them are ignored.
  unix
  af_packet
  via-rhine
  cmpci
  ne2k-pci
  nvidia
  

/etc/modules.conf

  ### This file is automatically generated by update-modules"
  #
  # Please do not edit this file directly. If you want to change or add
  # anything please take a look at the files in /etc/modutils and read
  # the manpage for update-modules.
  #
  ### update-modules: start processing /etc/modutils/0keep
  # DO NOT MODIFY THIS FILE!
  # This file is not marked as conffile to make sure if you upgrade modutils
  # it will be restored in case some modifications have been made.
  #
  # The keep command is necessary to prevent insmod and friends from ignoring
  # the builtin defaults of a path-statement is encountered. Until all other
  # packages use the new `add path'-statement this keep-statement is essential
  # to keep your system working
  keep

  ### update-modules: end processing /etc/modutils/0keep

  ### update-modules: start processing /etc/modutils/actions
  # Special actions that are needed for some modules

  # The BTTV module does not load the tuner module automatically,
  # so do that in here
  post-install bttv insmod tuner
  post-remove bttv rmmod tuner


  ### update-modules: end processing /etc/modutils/actions

  ### update-modules: start processing /etc/modutils/aliases
  # Aliases to tell insmod/modprobe which modules to use 

  # Uncomment the network protocols you don't want loaded:
  # alias net-pf-1 off		# Unix
  # alias net-pf-2 off		# IPv4
  # alias net-pf-3 off		# Amateur Radio AX.25
  # alias net-pf-4 off		# IPX
  # alias net-pf-5 off		# DDP / appletalk
  # alias net-pf-6 off		# Amateur Radio NET/ROM
  # alias net-pf-9 off		# X.25
  # alias net-pf-10 off		# IPv6
  # alias net-pf-11 off		# ROSE / Amateur Radio X.25 PLP
  # alias net-pf-19 off		# Acorn Econet

  alias char-major-10-175	agpgart
  alias char-major-10-200	tun
  alias char-major-81	bttv
  alias char-major-108	ppp_generic
  alias /dev/ppp		ppp_generic
  alias tty-ldisc-3	ppp_async
  alias tty-ldisc-14	ppp_synctty
  alias ppp-compress-21	bsd_comp
  alias ppp-compress-24	ppp_deflate
  alias ppp-compress-26	ppp_deflate

  # Crypto modules (see http://www.kerneli.org/)
  alias loop-xfer-gen-0	loop_gen
  alias loop-xfer-3	loop_fish2
  alias loop-xfer-gen-10	loop_gen
  alias cipher-2		des
  alias cipher-3		fish2
  alias cipher-4		blowfish
  alias cipher-6		idea
  alias cipher-7		serp6f
  alias cipher-8		mars6
  alias cipher-11		rc62
  alias cipher-15		dfc2
  alias cipher-16		rijndael
  alias cipher-17		rc5


  ### update-modules: end processing /etc/modutils/aliases

  ### update-modules: start processing /etc/modutils/ltmodem-2.4.18
  # lt_drivers: autoloading and insertion parameter usage
  alias char-major-62 lt_serial
  alias /dev/tts/LT0  lt_serial
  alias /dev/modem lt_serial
  # options lt_modem vendor_id=0x115d device_id=0x0420 Forced=3,0x130,0x2f8
  # section for lt_drivers ends

  ### update-modules: end processing /etc/modutils/ltmodem-2.4.18

  ### update-modules: start processing /etc/modutils/paths
  # This file contains a list of paths that modprobe should scan,
  # beside the once that are compiled into the modutils tools
  # themselves.


  ### update-modules: end processing /etc/modutils/paths

  ### update-modules: start processing /etc/modutils/ppp
  alias /dev/ppp          ppp_generic
  alias char-major-108    ppp_generic
  alias tty-ldisc-3       ppp_async  
  alias tty-ldisc-14      ppp_synctty
  alias ppp-compress-21   bsd_comp   
  alias ppp-compress-24   ppp_deflate
  alias ppp-compress-26   ppp_deflate

  ### update-modules: end processing /etc/modutils/ppp

  ### update-modules: start processing /etc/modutils/setserial
  #
  # This is what I wanted to do, but logger is in /usr/bin, which isn't
  # loaded when the module is first loaded into the kernel at boot time!
  #
  #post-install serial /etc/init.d/setserial start | 
  #logger -p daemon.info -t "setserial-module reload"
  #pre-remove serial /etc/init.d/setserial stop | 
  #logger -p daemon.info -t "setserial-module uload"
  #
  alias /dev/tts          serial
  alias /dev/tts/0        serial
  alias /dev/tts/1        serial
  alias /dev/tts/2        serial
  alias /dev/tts/3        serial
  post-install serial /etc/init.d/setserial modload > /dev/null 2> /dev/null
  pre-remove serial /etc/init.d/setserial modsave  > /dev/null 2> /dev/null

  ### update-modules: end processing /etc/modutils/setserial

  ### update-modules: start processing /etc/modutils/arch/i386
  alias parport_lowlevel parport_pc
  alias char-major-10-144 nvram
  alias binfmt-0064 binfmt_aout
  alias char-major-10-135 rtc

  ### update-modules: end processing /etc/modutils/arch/i386
  

/etc/modutils

这些实用程序旨在使 Linux 模块化内核对所有用户、管理员和发行版维护者都可管理。

/etc/mtools

Debian 默认 mtools 配置文件。mtools 系列命令用于处理软盘上的 MS-DOS 文件和目录。这允许您在 DOS 和 Windows 系统上将 Linux 与 MS-DOS 格式化的软盘一起使用。

/etc/manpath.conf

man_db 软件包使用此文件来配置 man 和 cat 路径。它还用于通过检查用户的 PATH 环境变量为没有 manpath 的人提供 manpath。有关详细信息,请参阅 manpath(5) 手册页。

/etc/mediaprm

以前名为 /etc/fdprm。有关更多详细信息,请参阅 /etc/fdprm。

/etc/motd

每日消息,在成功登录后自动输出。内容由系统管理员决定。通常用于向每个用户获取信息,例如有关计划停机时间的警告。Linux debian.localdomain.com 2.4.18 #1 Sat Mar 15 00:17:39 EST 2003 i686 unknown Debian GNU/Linux 系统附带的大多数程序都是可以自由再发行的;每个程序的具体发行条款在 /usr/share/doc/*/copyright 中的各个文件中描述。Debian GNU/Linux 不提供任何担保,在适用法律允许的范围内。

/etc/mtab

当前挂载的文件系统列表。最初由启动脚本设置,并由 mount 命令自动更新。当需要挂载文件系统列表时使用,例如,由 df 命令使用。此文件有时是 /proc/mounts 的符号链接。

/etc/networks

系统当前所在的网络列表。例如,192.168.0.0。

/etc/nsswitch.conf

系统数据库/名称服务切换配置文件。

/etc/oss.conf

OSS(开放声音系统)配置文件。

/etc/pam.d/

此目录是 PAM(可插拔身份验证模块)的配置文件的家目录。

/etc/postfix/

保存您的 postfix 配置文件。Postfix 现在是 Linux 发行版中首选的 MTA。它与 sendmail 兼容,与 sendmail 相比,提供了更高的速度、易于管理和安全性。它最初由 IBM 开发,被称为 IBM Secure Mailer,并在许多大型商业网络中使用。现在它已成为事实上的标准。

/etc/ppp/

放置拨号配置文件的位置。很可能由基于文本菜单的 pppconfig 或其他基于 GUI 的 ppp 配置实用程序(如 kppp 或 gnome-ppp)创建。

/etc/pam.conf

大多数程序使用 /etc/pam.d/ 目录下的文件来设置其 PAM 服务模块。此文件可以使用,但不推荐使用。

/etc/paper.config

纸张尺寸配置文件。

/etc/papersize

默认纸张尺寸。

/etc/passwd

这是“旧”密码文件,它为了兼容性而保留,并包含用户数据库,其中字段给出用户名、真实姓名、主目录、加密密码以及有关每个用户的其他信息。格式记录在 passwd 手册页中。

root:x:0:0:root:/root:/bin/bash daemon:x:1:1:daemon:/usr/sbin:/bin/sh
bin:x:2:2:bin:/bin:/bin/sh sys:x:3:3:sys:/dev:/bin/sh
sync:x:4:100:sync:/bin:/bin/sync games:x:5:100:games:/usr/games:/bin/sh
man:x:6:100:man:/var/cache/man:/bin/sh lp:x:7:7:lp:/var/spool/lpd:/bin/sh
mail:x:8:8:mail:/var/mail:/bin/sh news:x:9:9:news:/var/spool/news:/bin/sh
uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh proxy:x:13:13:proxy:/bin:/bin/sh
postgres:x:31:32:postgres:/var/lib/postgres:/bin/sh
www-data:x:33:33:www-data:/var/www:/bin/sh
backup:x:34:34:backup:/var/backups:/bin/sh
operator:x:37:37:Operator:/var:/bin/sh
list:x:38:38:SmartList:/var/list:/bin/sh irc:x:39:39:ircd:/var:/bin/sh
gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
nobody:x:65534:65534:nobody:/home:/bin/sh
binh:x:1000:1000:,,,:/home/binh:/bin/bash
identd:x:100:65534::/var/run/identd:/bin/false
sshd:x:101:65534::/var/run/sshd:/bin/false gdm:x:102:101:Gnome Display
Manager:/var/lib/gdm:/bin/false
telnetd:x:103:103::/usr/lib/telnetd:/bin/false
dummy:x:1001:1001:,,,:/home/dummy:/bin/bash

/etc/passwd-

旧的 /etc/passwd 文件。

/etc/printcap

打印机配置(功能)文件。所有系统打印机(无论是本地打印机还是远程打印机)的定义都存储在此文件中。其布局类似于 /etc/termcap,但它使用不同的语法。

/etc/profile

Bourne shell 或 C shell 在登录或启动时要执行的文件和命令。这些允许系统管理员为所有用户设置全局默认值。

/etc/profile.d

登录到 Bourne shell 或 C shell 时要执行的 Shell 脚本。这些脚本通常从 /etc/profile 文件中调用。

/etc/protocols

协议定义文件。它描述了可从 TCP/IP 子系统获得的各种 DARPA Internet 协议。应该查阅它,而不是使用 ARPA 包含文件中的数字或求助于猜测。此文件应保持原样,因为更改可能会导致不正确的 IP 数据包。

/etc/pcmcia

PCMCIA 设备的配置文件。通常只对笔记本电脑用户有用。

/etc/reportbug.conf

reportbug 的配置文件。Reportbug 主要设计用于报告 Debian 发行版中的错误。默认情况下,它会创建一个电子邮件发送到 mit@bugs.debian.org 的 Debian 错误跟踪系统,其中包含有关错误的信息。使用 -bts 选项,您还可以向其他也使用 ddebbugs 的服务器(如 KDE.org)报告错误。它类似于 bug,但具有更强大的功能,同时仍保持简单性。

/etc/rc.boot 或 /etc/rc?.d

这些目录包含控制系统服务和配置运行级别所需的所有文件。骨架文件在 /etc/init.d/skeleton 中提供

/etc/rcS.d

此目录中的脚本在系统启动时执行一次,即使直接启动到单用户模式也是如此。这些文件都是符号链接,真实文件位于 /etc/init.d/ 中。有关此技术的更一般性讨论,请参阅 /etc/init.d/README。

/etc/resolv.conf

DNS 如何发生的配置在此文件中定义。它告诉名称解析器库需要去哪里查找在 /etc/hosts 文件中找不到的信息。这总是至少有一行 nameserver,但最好是三行。解析器依次使用每个服务器。可以包含超过前三个服务器,但超出前三个服务器的任何服务器都将被忽略。/etc/resolv.conf 文件中出现的两行是 domain 和 search。这两个都是互斥的选项,如果两者都出现,则最后一个获胜。手册页中列出了此处讨论的三个条目之外的其他条目,但它们并不常用。

/etc/rmt

这不是错误。提供此 shell 脚本 (/etc/rmt) 是为了与其他类 Unix 系统兼容,其中一些系统具有期望在远程系统上的 /etc 目录中找到(并执行)rmt 的实用程序。

/etc/rpc

rpc 文件包含用户可读的名称,可以用来代替 rpc 程序号。每行都有以下信息:-rpc 程序的服务器名称 -rpc 程序号 -别名 项目用任意数量的空格和/或制表符分隔。“#”表示注释的开始;直到行尾的字符都不会被搜索文件的例程解释。

  # /etc/rpc:
  # $Id: etc.xml,v 1.10 2004/02/03 21:42:57 binh Exp $
  #
  # rpc 88/08/01 4.0 RPCSRC; from 1.12   88/02/07 SMI

  portmapper	100000	portmap sunrpc
  rstatd		100001	rstat rstat_svc rup perfmeter
  rusersd		100002	rusers
  nfs		100003	nfsprog
  ypserv		100004	ypprog
  mountd		100005	mount showmount
  ypbind		100007
  walld		100008	rwall shutdown
  yppasswdd	100009	yppasswd
  etherstatd	100010	etherstat
  rquotad		100011	rquotaprog quota rquota
  sprayd		100012	spray
  3270_mapper	100013
  rje_mapper	100014
  selection_svc	100015	selnsvc
  database_svc	100016
  rexd		100017	rex
  alis		100018
  sched		100019
  llockmgr	100020
  nlockmgr	100021
  x25.inr		100022
  statmon		100023
  status		100024
  bootparam	100026
  ypupdated	100028	ypupdate
  keyserv		100029	keyserver
  tfsd		100037 
  nsed		100038
  nsemntd		100039
  pcnfsd		150001
  amd		300019	amq
  sgi_fam		391002
  ugidd		545580417
  bwnfsd          788585389
  

/etc/samba

Samba 配置文件。一个类似 'LanManager' 的 Unix 文件和打印机服务器。Samba 软件包是一组程序,用于为 unix 系统实现 SMB 协议,允许您为 Windows、NT、OS/2 和 DOS 客户端提供文件和打印机服务。此协议有时也称为 LanManager 或 NetBIOS 协议。

/etc/sane.d

Sane 配置文件。SANE 代表 "Scanner Access Now Easy",它是一个应用程序编程接口 (API),提供对任何光栅图像扫描仪硬件(平板扫描仪、手持扫描仪、视频和静态相机、帧捕获器等)的标准化访问。SANE API 是公有领域,其讨论和开发对所有人开放。当前源代码是用 UNIX(包括 GNU/Linux)编写的,并且在 GNU 通用公共许可证 (SANE API 也可用于专有应用程序和后端) 下可用。

SANE 是一个通用的扫描仪接口。这种通用接口的价值在于,它允许为每个图像采集设备编写一个驱动程序,而不是为每个设备和应用程序编写一个驱动程序。因此,如果您有三个应用程序和四个设备,传统上您将不得不编写 12 个不同的程序。使用 SANE,这个数字减少到 7 个:三个应用程序加上四个驱动程序。当然,随着越来越多的驱动程序和/或应用程序的添加,节省的成本会更大。

SANE 不仅减少了开发时间和代码重复,还提高了应用程序可以工作的级别。因此,它将启用以前在 UNIX 世界中闻所未闻的应用程序。虽然 SANE 主要针对 UNIX 环境,但该标准经过精心设计,使其可以在几乎任何硬件或操作系统上实现 API。

虽然 SANE 是 "Scanner Access Now Easy" 的首字母缩写,但希望 SANE 确实是明智的,因为它允许轻松实现 API,同时适应当今扫描仪硬件和应用程序所需的所有功能。具体来说,SANE 应该足够广泛,以容纳扫描仪、数字静态和视频摄像机以及图像文件过滤器等设备。

如果您熟悉 TWAIN,您可能会想知道为什么需要 SANE。简而言之,TWAIN 不会将用户界面与设备的驱动程序分离。不幸的是,这使得提供对图像采集设备的网络透明访问变得困难(如果不是不可能的话)(如果您有一个充满机器的局域网,但扫描仪仅连接到一台或两台机器,这将非常有用;对于远程控制的摄像机等来说,显然也很有用)。这也意味着任何特定的 TWAIN 驱动程序都几乎与特定的 GUI API(无论是 Win32 还是 Mac API)绑定在一起。相比之下,SANE 干净利落地将设备控件与其在用户界面中的表示形式分离。因此,SANE 可以轻松支持命令行驱动的界面或网络透明扫描。由于这些原因,不太可能出现可以与 TWAIN 驱动程序对话的 SANE 后端。然而,反过来没有问题:通过 TWAIN 源访问 SANE 设备将非常简单。总而言之,如果 TWAIN 的设计稍微好一点,就没有理由存在 SANE,但事情就是这样,TWAIN 根本不 SANE。

/etc/securetty

标识安全终端,即允许 root 用户登录的终端。通常只列出虚拟控制台,这样就可以防止(或至少更难)通过调制解调器或网络入侵系统来获得超级用户权限。

 
  # /etc/securetty: list of terminals on which root is allowed to login.
  # See securetty(5) and login(1).
  console

  # Standard consoles
  tty1
  tty2
  tty3
  tty4
  tty5
  tty6
  tty7
  tty8
  tty9
  tty10
  tty11
  tty12

  # Same as above, but these only occur with devfs devices
  vc/1
  vc/2
  vc/3
  vc/4
  vc/5
  vc/6
  vc/7
  vc/8
  vc/9
  vc/10
  vc/11
  vc/12
  

/etc/sensors.conf

libsensors 的配置文件。一组旨在通过主板传感器芯片确定当前硬件状态的库。可以通过第三方实用程序(如 'gkrellm')利用这些库来确定有用的统计信息,例如内核电压、CPU 温度。如果您不想安装这些软件包,您也可以利用 /proc 文件系统的实时特性。

/etc/sudoers

Sudoers 文件。必须以 root 用户身份使用 'visudo' 命令编辑此文件。sudo 命令允许经过身份验证的用户以 root 用户身份执行授权命令。有效 UID 和 GID 都设置为 0(您基本上是 root 用户)。它确定哪些用户被授权以及他们被授权使用哪些命令。此命令的配置通过此文件进行。

/etc/shadow

安装了影子密码软件(PAM)的系统上的影子密码文件。影子密码将加密密码从 /etc/passwd 移动到 /etc/shadow;后者除了 root 用户外,任何人都不可读取。这使得破解密码更加困难。

/etc/shadow-

旧的 /etc/shadow 文件。

/etc/sysctl.conf

用于设置系统变量(最值得注意的是内核参数)的配置文件。'sysctl' 是一种在运行时配置内核某些方面的方法,/proc/sys/ 目录在那里,这样您甚至不需要特殊工具来执行此操作!

/etc/security

对安全至关重要。此子目录允许管理员施加配额限制、访问限制,并配置 PAM 环境。

/etc/serial.conf

串行端口配置。可更改的参数包括速度、波特率、端口、irq 和类型。

/etc/services

此系统上可用的网络、服务以及每个协议的关联端口的定义。例如,Web 服务 (http) 默认分配给端口 80。# /etc/services: # $Id: etc.xml,v 1.10 2004/02/03 21:42:57 binh Exp $ # # 网络服务,Internet 风格 # # 请注意,IANA 目前的政策是为 TCP 和 UDP 分配一个单一的 # 众所周知的端口号;因此,即使协议不支持 UDP # 操作,这里的大多数条目都有两个条目。从 RFC 1700,“分配的号码”(10 月 # 1994 年)更新。并非所有端口都包含在内,仅包含更常见的端口。 echo 7/tcp echo 7/udp discard 9/tcp sink null discard 9/udp sink null systat 11/tcp users daytime 13/tcp daytime 13/udp netstat 15/tcp qotd 17/tcp quote msp 18/tcp # message send protocol msp 18/udp # message send protocol chargen 19/tcp ttytst source chargen 19/udp ttytst source ftp-data 20/tcp ftp 21/tcp fsp 21/udp fspd ssh 22/tcp # SSH 远程登录协议 ssh 22/udp # SSH 远程登录协议 telnet 23/tcp # 24 - private smtp 25/tcp mail # 26 - unassigned time 37/tcp timserver time 37/udp timserver rlp 39/udp resource # resource location nameserver 42/tcp name # IEN 116 whois 43/tcp nicname re-mail-ck 50/tcp # Remote Mail Checking Protocol re-mail-ck 50/udp # Remote Mail Checking Protocol domain 53/tcp nameserver # name-domain server domain 53/udp nameserver netbios-ns 137/tcp # NETBIOS 名称服务 netbios-ns 137/udp netbios-dgm 138/tcp # NETBIOS 数据报服务 netbios-dgm 138/udp netbios-ssn 139/tcp # NETBIOS 会话服务 netbios-ssn 139/udp x11 6000/tcp x11-0 # X windows system x11 6000/udp x11-0 # X windows system

/etc/shells

列出受信任的 Shell。chsh 命令允许用户仅将其登录 Shell 更改为此文件中列出的 Shell。ftpd,为机器提供 FTP 服务的服务器进程,将检查用户的 Shell 是否在 /etc/shells 中列出,并且除非 Shell 在那里列出,否则将不允许人们登录。还有一些显示管理器会被动或主动地(取决于所使用的发行版和显示管理器)拒绝用户访问系统,除非他们的 Shell 是此处列出的 Shell 之一。

  # /etc/shells: valid login shells
  /bin/ash
  /bin/bash
  /bin/csh
  /bin/sh
  /usr/bin/es
  /usr/bin/ksh 
  /bin/ksh
  /usr/bin/rc
  /usr/bin/tcsh
  /bin/tcsh
  /usr/bin/zsh
  /bin/sash
  /bin/zsh
  /usr/bin/esh
  

/etc/skel/

每个新用户的默认文件都存储在此目录中。每次添加新用户时,这些骨架文件都会复制到他们的主目录中。平均系统将具有:.alias、.bash_profile、.bashrc 和 .cshrc 文件。其他文件留给系统管理员决定。

/etc/sysconfig/

此目录包含用于设置系统配置细节和启动过程的配置文件和子目录,例如设置时区的“clock”,或控制键盘映射的“keyboard”。内容可能会因您安装的发行版和实用程序而差异很大。例如,在基于 Redhat 或 Mandrake 的系统上,可以更改从默认桌面到是否应为您的 IDE 设备启用 DMA 的无数属性。但是,在我们的 Debian 参考系统上,此文件夹几乎是权宜之计,仅包含两个文件 hwconf 和 soundcard,它们分别由 Redhat 实用程序 hwconf 和 sndconfig 配置。

/etc/slip

用于设置和操作 SLIP(串行线路 IP)接口的配置文件。现在通常不使用。此协议已被更快、更高效的 PPP 协议取代。

/etc/screenrc

这是系统范围的 screenrc。您可以使用此文件来更改 screen 系统范围的默认行为,或将其复制到 ~/.screenrc 并将其用作您自己设置的起点。此文件中的命令用于设置选项、将 screen 功能绑定到按键、重新定义终端功能以及在 screen 会话开始时自动建立一个或多个窗口。这不是选项的完整列表,请查看 screen 手册以了解您可以放入此文件中的所有内容。

/etc/scrollkeeper.conf

一个用于文档的免费电子编目系统。它存储 http://www.ibiblio.org/osrt/omf/ (开放源代码元数据框架) 指定的元数据,以及直接从文档中提取的某些元数据(例如目录)。它为此元数据提供各种功能,以帮助浏览器,例如对注册文档进行排序或搜索元数据以查找满足一组条件的文档。

/etc/ssh

'ssh' 配置文件。'ssh' 是一个安全的 rlogin/rsh/rcp 替代品 (OpenSSH)。这是 OpenSSH 的可移植版本,OpenSSH 是 IETF secsh 工作组指定的安全 Shell 协议的免费实现。'ssh'(安全 Shell)是一个用于登录远程计算机并在远程计算机上执行命令的程序。它在两个不受信任的主机之间通过不安全的网络提供安全的加密通信。X11 连接和任意 TCP/IP 端口也可以通过安全通道转发。它旨在替代 rlogin、rsh 和 rcp,并且可以用于为应用程序提供安全的通信通道。应该注意的是,在某些国家/地区,特别是伊拉克和巴基斯坦,在没有特殊许可证的情况下使用任何加密都可能是非法的。

/etc/syslog.conf

列出日志文件应放置的位置、写入日志文件的消息以及详细程度。现在还可以根据消息内容、消息完整性、消息加密(不久的将来)、可移植性和更好的网络转发进行过滤。

/etc/termcap

终端功能数据库。描述各种终端可以控制的“转义序列”。程序的编写方式是,它们不是直接输出仅在特定品牌终端上工作的转义序列,而是查找在 /etc/termcap 中执行他们想要执行的操作的正确序列。因此,大多数程序都适用于大多数类型的终端。

/etc/timezone

本地时区。

/etc/updatedb.conf

设置 updatedb 使用的环境变量,因此配置 'locate' 的数据库,'locate' 是一个在文件名数据库中查找模式并返回匹配文件名的实用程序。

  # This file sets environment variables which are used by updatedb

  # filesystems which are pruned from updatedb database
  PRUNEFS="NFS nfs afs proc smbfs autofs auto iso9660 ncpfs coda devpts ftpfs"
  export PRUNEFS
  # paths which are pruned from updatedb database
  PRUNEPATHS="/tmp /usr/tmp /var/tmp /afs /amd /alex /var/spool"
  export PRUNEPATHS
  # netpaths which are added
  NETPATHS=""
  export NETPATHS
  

/etc/vga

用于 svgalib 的配置文件存储在此目录中。svgalib 为在系统控制台上运行的程序提供图形功能,而无需通过 X Window 系统。它使用直接访问视频硬件来提供对标准 VGA 和 SVGA 图形模式的低级访问。它仅适用于某些视频硬件;因此请谨慎使用。

/etc/vim

包含 vim 及其基于 X 的对应程序 gvim 的配置文件。可以通过这两个文件访问各种选项,例如自动缩进、语法突出显示等。

/etc/xinetd.d/

原始的 'inetd' 守护程序现在已被大大改进的 'xinetd' 取代。'inetd' 应在启动时由 /etc/init.d/inetd(或某些系统上的 /etc/rc.local)运行。然后,它侦听某些 Internet 套接字上的连接。当在其中一个套接字上找到连接时,它会确定套接字对应的服务,并调用一个程序来服务该请求。程序完成后,它会继续侦听套接字(某些情况下除外)。本质上,inetd 允许运行一个守护程序来调用其他几个守护程序,从而减少系统负载。通过 xinetd 控制的服务将其配置文件放在此处。

/etc/zlogin

zsh(1) 的系统范围的 .zlogin 文件。此文件仅针对登录 Shell 源化。它应包含仅应在登录 Shell 中执行的命令。它应用于设置终端类型并运行一系列外部命令(fortune、msgs、from 等)。

/etc/zlogout

用户从 zsh 退出时要执行的命令。它的控制是系统范围的,但 zsh(1) 的 .zlogout 文件在重要性方面会覆盖它。

/etc/zprofile

zsh(1) 的系统范围的 .zprofile 文件。此文件仅针对登录 Shell 源化(即,以“-”作为 argv[0] 的第一个字符调用的 Shell,以及以 -l 标志调用的 Shell。)

/etc/zshenv

zsh(1) 的系统范围的 .zshenv 文件。此文件在 shell 的所有调用上源化。如果存在 -f 标志,或者如果在此文件中设置了 NO_RCS 选项,则会跳过所有其他初始化文件。此文件应包含用于设置命令搜索路径以及其他重要环境变量的命令。此文件不应包含产生输出或假设 shell 连接到 tty 的命令。

/etc/zshrc

zsh(1) 的系统范围的 .zshrc 文件。此文件仅针对交互式 shell 源化。它应包含用于设置别名、函数、选项、按键绑定等的命令。

符合 FSSTND 要求 /etc 中需要以下目录或目录的符号链接

  opt       Configuration for /opt
  X11       Configuration for the X Window system (optional)
  sgml      Configuration for SGML (optional)
  xml       Configuration for XML (optional)

  The following directories, or symbolic links to directories must be in /etc,
  if the corresponding subsystem is installed:

  opt       Configuration for /opt

  The following files, or symbolic links to files, must be in /etc if the
  corresponding subsystem is installed (it is recommended that files be
  stored in subdirectories of /etc/ rather than directly in /etc:

  csh.login   Systemwide initialization file for C shell logins (optional)
  exports     NFS filesystem access control list (optional)
  fstab       Static information about filesystems (optional)
  ftpusers    FTP daemon user access control list (optional)
  gateways    File which lists gateways for routed (optional)
  gettydefs   Speed and terminal settings used by getty (optional)
  group       User group file (optional)
  host.conf   Resolver configuration file (optional)
  hosts       Static information about host names (optional)
  hosts.allow Host access file for TCP wrappers (optional)
  hosts.deny  Host access file for TCP wrappers (optional)
  hosts.equiv List of trusted hosts for rlogin, rsh, rcp (optional)
  hosts.lpd   List of trusted hosts for lpd (optional)
  inetd.conf  Configuration file for inetd (optional)
  inittab     Configuration file for init (optional)
  issue       Pre-login message and identification file (optional)
  ld.so.conf  List of extra directories to search for shared libraries 
              (optional)
  motd        Post-login message of the day file (optional)
  mtab        Dynamic information about filesystems (optional)
  mtools.conf Configuration file for mtools (optional)
  networks    Static information about network names (optional)
  passwd      The password file (optional)
  printcap    The lpd printer capability database (optional)
  profile     Systemwide initialization file for sh shell logins (optional)
  protocols   IP protocol listing (optional)
  resolv.conf Resolver configuration file (optional)
  rpc         RPC protocol listing (optional)
  securetty   TTY access control for root login (optional)
  services    Port names for network services (optional)
  shells      Pathnames of valid login shells (optional)
  syslog.conf Configuration file for syslogd (optional) 

  mtab does not fit the static nature of /etc: it is excepted for historical
  reasons. On some Linux systems, this may be a symbolic link to /proc/mounts,
  in which case this exception is not required.

  /etc/opt : Configuration files for /opt
  Host-specific configuration files for add-on application software packages
  must be installed within the directory /etc/opt/&60;subdir&62;, where 
  &60;subdir&62; is the name of the subtree in /opt where the static data
  from that package is stored.

  No structure is imposed on the internal arrangement of /etc/opt/&60;subdir&62;.
  If a configuration file must reside in a different location in order for the
  package or system to function properly, it may be placed in a location other
  than /etc/opt/&60;subdir&62;.

  The rationale behind this subtree is best explained by refering to the
  rationale for /opt.

  /etc/X11 : Configuration for the X Window System (optional)
  /etc/X11 is the location for all X11 host-specific configuration. This
  directory is necessary to allow local control if /usr is mounted read only.

  The following files, or symbolic links to files, must be in /etc/X11 if the
  corresponding subsystem is installed:

  Xconfig    The configuration file for early versions of XFree86 (optional)
  XF86Config The configuration file for XFree86 versions 3 and 4 (optional)
  Xmodmap    Global X11 keyboard modification file (optional)

  Subdirectories of /etc/X11 may include those for xdm and for any other
  programs (some window managers, for example) that need them.

  /etc/X11/xdm holds the configuration files for xdm. These are most of the
  files previously found in /usr/lib/X11/xdm. Some local variable data for
  xdm is stored in /var/lib/xdm.

  It is recommended that window managers with only one configuration file
  which is a default .*wmrc file must name it system.*wmrc (unless there is
  a widely-accepted alternative name) and not use a subdirectory. Any window
  manager subdirectories must be identically named to the actual window 
  manager binary.

  /etc/sgml : Configuration files for SGML (optional)
  Generic configuration files defining high-level parameters of the SGML
  systems are installed here. Files with names *.conf indicate generic
  configuration files. File with names *.cat are the DTD-specific centralized
  catalogs, containing references to all other catalogs needed to use the 
  given DTD. The super catalog file catalog references all the centralized
  catalogs.

  /etc/xml : Configuration files for XML (optional)
  Generic configuration files defining high-level parameters of the XML
  systems are installed here. Files with names *.conf indicate generic
  configuration files. The super catalog file catalog references all the
  centralized catalogs.