gpt4 book ai didi

nginx 已卸载,本地主机 :8080 still showing nginx welcome page

转载 作者:行者123 更新时间:2023-12-01 13:36:35 26 4
gpt4 key购买 nike

我使用 brew uninstall nginx 从 brew 卸载了 nginx,但是当我转到 http://localhost:8080 时,我仍然收到“欢迎使用 Nginx”消息.

我已经做了:

  • 重启我的电脑(3 次)
  • 使用 rm -rf/usr/local/etc/nginx 删除了额外的 nginx 文件夹
  • 使用 sudo find/-name "nginx" 从根文件夹中到处寻找 nginx。没有任何显示。
  • /Library/LaunchAgents/~/Library/LaunchAgents/ 中寻找 nginx .plist 文件,但没有。

我在 macOS High Sierra 上。

谢谢!

最佳答案

也有这个恼人的问题,发现是httpd包导致这个页面在卸载了nginx后也出现了。

虽然强行关闭/卸载 httpd 可以解决表面上的问题,但根本问题实际上是 usr/local/var/www/index.html 的通用启动文件,有已被硬编码为包含“欢迎使用 nginx”消息,并且即使在卸载 nginx 后仍将保持这种状态。 Apache (httpd) 服务也会在启动时调用 index.html 文件,这使得它看起来好像是 nginx 呈现该文件。

不太清楚为什么 nginx 在卸载时不会自动清空文件,而是在卸载 nginx 后手动更改/删除该文件的内容,您的问题应该得到解决:)

这篇文章还解决了一个类似的问题:Brew Install Httpd: Welcome to Nginx?

关于nginx 已卸载,本地主机 :8080 still showing nginx welcome page,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51040372/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com