I have 2 users to whom i want to disable terminal access, but still keep ftp access.How do I achieve this?

EDIT

Forgot to mention, I'm using vsftpd.

link|improve this question

60% accept rate
feedback

3 Answers

You can disable shell with:

usermod -s /sbin/nologin <ftp_user>

or use virtual users.

link|improve this answer
feedback

Proftpd will not allow nologin shell, just disable the non-shelled users in SSH by allowing only trusted shell users:

In sshd_config :

AllowUsers toto john chuck morice
link|improve this answer
feedback

Due to

RequireValidShell directive in proftpd which is by default ON one needs to either add /bin/false to /etc/shells or turn RequireValidShell to off and then

usermod -s /bin/false <ftp_user>

reference : proftpd RequireValidShell directive man page

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.