1.先執行指令:
1.1 刪除nginx,–purge包含設定檔
<code>sudo apt-<span>get</span><span>--purge remove nginx</span></code>
1.2 自動移除全部不使用的軟體包
<code><span>sudo</span> apt-get autoremove </code>
1.3 羅列出與nginx相關的軟體包
<code>dpkg --<span>get</span>-selections|grep nginx</code>
1.3 羅列出與nginx相關的軟體包
1.3查詢出與nginx有關的軟體<code>执行<span>1.3</span>的结果: stephen@stephen<span>-OptiPlex</span><span>-</span><span>390</span>:~$ dpkg <span>--</span>get<span>-selections</span><span>|</span>grep nginx nginx install nginx<span>-common</span> install nginx<span>-core</span> install </code>
<code>sudo apt-<span>get</span><span>--purge remove nginx</span> sudo apt-<span>get</span><span>--purge remove nginx-common</span> sudo apt-<span>get</span><span>--purge remove nginx-core</span></code>
<code>ps -ef <span>|grep nginx</span></code>
<code><span>stephen</span>@stephen-<span>OptiPlex</span>-<span>390</span>:~$ ps -ef |grep nginx <span>root</span><span>7875</span><span>2317</span><span>0</span><span>15</span>:<span>02</span> ? <span>00</span>:<span>00</span>:<span>00</span> nginx: master process /usr/sbin/nginx <span>www</span>-<span><span>data</span> 7876 7875 0 15:02 ? 00:00:00 nginx: worker process</span><span>www</span>-<span><span>data</span> 7877 7875 0 15:02 ? 00:00:00 nginx: worker process</span><span>www</span>-<span><span>data</span> 7878 7875 0 15:02 ? 00:00:00 nginx: worker process</span><span>www</span>-<span><span>data</span> 7879 7875 0 15:02 ? 00:00:00 nginx: worker process</span><span>stephen</span><span>8321</span><span>3510</span><span>0</span><span>15</span>:<span>20</span> pts/<span>0</span><span>00</span>:<span>00</span>:<span>00</span> grep <span>--color=auto nginx</span></code>
<code><span>sudo</span> kill -<span>9</span><span>7875</span><span>7876</span><span>7877</span><span>7879</span></code>
<code><span>sudo</span> find / -name nginx*</code>
<code><span>sudo</span> rm -rf file</code>
<code><span>sudo</span> apt-get update <span>sudo</span> apt-get install nginx</code>
以上就介紹了ubuntu1404徹底刪除nginx,包含了方面的內容,希望對PHP教學有興趣的朋友有幫助。
🎜