nixCraft has posted yet another tutorial on how to see what programs are listed on a certain port on FreeBSD.
I’m a new FreeBSD Unix system user. How can I find out the process/programs names listing on a certain port on a FreeBSD Unix systems using command line? How do I lookup the process which is currently bound to the given network port on a FreeBSD server?
Tutorial details Difficulty Easy (rss) Root privileges Yes Requirements none Estimated completion time 5m
You can use any one of the following command-line tools that displays network connections, routing tables, and a number of network interface statistics on a FreeBSD operating systems.
- netstat command – Use to see network status including open ports, tcp/udp connections, and more.
- sockstat command – Show open sockets.
- lsof command – List open files such as network sockets and files on disks.
FreeBSD has a command called sockstat and netstat tools. These are already on a standard FreeBSD install. You need to install the lsof tool from ports collection.
View the full tutorial here: http://www.cyberciti.biz/faq/freebsd-unix-find-the-process-pid-listening-on-a-certain-port-commands/