Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unexpected used port 80 on macOS with "It works" result

I'm using macOS and I'm just wondering why port 80 is already used as I need to install my own nginx (as docker container) server. Going to http://localhost shows me "It works!". But I don't understand where this comes from, as I didn't installed anything by myself. I thought it could be an Apache server shipped with macOS.

So I did

$ sudo lsof -i:80

And I got this result, which I do not understand:

COMMAND  PID USER   FD   TYPE             DEVICE SIZE/OFF NODE NAME
httpd   9283 root    4u  IPv6 0x2e000a8d22b1a699      0t0  TCP *:http (LISTEN)
httpd   9292 _www    4u  IPv6 0x2e000a8d22b1a699      0t0  TCP *:http (LISTEN)
httpd   9307 _www    4u  IPv6 0x2e000a8d22b1a699      0t0  TCP *:http (LISTEN)
like image 537
user3142695 Avatar asked Oct 16 '17 12:10

user3142695


1 Answers

There is, indeed, a built-in Apache server inside macOS. To stop it, enter the following command to Terminal:

sudo apachectl stop
like image 142
Tamás Sengel Avatar answered Sep 25 '22 22:09

Tamás Sengel