These files control package installation. anaconda allows for multiple package installation backends, though the only real one in the tree uses yum. Each backend provides methods for selecting groups and packages, removing groups and packages, writing out configuration settings, and so forth.

These files handle writing some sort of filesystem or filesystem-like abstraction to a storage device. Think of this as a layer on top of something in pyanaconda/storage/devicelibs/. Filesystem-like abstractions include disk labels, encryption, machine-specific boot partitions, and swap.

pyanaconda/partIntfHelpers.py

This file contains methods that are used for error checking, input validation, and displaying error messages. The graphical and text interfaces make use of it.

These files form a support library within the storage module, taking care of a variety of small tasks that don't fit well in another group. For the most part, the names describe what they do. pyanaconda/storage/__init__.py handles a rather large number of catch-all tasks including reading and writing storage-related configuration files, probing for existing installations, coordinating storage actions, marshalling data between storage objects, and performing sanity checks.

This group of files implements the partitioning logic. It holds the DeviceTree abstraction that stores existing partitions and requests in a meaningful way, defines the actions needed to write storage requests to disk, handles automatic partitioning (which is the default), and knows how to grow and shrink all requests until they fit in the space provided. Partitions themselves are created on disk by using the pyparted package.

安装类别

Installation classes define settings that form a sort of installation profile. This includes steps to show and skip, product names, installation method, enabled repositories, configuration settings, and so forth. We primarily use it to create a difference between Fedora and RHEL installs. Other projects or ISVs could define their own installation classes for their own defaults.

特殊模块

pyanaconda/kickstart.py

Kickstart is a way of automating installations by providing anaconda with a file that contains all the data that the user would have to provide via the UI. This file is an interface between the parser in the pykickstart package and the anaconda internals. It primarily provides a way of saving the settings in the places anaconda expects.

data/icons
data/liveinst
liveinst/
pyanaconda/livecd.py

These files implement installation from the live CD. They provide a special installation method, a special package installation backend, and some files needed to launch the installer from the live CD's desktop.

These files provide a variety of miscellaneous methods that are used throughout the installer. These functions include the logging framework, hardware probing via a udev interface, process control, handling exceptions, and other tasks. They also contain methods that just don't fit anywhere else.

主程序

anaconda

This is the main anaconda program that gets called from the loader. It handles lots of environment setup, enables updates if they exist, reads any kickstart file, sets up VNC, and other tasks. When all this is done, it hands control over to the dispatcher which deals with the rest of the installation process.

镜像制作

data/bootdisk/
data/command-stubs/
data/fonts/
scripts/
utils/

These directories contain code that controls how the installation environment is made. This includes creating the initial ramdisk and the
stage2 images, adding very basic versions of certain needed commands, splitting the installation tree into media-sized chunks, and other
miscellaneous tasks.