How to set for a user a non-login shell?


 
Thread Tools Search this Thread
Homework and Emergencies Homework & Coursework Questions How to set for a user a non-login shell?
# 1  
Old 12-26-2014
How to set for a user a non-login shell?

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!

1. The problem statement, all variables and given/known data:
I am a root in a Unix system. My shell is bash.


2. Relevant commands, code, scripts, algorithms:
How to set for a certain user:
* a non-login interactive shell,
* a login, non-interactive shell,
* a non-login, non-interactive shell.


3. The attempts at a solution (include all code and scripts):
I read everything I could find, I only found information which files are read by different types of shells. I cannot find anywhere how a root can set a certain shell. I know about useradd and adduser commands where I can use the option -s but I do not know what to put after -s to set a non-interactive shell.


4. Complete Name of School (University), City (State), Country, Name of Professor, and Course Number (Link to Course):
AGH, profesor Nalepa

Note: Without school/professor/course information, you will be banned if you post here! You must complete the entire template (not just parts of it).
# 2  
Old 12-26-2014
Quote:
4. Complete Name of School (University), City (State), Country, Name of Professor, and Course Number (Link to Course):
AGH, profesor Nalepa
Moderator's Comments:
Mod Comment Please provide ALL asked information and the thread will be reopend!
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Shell script for login user and email

Guys please help me I have a linux class and I want to write a shell script who shows which user loged in and show the process that are active in his/her shell in another text file and email that file to root just when the user loged out Thanks every bod (1 Reply)
Discussion started by: hamedk1122
1 Replies

2. Solaris

Run commans as no login shell user

Hi All, I have problem running a command with another user who has no login shell the os is solaris 10 i am root and doing the following: su user -s /bin/bash "ls" no output .. no error messages if su - user i got No directory Please use CODE tags as required by forum... (2 Replies)
Discussion started by: BF_DEV
2 Replies

3. Shell Programming and Scripting

Shell script to install and set JAVA_HOME as non root user

HI I am trying to install JAVA and set JAVA_HOME variable in non-root user mode. I am trying to write a script for that. I am doing it by downloading a tar ball.Any inputs will be helpful. (1 Reply)
Discussion started by: sailu_mvn
1 Replies

4. Homework & Coursework Questions

How to set a non-login non-interactive shell for a user?

I am sorry for creating a new topic after my previous inquiry was closed, but I tried and tried and I do not know how to edit my previous post. This is not exactly any homework, this is one of 40 questions we were expected to prepare for one of the labs. I searched and read what I could and still... (4 Replies)
Discussion started by: me_me_me
4 Replies

5. Shell Programming and Scripting

How to login as a different user inside a shell script?

hi, i want to login as a different user inside a shell script and then call another shell script from that script. how to do that? original script : script_A.sh so when the script_A.sh is called , i want to login as a different user and then call another shell script(script_B.sh) from... (3 Replies)
Discussion started by: Little
3 Replies

6. Solaris

HOW to set unlimited login attempts for user in Solaris?

Hi Admins, HOW to set unlimited login attempts for user in Solaris ? And do I need to insatll any packages before doing this? Thanks. (1 Reply)
Discussion started by: manalisharmabe
1 Replies

7. Shell Programming and Scripting

How to Login as another user through Shell script from current user[Not Root]

Hi Every body, I would need a shell script program to login as different user and perform some copy commands in the script. example: Supppose ora_toms is the active user ora_toms should be able to run a script where user: ftptomsp pass: XXX should login through and run the commands ... (9 Replies)
Discussion started by: ujjwal27
9 Replies

8. Shell Programming and Scripting

Shell script for user login information.

Hi Gurus, I need help in writing a script which should say which user has used or logged in in the server from past one month using FTP or TELNET and the output should be of the form Username Service NumberofTimes Date. Thanks in Advance. ---------- Post updated at 04:01 PM... (1 Reply)
Discussion started by: rama krishna
1 Replies

9. UNIX for Dummies Questions & Answers

$USER is not set in remsh but works fine via ssh login

1) ssh a@b echo $USER it display the correct value as a (even though i have not defined it in .profile) 2) remsh b -l a echo $USER it does not display the value as a (variable is not set any idea why $USER variable is not initialized when i login via remsh or rlogin but shows the... (10 Replies)
Discussion started by: reldb
10 Replies

10. UNIX for Dummies Questions & Answers

User account with no login shell

Hi All, I was reading a tutorial for Installing Tomcat on Linux machine. (http://www.puschitz.com/InstallingTomcat.html) Here the author had mentioned that: For security reasons I created a user account with no login shell for running the Tomcat server. My question is: 1. What is a User... (6 Replies)
Discussion started by: jw_amp
6 Replies
Login or Register to Ask a Question