echo "[netstat]"
netstat -s
echo "[ports]"
(netstat -Wna -f inet; netstat -Wna -f inet6) | grep "^tcp"
(netstat -na -f inet; netstat -na -f inet6) | grep "^tcp"
echo "[ps]"
# Dont use "args". "command" works also in FreeBSD 4.x.
ps -ax -ww -o pid,ppid,user,start,state,pri,pcpu,cputime,pmem,rss,vsz,command