Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uwm.edu!zaphod.mps.ohio-state.edu!usc!wuarchive!psuvax1!rutgers!mcnc!uvaarpa!murdoch!savant!jon From: jon@savant.UUCP (Jon Gefaell) Newsgroups: comp.unix.questions Subject: Re: loginid vs. uid. Message-ID: <611@savant.UUCP> Date: 19 Jul 90 03:28:45 GMT References: <316@dynasys.UUCP> Reply-To: jon@savant.UUCP (Jon Gefaell) Organization: Savant System, Public Interactive Media: Charlottesville, Va. Lines: 52 In article <316@dynasys.UUCP> jessea@dynasys.UUCP (Jesse W. Asher) writes: >I have learned to make a distinction between a loginid and the userid. >The loginid is the actual name of your login. For example: jessea. >The userid is the actual number, your uid. For example: 110. > >I consider these two separate concepts - one is a name and the other a >number and they are not interchangeable. > >My question is does anyone else view them this way, and if not what is >the relationship? The reason I make this distinction is because your >uid can be changed while your loginid doesn't have to be changed - the >os looks at your uid (the number) to determine who your are in most >cases. An example is su changing your uid to 0 (or to whatever your su >uid is) while leaving your login intact. Of course you can have both >changed, but the above leaves me to believe that they are not >interchangeable concepts. The uid is not the same as the loginid. >Does anyone have any comments on this? I learned this the hard way when I set up savant and started adding users I wanted to change the order some people appeared in the /etc/password file, and their uid's too.. Well, this resulted in some _very_ interesting manifestations. Notably, it seems file permissions are 'remembered' or whatever in uid form (that is, underneath the ls output, the file ownership and group ownership must be in uid and gid's... So, news, who was 101 (right after me, who was 100) I wanted as 100 (so it wouldn't interupt a contiguous listing of _real_ people) This meant that /usr/lib/news and it's files were now owned by 'jon' instead of 'news' and of course, inews didn't have proper permissions on the history files (for one thing, but after this became evident I spotted it before any thing else went wrong (that I noticed) For those interested, another interesting aspect of this is that there were no other manifestations of this error within the news system (or any other that I'm aware of) and that this problem (not being able to post because of access permission problems on LIBDIR/history.d files) didn't occur until I ran 'expire' for the first ever 10 days later (waited for a 70M news fs to start to fill up). Interesting, at least to me, and illustrates well the diference between uid gid and their corresponding text tokens. (I believe the later are only looked up for their abstract value in user presentation) As usual, please comment :) I wanna learn.... -- +----------- Domain? DOMAIN? We Don't Need No Steeeenkin' Domain! -----------+ | __/\ | | \/~~ | +-savant!jon@virginia.edu {...}!uunet!virginia!savant!jon jeg7e@virginia.edu-+