1.Ubuntu下安装Nginx比较简单
敲入下列命令即可:
sudo apt-get update
sudo apt-get install nginx
2.Ubuntu下卸载,稍不注意就会入坑
sudo apt-get remove nginx nginx-common
sudo apt-get purge nginx nginx-common
sudo apt-get autoremove
sudo apt-get remove nginx-full nginx-common
上面的命令基本上都能解决你在Ubuntu下安装卸载Nginx的问题。