centoskill

How can I find a specified service running on a port 443 CentOS and kill it?


I am getting the following error when restarting Apache (as root):

service httpd restart

Output:

Stopping httpd:                                            [  OK  ]
Starting httpd: (98)Address already in use: make_sock: could not bind to address 0.0.0.0:443
no listening sockets available, shutting down
Unable to open logs

How can I find and kill the service?


Solution

  • Okay, it’s solved now.

    I did:

    service httpd stop
    

    Then

    service httpd start

    I finally restarted the httpd and the problem was fixed (I don't know where the problem was, but changing the port and then again putting it back to default fixed the issue):

    service httpd restart