I'm trying to run a local apache server on a dedicated ubuntu 22.04.1 LTS
server machine. However, I can't get apache2 to start. Every time I try sudo systemctl restart apache2
I'm told that it failed to start because another service is listening on port 80.
(98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:80
apachectl
(98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
After running sudo lsof -i -P -n
I can see a COMMAND
called chipper
is running as root and hogging port 80.
sudo kill [that pid]
worked, but it started itself back up before i could restart apache. This isn't a package I recognize, and neither sudo apt remove chipper
or sudo snap remove chipper
were helpful. How can I find out what package this service is a part of and determine what action I want to take to free this port?
UPDATE:
Chipper is a part of DDL's Escape Pod for Vector. Though my source problem is now resolved, I'd still like to know how to find a COMMAND
's source package, if possible.
UPDATE 2:
The idea behind this question is finding the source of a command given only a command name and PID. I was able to get apache to restart fast enough to outpace the port 80 hog, and that allowed me to see the source in the logs when it failed to run (because now apache has port 80). Originally, all i had was a field called COMMAND
and PID,
so I think it would be useful to know how to find the source package for the output of the sudo lsof -i -P -n
command. This is not about finding the source package of an existing file, because if I had the file from the start I would have seen the directory it was contained in (in this case, ~/wire-pod/
would have answered my question before i even asked it).
dpkg -S
to see if it was provided by some package. – muru Jun 06 '23 at 04:26chipper
, the file is also likely to be namedchipper
. You can check what file is actually running usingls -l /proc/<pid>/exe
– muru Jun 06 '23 at 04:56ls -l /proc/<pid>/exe
followed bydpkg -S
on the identified file. Thanks again! – officialrewind Jun 06 '23 at 05:07