LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-05-2014, 05:46 AM   #1
massy
Member
 
Registered: Nov 2013
Distribution: CentOS 6.4
Posts: 209
Blog Entries: 1

Rep: Reputation: Disabled
What is the user 1000?


I've understood that the owner of some files is 1000(user), what is
it? and why there is it!?
Code:
uname -a
Linux RSU-2-15 2.6.32.10 #13 SMP PREEMPT Wed May 22 16:09:03 UTC 2013 i586 GNU/Linux
Code:
ls -l /var/
drwxr-xr-x  2 1000 root  4096 Jul  5 15:05 agentx
drwxr-xr-x  2 1000 root  4096 May 21  2012 backups
drwxr-xr-x  7 1000 root  4096 Aug  3  2012 cache
drwxr-xr-x 24 1000 root  4096 Aug 21  2013 lib
drwxrwsr-x  2 1000 staff 4096 May 21  2012 local
lrwxrwxrwx  1 root root     9 Jun 24 14:42 lock -> /run/lock
drwxrwxrwx  9 1000 sudo  4096 Jul  5 15:05 log
...
 
Old 07-05-2014, 06:13 AM   #2
saivinoba
Member
 
Registered: Oct 2007
Distribution: FreeBSD, Slackware
Posts: 48

Rep: Reputation: 9
Usually, the user id for users created on Linux systems now starts from 1000. On Fedora/CentOS systems it used to be from 500. It is specified in /etc/login.defs file. So, a user with uid 1000 is the first normal user (non-root user) created on the system. Or if your system starts giving uid from 500, then another non-root (non administrator) user with uid 1000.

The file ownership shown in your post for directory /var (which is a system directory) is clearly a case of mess up. This directory should be owned by root only and not normal user. It's either an innocent experimentation with file permissions or an attack perhaps?

P.S.: If only uid is shown and not the name of the user, it is mostly because, the username changed.

Last edited by saivinoba; 07-05-2014 at 06:25 AM.
 
Old 07-05-2014, 06:14 AM   #3
Doc CPU
Senior Member
 
Registered: Jun 2011
Location: Stuttgart, Germany
Distribution: Mint, Debian, Gentoo, Win 2k/XP
Posts: 1,099

Rep: Reputation: 344Reputation: 344Reputation: 344Reputation: 344
Hi there,

Quote:
Originally Posted by massy View Post
I've understood that the owner of some files is 1000(user), what is it? and why there is it!?
typically, Linux starts creating "normal" users at UID 1000. So a user with UID 1000 is probably the first user ever created on that particular system (beside root, who always has UID 0).

[X] Doc CPU
 
Old 07-05-2014, 06:19 AM   #4
273
LQ Addict
 
Registered: Dec 2011
Location: UK
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680

Rep: Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373
If you want to see the name of the user then you could try the following:
Code:
cat /etc/passwd|grep 1000
 
Old 07-05-2014, 07:00 AM   #5
Doc CPU
Senior Member
 
Registered: Jun 2011
Location: Stuttgart, Germany
Distribution: Mint, Debian, Gentoo, Win 2k/XP
Posts: 1,099

Rep: Reputation: 344Reputation: 344Reputation: 344Reputation: 344
Hi there,

Quote:
Originally Posted by saivinoba View Post
P.S.: If only uid is shown and not the name of the user, it is mostly because, the username changed.
are you sure? If you change the user name, the new name will be displayed instead of the old one.

I'd rather assume this occurs when a user is deleted. In that case, there are still files that have UID 1000 for the file owner in their meta data, but since there is no such user any more, Linux can't display a name for it.

[X] Doc CPU
 
1 members found this post helpful.
Old 07-05-2014, 08:59 AM   #6
saivinoba
Member
 
Registered: Oct 2007
Distribution: FreeBSD, Slackware
Posts: 48

Rep: Reputation: 9
Quote:
Originally Posted by Doc CPU View Post
are you sure? If you change the user name, the new name will be displayed instead of the old one.

I'd rather assume this occurs when a user is deleted. In that case, there are still files that have UID 1000 for the file owner in their meta data, but since there is no such user any more, Linux can't display a name for it.
[X] Doc CPU
You are correct. I stand corrected uid is displayed instead of username when the user is deleted (say using 'userdel') without deleting all related files.

Last edited by saivinoba; 07-05-2014 at 09:04 AM.
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] id: cannot find name for group ID 1000 / user ID 1000 McZ Linux From Scratch 1 01-14-2013 11:46 PM
[SOLVED] Nic -> 1000 MB ? jv2112 Linux - Hardware 1 08-28-2010 05:00 AM
How to configure 1000 Base T ethernet card to send at 1000 Base T? trist007 Linux - Newbie 12 09-23-2009 12:59 AM
1000 pardons supern00b5 Linux - General 1 05-31-2005 12:49 PM
A 1000 Posts LinuxLala LQ Suggestions & Feedback 8 08-17-2004 10:56 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:58 AM.

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