Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I got a set of assignments at work to do to see how can I work around Linux systems (namely I was recommended openSUSE since I will be working with SLES). Most of those assignments are pretty straightforward, or simple enough to find on Google.

However one of the assignments states:

User test03 should not be allowed to use interactive shell

I initially used -s /sbin/nologin option, but apparently this basically turns off the whole account, and I think this is most likely a wrong way to do what the assignment asks for. (I suppose the point is to be able to pipe scripts via ssh or something along those lines, but not to login as user directly.)

I have found heaps of information about how to find out whether shell is interactive, or how to force a script to run interactively and such. However, I have not found anything specific to disabling interactive shell.

Could anyone please point me in the right direction?


share|improve this question
up vote 0 down vote accepted

Use /bin/false instead to accomplish this.

share|improve this answer
I think it's time I marked this as the correct answer. Sorry for the delay... – Apr 18 '14 at 20:13

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .