DEV Community

killDevils
killDevils

Posted on • Updated on

Bash | Find out the usage of a certain PORT

When I was trying to run acme.sh to generate SSL certification, I got an error:

[Sat May  9 18:54:10 HKT 2020] tcp port 80 is already used by 
[Sat May  9 18:54:10 HKT 2020] Please stop it first
[Sat May  9 18:54:10 HKT 2020] _on_before_issue.

I believe it is expected to show the service which is using port 80 in the first line, but nothing at all. I have to find out my self.

sudo netstat -tulpn | grep :80

I got the output:

tcp6       0      0 :::80                   :::*                    LISTEN      10541/apache2

Oh, yes, Apache2. I wanna shut it down temporally:

sudo systemctl stop apache2

Now, generate cert again:

~/.acme.sh/acme.sh --issue -d mydomain.me --standalone --keylength ec-256

Latest comments (0)