Linux one-click installation of web environment Raiders (Alibaba Cloud Server)

One-click installation package download : Click here to download 

 

Installation Instructions

1. This installation package can be deployed and installed on all linux systems of Alibaba Cloud. The software and versions included in this installation package are:

nginx:1.0.15、1.2.5、1.4.4

apache:2.2.22、2.4.2

mysql:5.1.73、5.5.35、5.6.15

php:5.3.18、5.4.23、5.5.7

PHP extensions: memcache, Zend Engine/ OPcache

ftp : (yum/apt-get install)

phpwind:8.7 GBK

phpmyadmin:4.1.8

 

2. Please use the latest one-click installation package script to install. There are bugs in previous versions, which will cause abnormal installation and confusion in the installation environment.

 

3. Execute the one-click installation package (./install.sh), which will automatically clean up the environment installed by the one-click installation package.

     If you have already installed the one-click installation package, perform the installation again. If you have important data, please back up the /alidata directory by yourself.

4. The one-click installation package will install the software in the /alidata directory.

     If your system does not have a data disk, the one-click installation package will install the software to the system /alidata directory.

     If there is a data disk in your system, and the data disk has not been formatted and mounted. Then the one-click installation package will automatically format the first data disk for you and mount it in the /alidata directory.

     If a data disk exists in your system, the first data disk has been formatted and mounted. The one-click installation package will mount the first data disk to the /alidata directory again, which does not affect the use of your previous mounted directory. For example, as shown in the figure below, the mnt directory has been mounted before installation. After installation, the one-click installation package mounts the /alidata directory again.

 

If there is a data disk in your system, and the data disk has been formatted, but no data disk is mounted. The one-click installation package will mount the first data disk to the /alidata directory.

 

5. How to uninstall the one-click installation package?

Uninstallation can be done by executing the following command:

chmod  777 -R sh-1.3.0/

cd sh-1.3.0 /

./uninstall.sh

 

Well, let's go to our detailed installation steps, come on~~!

 

First, prepare the tools to connect to the linux server. It is recommended to use xshell and xftp.

 

xshell  is a powerful secure terminal emulation software that supports SSH1, SSH2, and TELNET protocols for Microsoft Windows platforms.
Download address:
http://www.newhua.com/soft/36383.htm

Xftp  is a powerful SFTP and FTP file transfer software based on MS windows platform.
Download address:
http://www.newhua.com/soft/143.htm

 

According to the download address provided above, first install xshell (basically click Next until the installation is complete):

 

Click Next --> At this time, select "free for Home/School" (free version).

 

Then click Next-->Next-->Next-->install to install (you can also choose the language environment after xshell installation, friends who are familiar with English, you can choose the English option).

 

Click finish to complete the xshell installation.

 

Then we can see the following interface.

 

Next, install xftp (a small tool for uploading files to a linux server). Installing xftp is also very simple. Basically, click Next until the installation is complete.

 

Click Next  --> At this time, select "free for Home/School", (free version).

 

Click Next  -->Next -->Next-->install (you can also choose the language environment after xshell is installed, friends who are familiar with English can choose the English option).

 

Click finish to complete the installation.

 

Then we can see the following bound.

 

Then we open xshell and set the cloud server login information.

 

Set the server account password.

 

 

 Set the character set encoding (if the character set encoding is not set, Chinese characters will be displayed as garbled characters in xshell).

 

After setting, click ok to save.

 

 Everything is ready, let's connect to see the true face of the cloud linux server!

It's not dark in the middle of winter, there is nothing, this is the shell of linux. What is the shell (shell) in the end?

 

 Shell is the user interface of the system, providing an interface for users to interact with the kernel. It receives commands entered by the user and sends them to the kernel for execution.

As a dedicated operating system for servers, linux mainly silently stays in the computer room to provide various network services. In order to save system resources, gorgeous user desktops like windows are not loaded by default. Of course, more and more users now use linux as their daily home office operating system, so they have super gorgeous desktops like gnome and kde. However, it is recommended to use the command line interface as a server. After all, it saves some resources and the website may be opened faster!

 

