zoukankan      html  css  js  c++  java
  • 卸载 nginx 彻底删除

    原文 : http://blog.csdn.net/u010571844/article/details/50819704

    卸载 删除 nginx

    1.删除nginx,–purge包括配置文件
    sudo apt-get --purge remove nginx
    2.自动移除全部不使用的软件包
    sudo apt-get autoremove
    3.罗列出与nginx相关的软件
    dpkg --get-selections|grep nginx

    执行结果:

    stephen@stephen-OptiPlex-390:~$ dpkg --get-selections|grep nginx
    
    nginx                       install
    nginx-common                install
    nginx-core                  install
    4.删除3.查询出与nginx有关的软件
    sudo apt-get --purge remove nginx
    sudo apt-get --purge remove nginx-common
    sudo apt-get --purge remove nginx-core

    这样就可以完全卸载掉nginx包括配置文件


    5.查看nginx正在运行的进程,如果有就kill掉
    ps -ef |grep nginx

    看下nginx还有没有启动,一般执行完1后,nginx还是启动着的,如下:

    stephen@stephen-OptiPlex-390:~$ ps -ef |grep nginx
    root      7875  2317  0 15:02 ?        00:00:00 nginx: master process /usr/sbin/nginx
    www-data  7876  7875  0 15:02 ?        00:00:00 nginx: worker process
    www-data  7877  7875  0 15:02 ?        00:00:00 nginx: worker process
    www-data  7878  7875  0 15:02 ?        00:00:00 nginx: worker process
    www-data  7879  7875  0 15:02 ?        00:00:00 nginx: worker process
    stephen   8321  3510  0 15:20 pts/0    00:00:00 grep --color=auto nginx
    6.kill nginx进程
    sudo kill  -9  7875 7876 7877 7879
    7.全局查找与nginx相关的文件
    sudo  find  /  -name  nginx*
    8.依依删除4列出的所有文件
    sudo rm -rf file

    这样就彻底删除nginx了


  • 相关阅读:
    变量的解构赋值
    vue-progressbar 知识点
    <script>标签里的defer和async属性 区别(待补充)
    管理node.js版本的模块:n
    node 知识点
    让node支持es模块化(export、import)的方法
    jvm 知识点
    前端 术语
    js的严格模式
    commonJS、AMD、es模块化 区别(表格比较)
  • 原文地址:https://www.cnblogs.com/lvgo/p/13275863.html
Copyright © 2011-2022 走看看