Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 09-23-2006, 07:19 AM   #1
Registered: Mar 2006
Distribution: FC4
Posts: 184

Rep: Reputation: 31
which command executed on which terminal

Hi All,
Can I know, on which terminal a particulaer command was executed....

For eg...was

$ls executed on pts/2 or pts/3

Is there any command like

$last etc

Old 09-23-2006, 08:57 AM   #2
Senior Member
Registered: Mar 2006
Posts: 1,896

Rep: Reputation: 61
While a process is running you can determine the terminal (if any) with the ps command. After the command is finished, TMK there is no record of it ever executing, let alone on which terminal, unless the command logs it itself (and most don't!). If the command was run interactively there may be a record of it in the user's history file, but that depends on settings and usually isn't recorded immediately.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
removing only most previously executed command from history? jagroop mand Linux - Newbie 2 01-19-2005 05:39 AM
"modprobe usbkbd" command cann't be executed! lucklemon Linux - Hardware 1 05-21-2004 08:43 AM
No effect when 'export' command executed in a script? sylvain_gnu Linux - Software 6 04-20-2004 07:15 PM
How find which command has been executed by which user. HPUX 11.11 OS kshell murugesan Linux - Distributions 3 04-16-2004 05:26 AM
How do I undo last command executed? Elfking Linux - General 4 02-05-2004 01:18 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:40 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration