I made an image of one of my private Amazon EC2 image that runs one website, then started installing redmine. After all the installation is done, it is about to restart Apache I encountered the following issue(sorry you might have to zoom in to see the screenshot):
My understanding of what was happening is that apache2 is not running but it is listening to port 80. Then I tried:
which gives the same confusing but consistent conclusion, apache2 is not running, but I am sure it is process 18304 which is apache2 listening to port 80.
Eventually, I had to kill the process and restart apache which worked.
Could someone explain to me what might have caused this and a fix?
Update1:
Following synthesizerpatel suggestion to use lsof.
This is exactly the same problem with different process as before.