I have searched for how to close psql port for a while, but most of the answers are talking about closing psql command line using \q, which is not what I am looking for.
My problem is, the postgresql on my laptop are running and listening on port 5432, but I would like to use port 5432 for some other use. Usually I run netstat -plnt to find the process to kill, but in this case the process that is listening on port 5432 does not have a process id...
Any idea on how I can release the port 5432?
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:5432 0.0.0.0:* LISTEN -