Go to the home directory (/home) by typing the following command

 

Enter the command: cd

 

Use xftp to upload the environment installation files.

 

Back to the shell interface, use the ll command to see the situation

 

Enter the command: ll

 

Is there an additional sh-1.3.0 directory, 1.3.0 is the version number of our one-click installation package. Please download the latest version and install, the version update introduction, we can view it in change.log. I also hope that you will give more feedback on the one-click installation package. (In addition, friends who are familiar with linux can directly use the wget command to download our installation package without installing Xftp, which is more convenient.)

 

Next, follow the instructions and enter the installation command step by step (the following is an installation example under the redhat system).

 

Enter the command: chmod –R 777 sh-1.3.0

                 cd sh-1.3.0

                  ./install.sh

 

A selection prompt appears, enter the web server selection interface.

 

Here you can choose apache or nginx server according to your needs, here is the introduction of 2 servers:


apachehttp://baike.baidu.com/view/28283.htm
nginxhttp://baike.baidu.com/view/926025.htm

 

Quote:

 

In the case of high concurrent connections, Nginx is a good alternative to Apache server. Nginx can also be used as a Layer 7 load balancing server. According to my test results, Nginx 0.8.46 + PHP 5.2.14 (FastCGI) can withstand more than 30,000 concurrent connections, which is equivalent to 10 times that of Apache in the same environment.

 

Here we choose nginx, enter 1, and press Enter (if you enter nothing, enter directly, or enter wrong characters, nginx is selected by default) 

 

