linux下nginx安裝

1.yum安裝

yum安裝  http://nginx.org/packages/centos/7/noarch/RPMS/

第一步:

安裝命令: yum localinstall http://nginx.org/packages/centos/7/noarch/RPMS/nginx-nr-agent-2.0.0-12.el7.ngx.noarch.rpm

檢測是否安裝成功

yum repolist enabled | grep 'nginx*'

第二步:

安裝nginx   yum -y install nginx

啟動nginx   systemctl nginx start / restart   或者  service nginx start / restart

設置nginx服務開機自動開啟  systemctl enabled nginx.service

檢測nginx開機啟動是否成功  systemctl list-dependencies | grep nginx

 

2.源碼安裝。。

posted @ 2018-07-14 16:56  侠岚之弋痕夕  阅读(278)  评论(0编辑  收藏  举报
Where is the starting point, we don't have a choice, but the destination where we can pursue!