Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

find out which tty

Status
Not open for further replies.

peac3

Technical User
Jan 17, 2009
226
AU
HI Guys,

Just wondering how am I be able to tell which tty I'm on because I got the script running in the background.

UID PID PPID C STIME TTY TIME CMD
master 26240 26088 0 May 05 pts/11 0:01 bash
master 20716 20377 0 00:30:17 pts/12 0:00 -ksh
master 21764 21762 0 05:10:18 pts/12 0:00 sleep 60
master 26088 26064 0 May 04 pts/11 0:00 -ksh
master 21762 20843 0 05:10:18 pts/12 0:00 /usr/bin/ksh /home/master/Scripts/testScript.ksh

How do I find out that which screen is pts/12?

thanks in advance guys,
 
Use the "last" command this will give you the ipaddress/alias

last|grep "pts/12
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top