portsInUse
returns a vector of UDP and TCP port numbers
currently being used by the operating system. Under Linux, these are
the ports listed in /proc/net/[u|t]cp
, while for Windows they
are the ports listed by netstat -an
. Under either operating system, availablePort
returns the first
TCP port number greater than 40000 that is not currenly in use.
portsInUse()
availablePort()
portsInUse
returns a numeric vector. availablePort
returns an integer.hostName