Part of the program:
Binary parts: Generally in/bin,/sbin and other directories
Libraries:/lib, include
Configuration file:/etc
Help file: Man
Linux Each directory brief note:
/etc,/bin,/sbin,/lib
Programs that need to be used when the system starts, these directories cannot mount additional partitions and must be on the same partition as the root file system
/usr/
Bin
Sbin
Lib
Operating system core functions, can be partitioned separately
/proc
/sys
Cannot separate partition, default is empty
/dev: device, cannot be partitioned separately
/root: cannot be partitioned separately
/var: recommended separate partitioning
/boot: Kernel, INITRD (INITRAMFS)
Post-->bios--> (MBR) bootloader (file system, ext2, ext3)--Kernel
Package Management: RPM
Role:
Package binaries, configuration files, Help files, library files into one file
Build a database to track every file you install
Core Features:
1. Making a software package
2. Install, uninstall, upgrade, query, verify
redhat,suse:rpm
Redhat Package Manager
PRM is package Manager
Debian:dpt
Front end tool: Yum Apt-get
Back-end tools: RPM,DPT
Yum:yellowdog Update Modifier
RPM Command:
Rpm:
Database:/var/lib/rpm
Rpmbuild:
RPM Name:
Package: Components
Main package:
bind-9.7.1-1.el5.i586.rpm
Child Package:
bind-libs-9.7.1-1.el5.i586.rpm
Package name format:
name-version-release.arch.rpm
bind-major.minor.release-release.arch.rpm
Major version number: significant improvements
Minor version number: A significant change in a child function
Release number (first release): Fixed some bugs, adjusted a bit of functionality
Release number (second release): The author made a modified version of RPM
RPM Package:
binary format
RPM Package Author Download the source program, after the compilation configuration is completed, made into RPM package
Rpm:
Installation:
Rpm-i/path/to/package_file
-H: Show progress in #: each # represents 2%;
-V: Show detailed procedures
-VV: A more detailed process
Rpm-ivh/path/to/package_file
--nodeps: Ignore dependencies:
--REPLACEPK: Reinstall, replace the original installation:
--force: Forced installation, can be re-installed or degraded:
Inquire:
Rpm-q package_name: Query whether the specified package is already installed
RPM-QA: Querying all packages that have been installed
Rpm-qi package_name: Query The description information for the specified package:
RPM-QL package_name: Query the list of files generated after the installation of the specified package:
RPM-QD package_name: Query the Help file for the specified package installation
Rpm-qf/path/to/somefile: Query the specified file is generated by which RPM package is installed
Rpm-q--script package_name: Query the script contained in the specified package
If a RPM package has not been installed, we need to query its description information, the installation will generate files
Rpm-qpi/path/to/package_file
Rpm-qpl
Upgrade:
Rpm-uvh/path/to/new_package_file: Upgrade If the old version is installed, otherwise, install
Rpm-fvh/path/to/new_package_file: Upgrade If old version is installed, otherwise, exit
--oldpackage: Downgrade
Unloading:
RPM-E package_name
--nodeps
Check:
Rpm-v package_name
Rebuild the RPM database:
Rpm
--REBUILDDB: Rebuilding the database
--INITDB: Initialize the database, not just build, there is no
Verify source legality, and software integrity:
Encryption Type:
Symmetric: Encrypt and decrypt using the same key
Public key: A pair of keys, public key, private key: The public key is implied in the private key, can be extracted and exposed
One-way: Used to verify the integrity, as long as one character changes, the results will vary greatly
[Email protected] ~]# ls/etc/pki/rpm-gpg/
Rpm-gpg-key-centos-6 rpm-gpg-key-epel-6
Rpm-gpg-key-centos-debug-6 Rpm-gpg-key-rpmforge-dag
Rpm-gpg-key-centos-security-6 Rpm-gpg-key-rpmforge-fabian
Rpm-gpg-key-centos-testing-6
Rpm-k/path/to/package_file
DSA,GPG: Verify the source legitimacy, that is, verify that the signature can be used--nosignature, skip this
SHA1,MD5: Verify package integrity; You can use--nodigest to skip this
This article from "Single Season rice" blog, declined reprint!
Linux Package Management rpm