how can i make an user to nologin without locking the account for the user

Answers were Sorted based on User's Feedback



how can i make an user to nologin without locking the account for the user..

Answer / aman thakur

Simply edit a line in /etc/passwd and chage user's shell to /bin/false(in case of ubuntu) or /bin/nologin(incase of redhat or fedora)

Is This Answer Correct ?    45 Yes 7 No

how can i make an user to nologin without locking the account for the user..

Answer / balaji

usermod -s /sbin/nologin username

Is This Answer Correct ?    11 Yes 2 No

how can i make an user to nologin without locking the account for the user..

Answer / arnab chowdury

Simply edit a line in /etc/passwd and chage user's shell to /sbin/nologin

Is This Answer Correct ?    12 Yes 4 No

how can i make an user to nologin without locking the account for the user..

Answer / tinku prasad

Simply edit a line in /etc/passwd and chage user's shell
to /sbin/nologin

Is This Answer Correct ?    5 Yes 2 No

how can i make an user to nologin without locking the account for the user..

Answer / naveen.esamalla

i know just lock the useraccount ie usermod -L username

Is This Answer Correct ?    10 Yes 9 No

how can i make an user to nologin without locking the account for the user..

Answer / santhosh kumar

use password aging for that user. and set the date which is already past..!!! "chage username" is the command

Is This Answer Correct ?    3 Yes 4 No

how can i make an user to nologin without locking the account for the user..

Answer / girish

vi /etc/passwd
student:x:500:500::/home/student:/bin/bash
student:*:500:500::/home/student:/bin/bash

here student is user and just replace "X" with "*"

Is This Answer Correct ?    1 Yes 6 No

Post New Answer

More Linux AllOther Interview Questions

what is difference between inetd and xinetd

2 Answers  


in linux gui desktop icon was lost how con u back this icons

2 Answers  


How to sort a file of size 2N bytes, if I have N bytes of memory?

2 Answers   Yahoo,


what are acl permissions..? what is automation of jobs..?

5 Answers   IBM, TCS,


what is the difference betweenh the NFS and FTP?

4 Answers   IBM,






How can i recover the linux system after it was crashed by step by step process..

3 Answers   IBM,


what is the gate of ftp server in redhat linux?

0 Answers  


What is the minimum number of partitions you need to install Linux?

30 Answers  


What are main anti-spam features available in sendmail?

1 Answers   CSC,


How To Hide the FTP Version?

3 Answers   Wipro,


why /etc/shadow file do not have any permission ?

0 Answers   IBM,


Which directory is closer to the top of the file system tree, parent directory or current directory?

3 Answers  


Categories