Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Nginx details the installation process.

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

1. Create a directory and download the installation package to the specified directory

Mkdir-p / home/download/tools

Cd / home/download/tools

Execute this command to download the installation package:

Wget http://nginx.org/download/nginx-1.10.3.tar.gz

two。 Resolve installation package dependencies

Just copy and execute.

Yum install pcre-devel openssl-devel-y

3. Check whether the dependency package has been installed

Rpm-qa | egrep "pcre | openssl"

View the returned result

Pcre-7.8-7.el6.x86_64

Openssl-1.0.1e-57.el6.x86_64

Pcre-devel-7.8-7.el6.x86_64

Openssl098e-0.9.8e-20.el6.centos.1.x86_64

Openssl-devel-1.0.1e-57.el6.x86_64

4. Decompress, compile and install

Tar xf nginx-1.10.3.tar.gz

Cd nginx-1.10.3

5. Add nginx to run user www

Useradd-s / sbin/nologin-M www

Id www to view

6. Compile

. / configure (configure compilation parameters) make (compile) make install (copy creation directory file)

. / configure-prefix=/application/nginx-1.10.3-user=www-group=www-with-http_stub_status_module-with-http_ssl_module

7.make&&make install&&echo $?

Create compilation, return value if the final value is 0, the execution is successful.

8. Create a soft connection, start nginx and test it

A. Ln-s / application/nginx-1.10.3/ / application/nginx

B. / application/nginx/sbin/nginx

C. Lsof-iRO 80

Check to see if port 80 is listening.

9. If the installation cannot be compiled, execute the following command

Yum install gcc gcc-c++ automake autoconf-y

10. Use your own configured public network address for testing.

In the browser (do not use win10 with your own browser, your own test is not successful.) Use Google, Sogou, 360, Firefox. Enter the configured public network ip enter.

The following page indicates that the installation is successful.

Welcome to nginx!

If you see this page, the nginx web server is successfully installed and working. Further configuration is required.

For online documentation and support please refer to nginx.org.

Commercial support is available at nginx.com.

Thank you for using nginx.

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.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report