猫箱内の巴托拉

Ubuntu使用apt安装和卸载nginx
姑且就当做记事本写了。今天手头上有个4核4G内存的测试用云主机,顺手装了Ubuntu 16.04 64位的系统。首...
扫描右侧二维码阅读全文
09
2017/11

Ubuntu使用apt安装和卸载nginx

请输入图片描述

姑且就当做记事本写了。
今天手头上有个4核4G内存的测试用云主机,顺手装了Ubuntu 16.04 64位的系统。

首先安装如下

apt-add-repository ppa:nginx/development
apt-get update
apt-get install nginx

即可安装成功,访问IP的80口能提示:

Welcome to nginx! If you see this page, the nginx web server is
successfully installed and working. Further configuration is required.

For online documentation and support please refer to nginx.org.
Commercial support is available at nginx.com.

Thank you for using nginx.

卸载方式如下

删除nginx,保留配置文件

apt-get remove nginx

删除配置文件

rm -rf /etc/nginx

或者用以下方法

删除nginx连带配置文件

apt-get purge nginx # Removes everything.

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

apt-get autoremove
Last modification:January 9th, 2019 at 11:31 am
随意啦,随意赞赏咱

Leave a Comment

One comment

  1. 伊撒尔

    测试一下下gravatar的头像(⊙o⊙)…