当前位置:Gxlcms > PHP教程 > ubuntu下使用apt方式安装、卸载nginx

ubuntu下使用apt方式安装、卸载nginx

时间:2021-07-01 10:21:17 帮助过:5人阅读

ubuntu和debain下的apt方式安装软件很方便,特别是对于新手安装和卸载nginx。
由于nginx不能动态添加模块,所以会经常安装和卸载、升级。

  • apt安装nginx方法
sudo apt-add-repository ppa:nginx/development
sudo apt-get update
sudo apt-get install nginx
  • apt卸载nginx方法

卸载方法1.
删除nginx,保留配置文件

sudo apt-get remove nginx

删除配置文件

rm -rf /etc/nginx

卸载方法2.
删除nginx连带配置文件

sudo apt-get purge nginx # Removes everything.

卸载不再需要的nginx依赖程序

sudo apt-get autoremove

').addClass('pre-numbering').hide(); $(this).addClass('has-numbering').parent().append($numbering); for (i = 1; i <= lines; i++) { $numbering.append($('
  • ').text(i)); }; $numbering.fadeIn(1700); }); });

    以上就介绍了 ubuntu下使用apt方式安装、卸载nginx,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。

  • 人气教程排行