专注于 JetBrains IDEA 全家桶,永久激活,教程
持续更新 PyCharm,IDEA,WebStorm,PhpStorm,DataGrip,RubyMine,CLion,AppCode 永久激活教程

How to install nginx in Ubuntu

The steps for installing the nginx on Ubuntu below.

1、install the packages first.

apt-get install gcc
apt-get install libpcre3 libpcre3-dev
apt-get install zlib1g zlib1g-dev
apt-get install openssl openssl-dev

2、download the source code of nginx from the website http://nginx.org/en/download.html

3、 uncompress the downloaded nginx file.

tar zxvf nginx-1.8.0

4、install nginx.

su root #using root user to install nginx
cd /home/pinxiong/pinxiong/nginx-1.8.0/ #the directory is the unpressed nginx's dictory.
./configure
make
make install

5、check if nginx configure is right.

root@ubuntu:/usr/local/nginx# ./sbin/nginx -t
nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful

6、check if nginx had started.

root@ubuntu:/usr/local/nginx# ps -ax | grep nginx
17050 ?        Ss     0:00 nginx: master process ./sbin/nginx
17051 ?        S      0:00 nginx: worker process
17052 ?        S      0:00 nginx: worker process
17053 ?        S      0:00 nginx: worker process
17054 ?        S      0:00 nginx: worker process
17055 ?        S      0:00 nginx: worker process
17056 ?        S      0:00 nginx: worker process
17057 ?        S      0:00 nginx: worker process
17058 ?        S      0:00 nginx: worker process
17059 ?        S      0:00 nginx: worker process
17060 ?        S      0:00 nginx: worker process
17062 pts/1    S+     0:00 grep --color=auto nginx

7、check if nginx can work well.

open your browser and then type the web address localhost/index.html . It’s OK if you can see a webpage showing “Welcome to nginx!“, or failed otherwise.

文章永久链接:https://tech.souyunku.com/23897

未经允许不得转载:搜云库技术团队 » How to install nginx in Ubuntu

JetBrains 全家桶,激活、破解、教程

提供 JetBrains 全家桶激活码、注册码、破解补丁下载及详细激活教程,支持 IntelliJ IDEA、PyCharm、WebStorm 等工具的永久激活。无论是破解教程,还是最新激活码,均可免费获得,帮助开发者解决常见激活问题,确保轻松破解并快速使用 JetBrains 软件。获取免费的破解补丁和激活码,快速解决激活难题,全面覆盖 2024/2025 版本!

联系我们联系我们