The installation method of PM package is created by REDHAT company. This installation method makes it extremely easy to install applications. Now many LINUX distribution companies have also added RPM installation methods to their products, so that the installation of RPM packages has become a standard for LINUX program installation.
Before installing the RPM package, we need to be familiar with some of the command forms and parameters of RPM. In the LINUX text interface, enter the following command:
rpm -help
You can see that there are many parameters. Use the following command to display the HELP file in split screen:
rpm -help |more
Among the many parameters of RPM, the most common ones are -e, -ivh, and -ql.
These three commands are to delete installed RPM packages, install RPM packages, and query installed RPM packages. After understanding the use of these three commands, we can install the program.
First, we need to find the installation file, which is the RPM package to be installed. This package can be obtained from many FTP sites, and these RPM packages can also be found in LINUX versions distributed by many companies. Remember, you must ensure your ROOT status before installation. Only the ROOT identity can load hardware, install programs, and other operations. Let's take installing the php-3.0.7.i386.rpm package as an example to explain how to install it. In the command line, type the following command to start the PHP installation:
rpm -ivh php-3.0.7.i386.rpm
You will see a progress bar, which is used to indicate the progress of the installation. When the progress bar reaches the end, php-3.0.7.i386.rpm is installed.
In this RPM package of PHP, because it supports relatively few options, it generally cannot meet our requirements. Then we can also customize and compile PHP (only suitable for users using REDHAT6.1).
The specific steps are as follows:
First obtain the PHP source code package, unzip it and enter the package.
Modify the apxs file in the /usr/sbin/ directory. Change:
my $CFG_LIBEXECDIR =modules; #substituted via APACI install
to:
my $CFG_LIBEXECDIR =/usr/lib/apache; #substituted via APACI install