Common software Installation under Linux

Source: Internet
Author: User

The installation process for MySQL:

Unzip the MySQL installation package:

TAR-XVF mysql-5.5.53-1.linux2.6.x86_64.rpm-bundle.tar-c MySQL

The RPM command uses

Syntax: RPM-IVH xxxx.rpm

Common parameters:

I: Installing the Application (install)

E: Uninstalling the application (erase)

VH: Show installation Progress (verbose hash)

U: Upgrade Package (update)

QA: Show all installed packages (query all)

Example: Rpm-ivh mysql-client-5.5.53-1.linux2.6.x86_64.rpm

RPM Way to install MySQL

RPM installation Syntax: RPM-IVH xxxx.rpm

Steps to install MySQL

RPM-IVH mysql-client-5.5.53-1.linux2.6.x86_64.rpm

RPM-IVH mysql-server-5.5.53-1.linux2.6.x86_64.rpm

Start MySQL server:service mysql start

To modify the root user's password: mysqladmin-u root password ' root '

Login Mysql:mysql-uroot-proot

Uninstalling the database: To stop the MySQL service in advance

Service MySQL stop stop mysql command

Service MySQL Status View the state of one of the services

Rpm-qa|grep-i MySQL to see what services MySQL has

Uninstall MySQL-corresponding service

Rpm-e mysql-server-5.5.53-1.linux2.6.x86_64

Rpm-e mysql-client-5.5.53-1.linux2.6.x86_64

Also need to delete the MySQL corresponding folder

Find/-name MySQL

Rm-rf/var/lib/mysql

Rm-rf/var/lib/mysql/mysql

Rm-rf/usr/lib64/mysql

Yum Way to install MySQL

Yum Install Mysql-server

Start command after installation: Service mysqld start

/etc/init.d/mysqld Status View MySQL run status

Mysqladmin-uroot Password Root creation administrator

Mysql-uroot-proot login MySQL

To uninstall MySQL:

Yum Remove mysql-server-5.1.73-7.el6.x86_64

Unloading MySQL dependencies at the same time

Rpm-qa|grep-i MySQL to see what services MySQL has

Yum Remove mysql-libs-5.1.73-8.el6_8.x86_64

Yum Remove mysql-5.1.73-8.el6_8.x86_64

Yum Remove perl-dbd-mysql-4.013-3.el6.x86_64

Yum Remove mysql-server-5.1.73-8.el6_8.x86_64

Attention:

Sometimes when you install some files with Yum, the following conditions occur:

Another app is currently holding the Yum lock; Waiting for it to exit ...

The other application Is:packagekit

You can disable the Yum process by forcing: Rm-f/var/run/yum.pid

Then you can use Yum.

Apache2 Installation:

1) Unzip TAR-ZXVF httpd-2.4.25.tar.gz

2) Installation

./configure

Error: Configure:error:APR not found. Please read the documentation.

Consult the documentation later to discover the need to install a lot of dependencies beforehand

3) APR

TAR-ZXVF apr-1.5.2.tar.gz

./configure--PREFIX=/USR/LOCAL/APR

--prefix indicates to which directory the APR is installed, we recommend that you add this parameter to set the installation directory so that subsequent lookups can be used

Make

Make install

Run when the APR is installed./configure--PREFIX=/USR/LOCAL/APR times the following error:

Configure:error:in '/software/apr-1.5.2 ':

Configure:error:no acceptable C compiler found in $PATH see ' config.log ' for more details

Causes and solutions:

You do not have any C-language compilers installed in your machine, you can install GCC. GCC-related packages can be found on the installation disk to install, but it will be cumbersome, because the associated packages will be more. If you can surf the Internet, it is a good choice to use Yum installation: Yum install GCC

After you install GCC, re-execute./configure--PREFIX=/USR/LOCAL/APR command will not error.

4) Install httpd again

./configure--prefix=/usr/local/apache--WITH-APR=/USR/LOCAL/APR

Error: Configure:error:apr-util not found. Please read the documentation.

5) Apr-util

TAR-ZXVF apr-util-1.5.4.tar.gz

./configure--prefix=/usr/local/apr-util--with-apr=/usr/local/apr/bin/apr-1-config

Make

Make install

6) Install httpd again

./configure--prefix=/usr/local/apache--with-apr=/usr/local/apr/bin/apr-1-config--with-apr-util=/usr/local/ Apr-util/bin/apu-1-config

Also error:

Configure:error:pcre-config for Libpcre not found. PCRE is required and available from http://pcre.org/

7) Pcre

TAR-ZXVF pcre-8.39.tar.gz

./configure--prefix=/usr/local/pcre--with-apr=/usr/local/apr/bin/apr-1-config

Make

Make install

Installation pcre execution./configure--prefix=/usr/local/pcre--with-apr=/usr/local/apr/bin/apr-1-config, the following error is reported:

Configure:error:You need a C + + compiler for C + + support.

Causes and solutions:

You do not have any C + + language compilers installed in your machine, you can install the C + + compiler by ordering yum install gcc-c++.

After you install C + +, re-execute./configure--prefix=/usr/local/pcre--with-apr=/usr/local/apr/bin/apr-1-config command will not error.

8) Install httpd again

./configure--prefix=/usr/local/apache--with-apr=/usr/local/apr/bin/apr-1-config--with-apr-util=/usr/local/ Apr-util/bin/apu-1-config--with-pcre=/usr/local/pcre/bin/pcre-config

Finally, no problem.

Make

Make install

9) Modify configuration file:/usr/local/apache/conf/httpd.conf

Listen 9999

Start Apache2

./apachectl-k Start

The error is as follows:

AH00557:httpd:apr_sockaddr_info_get () failed for KGC

AH00558:httpd:Could not reliably determine the server ' s fully qualified domain name, using 127.0.0.1. Set the ' ServerName ' directive globally to suppress this message

To modify the configuration/usr/local/apache/conf/httpd.conf, add the following:

ServerName localhost:9999

Start again, view port status by NETSTAT-LTNP command after startup

./apachectl-k Start/stop/restart indicates start/stop/restart

Nginx Installation:

TAR-ZXVF nginx-1.8.1.tar.gz

Several preconditions before compiling the installation:

Yum Install OpenSSL

Yum Install Openssl-devel

Yum Install zlib

Yum Install Zlib-devel

Yum Install Pcre

Yum Install Pcre-devel

Yum Install gcc-c++

./configure--prefix=/usr/local/nginx

Make

Make install

Switch to nginx installation directory:/usr/local/nginx

Inside of the important folder

Conf:nginx.conf

Html

Logs

Sbin

Start: Sbin/nginx

To detect if Nginx started successfully: Ps-ef|grep Nginx, the following two processes indicate a successful start

Nginx:master Process Sbin/nginx

Nginx:worker process

How to modify Port conf/nginx.conf

Verify that the modified configuration file is legitimate: sbin/nginx-t

Sbin/nginx-s Stop (quit, reload)

Common software Installation under Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.