The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
Google UNIX.COM


UNIX for Advanced & Expert Users Advanced UNIX and Linux questions go here. Expert-to-Expert.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
last logged on info nokia1100 Shell Programming and Scripting 1 04-07-2007 08:32 AM
crontab changes logged? chlawren AIX 4 02-05-2007 08:47 AM
Need help getting logged in to server mayewil SUN Solaris 1 10-26-2006 12:06 PM
know who logged and logged out with their timings vkandati UNIX for Dummies Questions & Answers 3 03-09-2005 07:04 AM
Is user logged on?? provo UNIX for Dummies Questions & Answers 1 12-07-2001 02:41 PM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 01-23-2008
Registered User
 

Join Date: Feb 2007
Location: Pune, Dehradun (INDIA), Michigan(US)
Posts: 187
Exclamation su ?? Who logged in First ??

Hi all,

Say my login user id is "t007" and I login into the unix server first using my id and password and then I used to use "su" command to switch the user using root user id and password. Now, how the third person will come to know who has logged in as a first user ?


As:

Login: t007
password: abcd

$ su - mqsiadm
password : qwert123

$$ [now I am as user "mqsiadm"]
$$ [How the third person will come to know who logged in first ? (i.e. t007)]

Now if I'll exit, I'll first comeout as a "mqsiadm" and then i'll be as "t007".

Please give me the solution to this !!

Thanks in advance !!
Reply With Quote
Forum Sponsor
  #2  
Old 01-24-2008
Registered User
 

Join Date: Sep 2007
Location: Poland
Posts: 63
I am not sure if I understand it correctly. If so, then:
1. You could try to trace what is your parent process and this way you could probably get this
2. Probably all the users will be assigned to the same console - try ps'ing with a full list and then checking what consoles are assigned to the user.
3. I am not sure about that but probably you could try to check if the real-uid and effective-uid are set to the given user IDs.
Reply With Quote
  #3  
Old 01-24-2008
Registered User
 

Join Date: Feb 2007
Location: Pune, Dehradun (INDIA), Michigan(US)
Posts: 187
Talking

Quote:
Originally Posted by adderek View Post
I am not sure if I understand it correctly. If so, then:
1. You could try to trace what is your parent process and this way you could probably get this
2. Probably all the users will be assigned to the same console - try ps'ing with a full list and then checking what consoles are assigned to the user.
3. I am not sure about that but probably you could try to check if the real-uid and effective-uid are set to the given user IDs.
Hey,

Yup , thanks man, parent process id will work. I had an idea about that but when i tried it was not working. Now I got the solution. Just, I had to dig more.

Thanks anyways.
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 09:07 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0