Tim Underwood wrote:
>How can I easily get the IP Address of a given terminal connected via a
>pseudo-tty?
>
>In other words, if I issue the 'tty' command, and receive /dev/pts/1, how
>can I convert /dev/pts/1 into normal dotted notation?
>
>I don't want to have to build a hosts file, DNS, etc.
>
>
>
>
I assume you mean DNS name format, ttys do not normally have IP addresses
tty | awk 'BEGIN{FS="/";}{print $4 "." $3 "." $2 ".";}
or
tty| tr "/" "."| cut -c 2-
if you are happy with 0.pts.dev
--
J. D. Addison
email
(E-Mail Removed)