安装步骤
- 添加源默认情况Centos7中无Nginx的源
rpm -Uvh http://nginx.org/packages/centos/7/noarch/RPMS/nginx-release-centos-7-0.el7.ngx.noarch.rpm
- 测试是否添加源
yum search nginx
- 安装Nginx
yum install -y nginx
4.启动Nginx并设置开机自动运行
sudo systemctl start nginx
sudo systemctl enable nginx
5.查看是否安装成功
ps -ef|grep nginx
7.一些常用的搜索命令
根据文件名搜索
find / -name mysql
find / -name 'mysql*'
whereis nginx