Linux-常用命令大全-ZThttps://blog.csdn.net/weixin_45075226/article/details/146059491
补充常用命令:
【清屏】(Ctrl+L)
clear
或
reset【列出命令】
# 列出所有包含nginx的包
apt list nginx*【卸载】
在 Debian 中卸载 nginx 1263-3+deb13u2 的完整命令:
<p style="color: rgb(28, 31, 35); font: 400 16px / 24px ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; white-space: normal; flex: 0 1 auto; flex-direction: row; justify-content: normal; align-items: normal; padding: 0px; margin: 0px; background-image: none; background-position: 0% 0%; background-size: auto; background-repeat: repeat; background-attachment: scroll; background-origin: padding-box; background-clip: border-box;">基本卸载(保留配置文件)sudo apt remove nginx完全卸载(删除配置文件)
sudo apt purge nginx清理依赖包
sudo apt autoremovesudo apt autoclean检查是否还有其他 nginx 相关包
dpkg -l | grep -i nginx如果有其他 nginx 包,一并卸载
sudo apt purge nginx-common nginx-core nginx-full nginx-extras验证卸载结果
which nginx
nginx -v如果卸载成功,which nginx不会返回路径,nginx -v会提示命令未找到。