In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >
Share
Shulou(Shulou.com)06/01 Report--
I. the foundation of the application program
Transfer the software to LINUX
Yum install lrzsz
(note: LINUX should be able to connect to the Internet, ping × × w.qq.com)
The relationship between application program and system command
File location
System commands: generally in / bin and / sbin directories, or Shell internal instructions
Applications: usually in / usr/bin and / usr/sbin directories
Main use
System commands: complete the basic management of the system, such as IP configuration tools
Applications: perform other relatively independent auxiliary tasks, such as web browsers
Applicable environment
System commands: generally only run in the character operation interface
Applications: according to the actual needs, some programs can be run in the graphical interface
Running format
System commands: generally include command words, command options, and command parameters
Applications: there is usually no fixed execution format
Directory structure of typical applications
File type
Save catalog
General executive program file
/ usr/bin
Server execution program file and manager program file
/ usr/sbin
Application configuration file
/ etc
Log file
/ var/log
Application documentation file
/ usr/share/doc
Application manual page file
/ usr/share/man
Common package encapsulation types
File type
Save catalog
Rpm software package
Extension ".rpm"
Deb software package
Extension ".deb"
Source code package
Compressed packages in the format of ".tar.gz", ".tar.bz2", etc., containing the original code of the program
Green installation-free software package
Provide the compiled executive program text in the compressed package-the files after unlocking the compressed package can be used directly
Centos software package management
Rpm software package
RPM
Redhat Package Manager
Proposed by Red Hat and adopted by many Linux distributions
Establish a unified database file
Record the changes of software package installation, uninstallation and so on in detail.
Automatic analysis of package dependencies
RPM software package
Software material reference: http:// × × w.rpm.org
General naming format:
Query information about installed RPM software
Rpm-Q [suboption] [software name]
Common option
-qa,-qi,-ql,-qf,-qc,-qd
Rpm-qa queries all installed software packages
Rpm-qi queries the information of an installed software package
Rpm-ql queries the installation path of an installed software package
Query information in uninstalled RPM package files
Rpm-qp [suboptions] RPM package file
Common option
-qpi,-qpl,-qpc,-qpd
Using the rpm command, you can only query the information of the software package installed by RPM, and the rpm command will not be able to obtain the relevant information if it is installed into the system by other means.
Install or upgrade RPM software
Rpm [options] RPM package file.
Common option
-I,-U,-F
Install upgrade force
-vh shows the progress of installation
Uninstall the specified RPM software
Rpm-e software name
Secondary option
-force,-nodeps,-h,-v,
Rebuild RPM database
[root@localhost] # rpm-- rebuilddb
Or
[root@localhost] # rpm-- initdb
Import verification public key
Root@localhost ~] # rpm-- import / media/cdrom/RPM-GPG-KEY-redhat-release
A method for solving package dependencies
Install multiple software with dependencies
Unload multiple software with dependencies
Ignore dependencies
Combined with the "--nodeps" option, but may cause a software exception
Overview of source code compilation
Advantages of using source code to install software
Get the latest software version and fix bug in time
Customize the software functions flexibly according to the needs of users
Examples of application situations
When installing a newer version of the application
When the currently installed program cannot meet the needs
When you need to add new features to your application
Source code compilation process
Make uninstall uninstall
-next time-
II. YUM installation software
YUM,Yellow dog Updater Modified
Software update mechanism based on RPM package construction
Dependencies can be resolved automatically
All software packages are provided by a centralized YUM software repository
The way the software repository is provided
FTP service: ftp://......
HTTP service: http://......
Local directory: file:///.......
The source of RPM software package
Collection of RPM packages released by CentOS
A collection of RPM packages released by third-party organizations
User-defined collection of RPM packages
Building CentOS 7 Software Repository
The RPM package is from CentOS 7 DVD CD.
Provided to the client through FTP, HTTP, or local directory
Join the unofficial RPM package group in the software repository
Includes all RPM packages that have dependencies
Using createrepo tool to build warehouse data file
YUM cache directory
Store downloaded software packages, warehouse information, and other data
Located at / var/cache/yum/$basearch/$releasever
[root@localhost ~] # yum clean all
Operation
Specify the YUM warehouse location for the client
Configuration file: / etc/yum.repos.d/*.repo
[root@localhost ~] # vi / etc/yum.repos.d/centos7.repo
[base]
Name=CentOS 7.5
Baseurl= ftp://192.168.4.254/centos7
Enabled=1
Gpgcheck=1
Gpgkey= file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
[other]
Name=Other RPM Packages
Baseurl= ftp://192.168.4.254/other
Enabled=1
Gpgcheck=0
Directly use CentOS 7 CD as software repository
1. Insert the CentOS 7 CD into the CD drive
two。 Specify warehouse location, URL address is file:///media/cdrom
[root@localhost ~] # vi / etc/yum.repos.d/local.repo
……
[local]
Name=CnetOS 7.3
Baseurl= file:///media/cdrom
Enabled=1
Gpgcheck=0
Example:
[Testlinux-base]
Name=CentOS-7.5
Baseurl= file:///media/cdrom
Gpgcheck=0
Gpgkey= file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
Enabled=1
Add some knowledge of CD mounting:
1. Insert the CD or virtualize the specified ISO file
2. Operate in LINUX to check how the CD is mounted mount; (type iso9660)
3. The CD can be mounted many times after it is inserted, but the mount point (directory) is different, mount / dev/sr0 / opt/guangpan/
4. If the mount is successful, check it on mount.
About the yum command
Provided by the package yum-3.4.3-150.el7.centos.noarch
Used to access YUM repository, query, download, install and uninstall software packages
Configuration file for yum
Basic setting: / etc/yum.conf
Warehouse setting: / etc/yum.repos.d/*.repo
Log file: / var/log/yum.log
Query software package
Yum list [software name]...
Yum info [software name]...
Yum search...
Query package group
Yum grouplist [package group name].
Yum groupinfo...
Install softwar
Yum install [Software name]
Yum groupinstall
Upgrade softwar
Yum update package name
Yum groupupdate package name
Uninstall the software
Yum remove...
Yum groupremove...
Automatically confirm installation
-y
Yum-y install vsftpd
Assignment:
1. Show the basic process of compiling the installer with the source code, and write out the function of each process.
2. What is the purpose of adding the "--prefix" option when performing the ". / configure" configuration?
3. Install nload and monitor the change of your server traffic within one minute.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.