Then we choose the version of nginx to install (if the web server chooses apache, the message here is the version to install apache), there are three versions 1.0.15/1.2.5/1.4.4 that can provide us Select, here we choose version 1.2.5, then enter 2 and press Enter (if you enter nothing, enter directly, or enter wrong characters, version 1.0.15 is selected by default)

 

 

 Then we choose the version of php to install. There are three versions of 5.3.18/5.4.23/5.5.7 to choose from. Here we choose version 5.5.7, enter 3 and press Enter (if everything is If you don't enter it, press Enter directly, or enter the wrong character, the default version 5.3.18 is selected)

 

 

Then we choose the version of mysql to be installed. There are three versions of 5.1.73/5.5.35/5.6.15 to choose from. Here we choose version 5.1.73, enter 1 and press Enter (if everything is If you don't enter it, press Enter directly, or enter the wrong character, the default version 5.1.73 is selected)

 

 

Then you can see that the version we just selected is as follows, we enter y or Y to install.

 

 

At this point, we have officially entered the environment installation link. You can take a break with a cup of tea. This process usually takes about half an hour.

 

Notice:

1. Please install when the network is unobstructed. Do not forcefully terminate the installation process (forcibly close the installation window or ctrl+c forcibly terminate the installation process), which will lead to installation failure and unpredictable installation exceptions!

2. Before installation, it is best to take a snapshot with the system disk. If it is abnormal, it is convenient to roll back the system.

 

In order to prevent disconnection from the server, you can open a new shell window, move the mouse to the window tab bar, and right-click, as shown in the following figure:

 

 

As you can see, a new window has opened.

 

Enter the top command

  

You can see the system resource statistics that have been beating.

 

All right. Let's wait quietly when we're done! The program is automatically compiling and installing the service!

 

At this interface, the installation is over. We can enter the following command to verify that the installation has been successful again:

 

Enter the command: netstat -tunpl

 

We can see the running services and ports: port 9000 is the php process service, port 3306 is the mysql service, port 80 is the nginx service, and port 21 is the ftp service.

 

If you see the above information, the installation is normal. One thing to note here is that if you choose to install apache, there is no port 9000 above. Why choose to install apache, there is no php process service on port 9000? This is because the integration method of nginx+php is different from that of apache+php. Interested friends can study it by themselves, and I will not introduce it here.

 

Everyone has questions. Then how do I log in to ftp and mysql?

 

Type in the command line:  cat account.log

 

did you see it

The username for ftp is: www The username for mysql is: root The password is on the screen!




In addition, we can also view the version information of the software just installed in cat /alidata/website-info.log.

 

All right. All configuration has been done. Is not it simple!

 

Next, we can visit the phpwind forum and phpmyadmin installed by default in the one-click installation package. 

Enter your domain name or ip directly in the browser, if it is the first time to visit phpwind, it will automatically jump to the installation page.

If you are stuck when accessing and the page does not appear, check the firewall, and set or close the firewall yourself.

 

Click "Accept" to install.

 

Then select the database type as mysql, and fill in the username and password in the account.log for the database user name and database password. Then set the database name, administrator account and password according to your own requirements.

 

After filling in the information, click Next to complete the installation.

 

Next, we visit phpmyadmin, type our domain name or ip+phpmyadmin path in the browser, and then we can access the phpmyadmin we installed.

 

Enter the mysql username and password to log in.

 

Finally, we can operate and manage our mysql here. It's simple and convenient.

 

----------------------------------------------------------------------

Website directory: /alidata/www
Server software directory: /alidata/server

Mysql  directory/alidata/server/mysql

Php directory/alidata/server/php

 

If nginx is selected, there will be an nginx directory in  /alidata/server/nginx/

Nginx  configuration file is at /alidata/server/nginx/conf

Nginx virtual hosts add you can modify /alidata/server/nginx/conf/vhosts/phpwind.conf

 

If apache is selected, there will be an httpd directory in  /alidata/server/httpd

The apache  configuration file is at /alidata/server/httpd/conf

apache virtual host add you can modify /alidata/server/httpd/conf/vhosts/phpwind.conf

 

A summary of each service operation command:

 

nginx

/etc/init.d/nginx start/stop/restart/reload)

 

apache:

/etc/init.d/httpd start/stop/restart/...

 

mysql:

/etc/init.d/mysqld  start/stop/restart/...

 

php-fpm:

/etc/init.d/php-fpm  start/stop/restart/...

 

ftp:

/etc/init.d/vsftpd  start/stop/restart/...

 

For example to start nginx:

/etc/init.d/nginx start

 

 

 

To install nginx, see the previous blog post http://www.cnblogs.com/radio/p/3782280.html, just add a module when installing config:

./configure --prefix=/usr/local/nginx --add-module=/usr/local/fastdfs-nginx-module/src

Result output: 

copy code
adding module in /usr/local/fastdfs-nginx-module/src/
 + ngx_http_fastdfs_module was configured
checking for PCRE library ... found
checking for PCRE JIT support ... not found
checking for md5 in system md library ... not found
checking for md5 in system md5 library ... not found
checking for md5 in system OpenSSL crypto library ... not found
checking for sha1 in system md library ... not found
checking for sha1 in system OpenSSL crypto library ... not found
checking for zlib library ... found
creating objs/Makefile

Configuration summary
  + using system PCRE library
  + OpenSSL library is not used
  + using builtin md5 code
  + sha1 library is not found
  + using system zlib library

  nginx path prefix: "/usr/local/nginx"
  nginx binary file: "/usr/local/nginx/sbin/nginx"
  nginx configuration prefix: "/usr/local/nginx/conf"
  nginx configuration file: "/usr/local/nginx/conf/nginx.conf"
  nginx pid file: "/usr/local/nginx/logs/nginx.pid"
  nginx error log file: "/usr/local/nginx/logs/error.log"
  nginx http access log file: "/usr/local/nginx/logs/access.log"
  nginx http client request body temporary files: "client_body_temp"
  nginx http proxy temporary files: "proxy_temp"
  nginx http fastcgi temporary files: "fastcgi_temp"
  nginx http uwsgi temporary files: "uwsgi_temp"
  nginx http scgi temporary files: "scgi_temp"
copy code
Then make, make install is OK

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326606641&siteId=291194637