<p>As root, run:</p>
<pre><code>netstat -tunap
</code></pre>
<p>you should receive something that looks like this:</p>
<p>Active Internet connections (servers and established)</p>
<p>Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name</p>
<p>tcp 0 0 0.0.0.0:37 0.0.0.0:* LISTEN 3425/inetd</p>
<p>tcp 0 0 0.0.0.0:6000 0.0.0.0:* LISTEN 3640/X</p>
<p>tcp 0 0 0.0.0.0:113 0.0.0.0:* LISTEN 3425/inetd</p>
<p>tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 7586/sshd</p>
<p>0.0.0.0:* indicates port 22 is listening on all addresses.</p>
<p>To search only for sshd, pipe netstat with grep:</p>
<pre><code>netstat -tunap | grep sshd
</code></pre>