know a particular user is disabled or enabled


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers know a particular user is disabled or enabled
# 1  
Old 03-15-2010
know a particular user is disabled or enabled

Hi all,

i had 500 users how can i know whether user is disabled or enabled


Thanks,
kalyan
# 2  
Old 03-15-2010
Do you mean that the user account is enabled or disabled?
# 3  
Old 03-15-2010
yes i want to know whether the user is enabled or disabled
# 4  
Old 03-15-2010
MySQL

Do you want to check the user having account or not using the following command.
(you can use the /etc/passwd file or /etc/shadow file)

Code:
cat /etc/passwd | grep "^username"

Do you want to check the user is login or not using the following command.

Code:
who | grep '^username'


Last edited by ungalnanban; 03-15-2010 at 08:00 AM.. Reason: code alignment
# 5  
Old 03-15-2010
Code:
cat /etc/shadow | grep "*LK*"

It will show the users that are locked .
# 6  
Old 03-15-2010
Continue in this node Disabled/Locked users
# 7  
Old 03-15-2010
thanks for your response
i am clear that if an account exist can search in etc/passwd
but what actually i mean is
for a user der are 2 states enable , disable .(disable is different from deleting an account ,we can enable a disabled acccount but cant enable a deleted account) .how to know whether the user is enabled are not.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Web Development

CentOS 7 redirecting me to old disabled dev site when removed from sites-enabled

I am having problems accessing a new site I am trying to setup on my CentOS 7 VM. I have added a vhosts file for it, but when I access easydev.com in the browser it continues to redirect me to the old (now disabled) dev site of crmpicco.dev. Is there something wrong with my config? # apachectl... (3 Replies)
Discussion started by: crmpicco
3 Replies

2. Solaris

[Solved] Can't get into single user mode - sulogin was disabled

Solaris 10 trying to patch and therefore want to do this from single user mode I do a init 0 get's me to ok> :) ok> boot -s I was a UK Sun Field Engineer for 10 years ..... I've used "boot -s " quite a bit ..... I get a console login , which I subsequently login into #who... (13 Replies)
Discussion started by: Martincorneuk
13 Replies

3. Solaris

see if async i/o is enabled in Solaris 9

Hi guys. This may be a stupid question but I am trying to see if my Solaris 9 server has async i/o enabled... Is there a quick way to determine this? Thanks in advance. (1 Reply)
Discussion started by: jamie_collins
1 Replies

4. Red Hat

how to test whether is user is enabled on disabled in Radius

Hi i am having two linux machines M1 M2 ,where M1 is the main machine and the connector is M2 Radius services are installed in M2. i pulled M2 users which resides on /user/local/raddb/users to M1 .so that any changes made to user in M1 will be reflected in M2. now i am disabling a user from M1... (1 Reply)
Discussion started by: kalyankalyan
1 Replies

5. UNIX for Dummies Questions & Answers

how to test whether is user is enabled on disabled in Radius

Hi i am having two linux machines M1 M2 ,where M1 is the main machine and the connector is M2 Radius services are installed in M2. i pulled M2 users which resides on /user/local/raddb/users to M1 .so that any changes made to user in M1 will be reflected in M2. now i am disabling a user from M1... (0 Replies)
Discussion started by: kalyankalyan
0 Replies

6. Linux

ldap user disabled

Hi All, If ldap user is disabled on linux. Do you think ldap processes will still run while ldap user had been disabled? Thanks for any comment you may add. (2 Replies)
Discussion started by: itik
2 Replies

7. UNIX for Dummies Questions & Answers

Difference between : Locked User Account & Disabled User Accounts in Linux ?

Thanks AVKlinux (3 Replies)
Discussion started by: avklinux
3 Replies

8. HP-UX

st_san_safe enabled

$ uname -a HP-UX vfauh203 B.11.11 U 9000/800 486452371 unlimited-user license SCSI TAPE: dev = 0xcd520000 Failed open - st_san_safe enabled () is there any tools i can run to further investigate this err0r i received from syslog.log ? im new to hp-ux thanks (1 Reply)
Discussion started by: libchk
1 Replies

9. IP Networking

how we can find whether net is enabled or not

how we can find whether net is enabled or not with out using ping is there anyway please guide me thanku ,in advance sree (1 Reply)
Discussion started by: phani_sree
1 Replies
Login or Register to Ask a Question