Install NGINX via YUM on CENTOS

WBOY
Release: 2016-07-28 08:27:52
Original
977 people have browsed it

It is very convenient to install nginx using YUM. All it takes is simple configuration!

The first step is to configure the nginx source

Create a source configuration file nginx.repo in the /etc/yum.repos.d/ directory:
cd /etc/yum.repos.d/ <br> vim nginx.repo
Fill in the following content:

[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/centos/releaseve r /basearch/
gpgcheck=0
enabled=1

Save, a /etc/yum.repos.d/nginx.repo file will be generated.

Second step, install Nginx

Execute the following command to automatically install Nginx:
yum install nginx -yyum install nginx -y

After the installation is complete, you can start Nginx directly as follows: /etc/init.d/nginx start
/etc/init.d/nginx start


Now that Nginx has been started, you can see the Nginx welcome page by directly accessing the server.

Nginx command and configuration file location: /etc/init.d/nginx start # 启动Nginx服务
/etc/init.d/nginx stop # 停止Nginx服务
/etc/nginx/nginx.conf # Nginx配置文件位置

/etc/init.d/nginx start # Start Nginx service

/etc/init.d/nginx stop # Stop Nginx service

/etc/nginx /nginx.conf # Nginx configuration file location🎜🎜🎜').addClass('pre-numbering').hide(); $(this).addClass('has-numbering').parent().append($numbering); for (i = 1; i 🎜').text(i)); }; $numbering.fadeIn(1700); }); }); 🎜 🎜 The above introduces the installation of NGINX through YUM on CENTOS, including the relevant content. I hope it will be helpful to friends who are interested in PHP tutorials. 🎜 🎜 🎜
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!