Sponsored Content
Top Forums Shell Programming and Scripting Create new user account and password in shell script Post 302388391 by killuane on Wednesday 20th of January 2010 08:29:26 AM
Old 01-20-2010
Thanks scottn. Appreciate the answer. I'll use chpasswd on AIX and think up an alternative solution on Solaris.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

create or modify user account to have same access as root

Is there a way to create or better yet modify a user account so it has the same privs as root? (6 Replies)
Discussion started by: xadamz23
6 Replies

2. Solaris

how can I change user name and password , of account ?

passwd only changes the password but i need to change the user name tnx (5 Replies)
Discussion started by: umen
5 Replies

3. Solaris

How to create a new ftp user account with limited access..?

Hi All, I'm using solaris 2.8, and I want create a new ftp user account with the following restrictions: - Have only ftp access, no telnet or rlogin - Have restricted access to its home directory example /export/home/newuser - Deny access to any other directory. Thanks for your help, ... (6 Replies)
Discussion started by: Jeremy3
6 Replies

4. Filesystems, Disks and Memory

script to create multiple instances of a user account across LPAR's

My company has about 40 databases with each database in a different logical partition. Presently the SysAdmin person says it is necessary to create a user profile (login and password for each instance of databases on each LPAR. 1. Is it necessary that the user must be created in each LPAR? 2.... (1 Reply)
Discussion started by: kcampbell
1 Replies

5. Debian

password less login to root from a user account

hello friends, one user is created named "user1" I login as "user1" . Now when i do "su -" to be root user I have to give password for root . Is there any way through which we can skip giving the password to root. i.e. user1@work:~$ su - Password: xxxxxx work:~$ I don't want that... (1 Reply)
Discussion started by: pradeepreddy
1 Replies

6. Shell Programming and Scripting

Passing password when changing the user account

Hi All, I have one requirment.. I need to change my id to some sudo account in a server.. Actually our username/passwd will be stored in one gip file like below... $cat .a.gz #It's hidden file username passwd $ So I tried the below script to pass the password when i sudo to... (7 Replies)
Discussion started by: raghu.iv85
7 Replies

7. UNIX for Dummies Questions & Answers

block user account after failed password

hi guys I have Centos 5.4 The idea is lock the user account for 3 minutes after he has entered his password incorrectly 3 times. I've modified /etc/pam.d/system-auth auth required pam_tally.so onerr=fail per_user deny=3 account required pam_tally.so resetbesides... (3 Replies)
Discussion started by: kopper
3 Replies

8. Solaris

Help me create new user account

I want create user. That user should be login to any server without asking password. How? tell me in detail. :wall: (3 Replies)
Discussion started by: Navkreddy
3 Replies

9. Shell Programming and Scripting

Shell script for user account Creation

Hi Folks, I had a request to create the user request. Between, I just write a script a create, Update Geos, and update the password. My script as below: The error message, what I am getting is all the users are updated with the same Goes value.. #!/bin/bash for i in `cat users.txt`;do... (2 Replies)
Discussion started by: gsiva
2 Replies

10. UNIX for Beginners Questions & Answers

Create a shell script to gather user account information and displays the result to administrator

I want to create a shell script to gather user account information and displays the result to administrator. I have created a script but its showing all the information when i search for username like: amit@mx:~$ ./uinfo.sh amit Username : amit User Info ... (2 Replies)
Discussion started by: amit1986
2 Replies
newgrp(1)						      General Commands Manual							 newgrp(1)

NAME
newgrp - switch to a new group SYNOPSIS
[group] DESCRIPTION
The command changes your group ID without changing your user ID and replaces your current shell with a new one. If you specify group, the change is successful if group exists and either your user ID is a member of the new group, or group has a pass- word and you can supply it from the terminal. If you omit group, changes to the group specified in your entry in the password file, Whether the group is changed successfully or not, or the new group is the same as the old one or not, proceeds to replace your current shell with the one specified in the shell field of your password file entry. If that field is empty, uses the POSIX shell, (see sh- posix(1)). If you specify (hyphen) as the first argument, the new shell starts up as if you had just logged in. If you omit the new shell starts up as if you had invoked it as a subshell. You remain logged in and the current directory is unchanged, but calculations of access permissions to files are performed with respect to the new real and effective group IDs. Exported variables retain their values and are passed to the new shell. All unexported variables are deleted, but the new shell may reset them to default values. Since the current process is replaced when the new shell is started, exiting from the new shell has the same effect as exiting from the shell in which was executed. EXTERNAL INFLUENCES
International Code Set Support Characters from the 7-bit USASCII code set are supported in group names (see ascii(5)). DIAGNOSTICS
The command issues the following error messages: Your user ID does not qualify as a group member. The group name does not exist in If a password is required, it must come from a terminal. Standard input is not a terminal file, causing the new shell to fail. EXAMPLES
To change from your current group to group without executing the login routines: To change from your current group to group and execute the login routines: WARNINGS
There is no convenient way to enter a password into The use of group passwords is not recommended because, by their very nature, they encourage poor security practices. Group passwords may be eliminated in future HP-UX releases. If the specified group to has multiple inconsistent entries (i.e. the group id or/and password are different) in the group database, will consider the group id and password of the first matched group entry as the correct group id and password for the group. FILES
System group file System password file SEE ALSO
csh(1), ksh(1), login(1), sh-posix(1), group(4), passwd(4), environ(5). STANDARDS CONFORMANCE
newgrp(1)
All times are GMT -4. The time now is 01:11 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy