On 14 December 2013 22:16, venkat kulkarni <[email protected]> wrote: > From z/OS unix command manual > > 1) whoami displays a user name associated with the effective user ID. > 2) To display your login name, use who am i > 3) who displays information about users who are logged into the system > 4) id displays the user name and group affiliations of the user who issued > the command > > But my outputs are totaly different > > $ id > uid=12345 gid=996(FLTG) > > $ whoami > Error for uid: 12345 > > $ who > VENKAT ttyp0000 Dec 14 19:07 > > $ who am i > VENKAT@TST01 ttyp0000 Dec 14 19:07
I don't see that your outputs are totally different - far from it. Everything is according to the book except for the cases where the command has to translate a uid to a userid - "whoami" - which has clearly encountered some sort of error, and "id", which doesn't make it clear that there is an error, but which fails to show the userid. Browsing /bin/whoami, I see the single occurence of the string "error" is: "Error for uid: %d". Sigh - wouldn't it be nice if UNIX commands gave at least some sort of hint as to what the error was? But it's not the UNIX Way... Tony H. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
