[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: HOW can i get user ID



> HI everybody,
>  Can anybody tell me how can i get the usrid of the user when new user log
> in to the linux system.. and how can i set the messege for him for first
> time  only. The messenge should not come when he login second time.
> thanks..
> 

For the id:
[09:34:14 /tmp]$ id
uid=1000(shaul) gid=1000(shaul) groups=1000(shaul),4(adm),20(dialout),21(fax),22(voice),24(cdrom),25(floppy),30(dip),50(staff),100(users),500(dos)
[09:34:15 /tmp]$ 

For the first time message you might have to prepare something that will replace the /etc/passwd entry with another although this is starting to get complicated and potentially a security risk.
-- 
Shaul Karl		 		   shaulk@israsrv.net.il
	An elephant is a mouse with an operating system.



=================================================================
To unsubscribe, send mail to linux-il-request@linux.org.il with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail linux-il-request@linux.org.il