Creating user account and setting password in Solaris9 through shell script

I need to create and set password of user through shell scripts.
User can be added successfully through "useradd" command but password cant be set through "passwd" command in script.
Is there any other alternative for the same.

Hi,
Did you get the answere for this ? I have the same problem as urs , like I want to creat the users by using useradd and want to hardcode there password in one script.
But I cant use expect utility which would have made my work easier

Similar Messages

  • Create new account and reset password options on AAD signIN page

    Hi there:
    When using Azure Active Directory as an authentication provider for Azure Mobile Services, authentication works fine, but what about signing UP. How can I add the typical links like "Create new account" (with a confirmation link via email) and
    "Reset Password" to the SignIN page?.
    Thx in adv,
    Gerardo

    This is actually a question relating to AAD, not Mobile Services, as AAD is in control of that page, etc.
    However, Azure Active Directory is intended as an enterprise identity management solution. There is no sign-up process, as users are managed explicitly by the organization.
    My understanding is that you are looking for a custom authentication solution where users have usernames/passwords associated with your application. AAD is not meant for this use case. We do have
    a tutorial for working with your own database, but you are responsible for the security, etc.

  • Cannot change anything in user account and family safety, even logging as an administrator account.

    My 1st user account was an administrator account, 2nd user account was a standard account. 3rd user account was a guest account of window 8 single language, however i accidentally made a mistake by setting guest account from standard account to become an
    administrator account. I also set down the 1st user account from administrator to standard account and after these stupid settings, the guest account becomes administrator account anyone can access in without any password, the 1st and 2nd accounts become standard
    accounts! Before this mistake, the 1st user account was the main account of mine, 2nd and 3rd (guest account) were logged in very rarely.
    The problem is when i logged in guest account as administrator, i cannot set the 1st or 2nd back to become another administrator account. Something has gone strange, it has been prevented me to set the others to be administrator and the guest back to standard
    account. Being as an administrator account, the guest account was totally useless in changing settings. When i logged in with 1st and 2nd account, i also cannot change anything in the user account settings (change type of user account) and family safety, all
    attempts to change the user account settings was useless such as i never tried. I also tried "refresh your computer without losing files" but not worked. Please provide me some advices!
    I did not find the forum for win 8 single language, so i place my question here.

    Thanks for your reply. I tried to go to safe mode of win 8 by holding the shift key while clicking "restart" on the login screen. (My login screen now shows 3 account users). Then i chose troubleshoot -> advanced options -> windows startup
    settings-> i went to safe mode. The safe mode only showed a complete black screen with an only window: "Administrator: cmd.exe". I did as you said (typing NETPLWIZ) and the User accounts window appeared. I went to "properties" of each
    user account and set 1st and 2nd accounts to Administrator but got the error: "This user cannot be added. Access is denied." and another error window: "Usert accounts: the group membership for ... could not be updated."
    Yesterday, i went to elevated command prompt as an administrator and typed "net user administrator /active:yes" with hope that the built-in administrator would be activated and i would use it for full control settings of 3 other user accounts.
    But i got the error: "system error 5. Access is denied."
    Now, my position is quite bad. Login with guest account which was set as administrator, i still can not have full control of this laptop, so that all attempts of mine to change the user account settings is denied. This guest account also does not have a
    password at all so that everyone can open my computer without typing a password. Because access is denied, i cannot set a password for the guest account even now it is the administrator account and i am loging in it.
    p/s: I tried to refresh the system but still got the error: "There was a problem refreshing your PC. No changes were made". And i also tried to restore the system, but got the error: "System restore did not complete successfully. Your computer's
    system files and settings were not changed. Details: A volume shadow copy service component encountered an unexpected error. Check the Application event log for more information (0x80042302)"
    I went in registry editor in safe mode and did as you said but there was no "AutoAdminLogon", "DefaultUserName", "DefaultPassword". I only saw "AutoLogonSID" and other different names...
    The problem i got half year ago has still remained and recently i made this mistake. https://social.technet.microsoft.com/Forums/en-US/8ebd868c-bdfd-412e-95a6-9dc0095d431c/cannot-paste-any-online-pictures-from-any-websites-into-wordpowerpointonenote-2013?forum=officeitpro
    I am a young woman who always creates mistakes when setting computer because of my carelessness.
    Hi,
    These phenomenon should be access rights problem, you need to check your current system User Accounts status. In my opinion, your administrator account probably disabled.
    Open Run, type LUSRMGR.MSC, press Enter.
    Then check your current system account which Group they are belongs to.
    If there is any progress, please feel free let me know.
    Roger Lu
    TechNet Community Support

  • How to manage user account and management through AMS

    Hi all,
    I’m in the process of designing a new mobile app that requires user registration, login and password reset. Basically all the standard user self service activities that public apps provide. Imagine Instagram for example.
    We’re already looking at Azure Mobile Services and Facebook, Live, etc. authentication. But I’m a bit unclear on how to best handle manual user registrations. How would you best handle a user who decides that they want to register
    without their social account?
    User table in the custom application DB with user name, password, etc. and custom user management pages for registration, login, password reset
    Azure Active Directory and OAuth same as with facebook, etc. Then build custom user management pages for registration, login, password reset, etc.
    Some other Azure service that I don't know about?
    Something else?
    I noticed there is already another related question here:
    https://social.msdn.microsoft.com/Forums/azure/en-US/ca5527f6-1130-4ebb-b335-2d4d6eda7734/create-new-account-and-reset-password-options-on-aad-signin-page?forum=azuremobile
    The 2 important aims for this app are to require minimal maintenance and support overhead and high security at the same time.
    Thanks,
    Kia

    I am not saying that, but with your question it looks like you want a custom auth.
    Did you saw these article:
    Register your apps to use an Azure Active Directory Account login
    Authenticate your app with Active Directory Authentication Library Single Sign-On
    Sara Silva - Microsoft Visual C# MVP
    My blog |
    My Windows 8 Store Apps Samples |
    More Samples
    Follow me in Twitter @saramgsilva
    My Windows 8 Store Apps:
    Female Pill |
    Galinho (Tic tac Toe) |
    24 |
    My Snake
    My Windows Phone Apps

  • AUDIT action (create, delete, privilege escalation, set and change password from users account and group) users and admins in Solaris 10

    Hello.
    in Solaris 10 i need auditing process create, delete, privilege escalation, set and change password and etc... from users account and group.
    I set settings:
    in file syslog.conf:
    *.info;mail.none;cron.none;audit.notice            @IP-Remote-syslog-server-SIEM
    in file   /etc/security/audit_control:
    dir:/var/audit
    flags:lo,ad,ex,cc,am,no,fc,fd
    minfree:20
    naflags:lo
    plugin:name=audit_syslog.so;p_flags=lo,ad,ex,cc,am,no
    in file   /etc/security/audit_user:
    root:lo,ad:no
    Now I see in the logs only the fact of a connection via SSH and run processes on behalf of users. Creation. delete users, change passwords for some reason do not is logged.
    Many users. For each individual write permissions in the file /etc/security/audit_user not possible, it is likely to forget any new user (or there is a possibility in this file one line to describe the audits for all accounts?)
    Where is the mistake?

    You are most likely hitting Bug 15779000 user/role/groupadd/mod/del don't audit their use.
    And the fix is only available in S11.2.
    -- Renaud

  • Creating User Accounts So I Can Set Parental Controls?

    My nine year old son loves to use YouTube to watch video game videos and apparently there are NO parental controls or any kind of filters on YouTube. The majority of the ones he finds are ok but there's about 15% that are just plain shocking even to me. Its pretty sad the things that people put up there. I hate to have him never be able to get online again so I want to set some sort of filter where I can block content according to keyword but I just cant figure it out at all. So I tried to set controls over the whole MacBook but it tells me that as administrator I cannot. I cant figure out how to create non-admin users though. Searched all the forums and guides, etc. but no answer.
    Thanks, so in summary, I just want to know how to create user accounts if thats the right term.
    I am using a MacBook, running Mac OSX version 10.4.11.

    Hi
    Apple menu (top left hand corner) > System Preferences > Accounts. Click the lock to authenticate. Just above the lock are two icons; a 'plus' and 'minus'. Click the 'plus' icon. Enter the name of your son, tab down into the next field and that should autofill for you with the information you placed in the name field; tab down again and enter a password; tab again to key in the password again; don't tick the box that says "allow user to administer this computer"; click 'Create Account'. You should be prompted with a window asking if you want to leave automatic login on or if you want to turn it off - turn it off. You'll see why later on. What you should see after this has finished is in the left hand window at the top your account details with your name and underneath it should 'Admin' and below your account details will be your son's. Underneath his name it should say 'Standard'.
    Click on his name to select it and now click on the Parental Controls tab on the right hand side of that window. You should now have the option to enable and configure control for the 5 applications listed there: Mail, Finder & System, iChat, Safari and Dictionary. Explore and configure to your hearts content from there. When you are happy quit out of System Preferences and select Log out from the Apple Menu. You should now be presented with the Login Window displaying not only your account but also the newly created one for your son. Log in s your son and test to see if what you've set as a control has worked. Keep going backwards and forwards between the two accounts until you are happy.
    Bear in mind there is only so much you can do.
    It's virtually impossible to block everything potentially morally harmful without basically stopping your son from having any access at all. You could look at supplementing Parental Controls with the built-in filters in your router - if you have one? If you don't then consider getting one. I'm struggling to think of a router for residential use that does not have some sort of built-in web filter?
    The tab button is the key immediately to the left of the 'Q' key. It will have an arrow going from left to right printed on it.
    Tony

  • HT4796 I used migration to transfer iTunes from pc to mac book. It had me set up another user account. Now i have 2 user accounts and i have the iTunes on the wrong one. How do i get the iTunes on the original account.

    I used migration to transfer iTunes from pc to mac book. It had me set up another user account. Now i have 2 user accounts and i have the iTunes on the wrong one. How do i get the iTunes on the original account.

    In Mail Preferences/Accounts/each GMail account, set up the SMTP Outgoing Server for each account separately, going into SMTP name/edit/Advanced and specify the Username of each account.  The Outgoing servers must be two different servers, authenticated by the Username and Password of each.
    Otherwise, the GMail SMTP server will change the from address to that of the account where the SMTP server was setup.
    Ernie

  • Creating a new user account and transferring files from old account

    I am now having more problems than I can handle with my Leopard installation...problems such as applications that refuse quit no matter what ~ even after attempting force quit them and/or attempting to "sudo kill -9 PID", and now that I am having problems with Adobe Lightroom not even being able to remain open on my user account for more than 10 seconds max before it crashes without provocation (yet runs fine on a troubleshooting account I created on the same machine), I would now like to create a new user account on my MacPro Leopard 10.5.6 and transfer my files from the previous (problematic) user account, but I've never done so in the past...
    Can someone give me a basic rundown of how to go about doing this as a means of troubleshooting my current sickly user account (and if you could also please let me know which files I should avoid restoring to the newly created user account so that I don't screw that one up as well, I would appreciate it)
    Any suggestions would be greatly appreciated... Thanks!

    While logged into the troubleshooting account (assuming that it's an admin account—if not create a new one and log into it), backup the bad account's folder, delete the bad account, selecting the save data option (which is stored in /Users/Deleted Users/ as a disk image), recreate the bad account using the same username/password combo, log out and back into the recreated original account. If the problem's solved, open the saved data dmg file in /Users/Deleted Users/, open the /Library/Preferences/ folder from the saved data, open the current /Users/restored account/Library/Preferences/ folder, and slowly copy plist files from the saved data folder to the current one that don't exist in it. Log out and back in to ensure there's no conflict and things still work correctly. Resolving conflicts or identifying corrupt plist files is a laborious process. Good luck.
    See http://discussions.apple.com/thread.jspa?messageID=4703015 for more details on this process.

  • **want to create a user account from "Crypted Password" to "Open Directory"

    I have create a user account with "user password type: Crypted Password"
    is there any way I can script it to "user password type: open directory"
    I've use perl-ldap to create user account but I don't know how to change user password type to open directory,
    because my script will add a new node in the directory, I just need a way to make the "user password type" to "Open Directory" AT CREATION TIME, not modifing it after a have a user account, the script below will generate a node in the directory with "Crypted Password" as User Password Type,
    is there any attribute I need to add to make it "Open Directory" or perl command, applescript, bash, objective c(hopefully not)....
    thank for reading...
    $res = $c->add(dn => 'uid=testing,cn=users,dc=microsoft,dc=info',
    attr => [
    'cn' => 'testing',
    'gidNumber' => '20',
    'homeDirectory' => '99',
    'objectclass' => 'inetOrgPerson', 'posixAccount', 'shadowAccount', 'apple-user', 'extensibleObject','organizationalPerson','top','person',
    'sn' => 'testing',
    'uid' => 'testing',
    'uidNumber' => '5000',
    1. 'apple-generateduid' => '27318931-B341-4364-91B4-84E4AAAD1234', #026F",
    'givenName' => 'testing',
    1. 'loginShell' => '/bin/bash',
    'userPassword' => 'testing' ,
    1. 'homePhone' => '555-2020',
    2. 'mail' => '[email protected]'
    die "unable to add, errorcode #".$res->code().$res->error if $res->code( );
    thanks

    Since this question isn't Xserve specific a better place to get an answer is probably in the Directory Services forum: http://discussions.apple.com/forum.jspa?forumID=1353
    That being said if you are trying to migrate Crypt accounts to OD accounts then the short answer is no. You need an unencrypted password to put the password into OD via a script do short of cracking the encrypted password, inserting it in plain text into the OD user account creation process then I don't think you can.
    You should be able to dictate the password (and any other settings you can do from the GUI) but the password is the missing piece. Under really old OS X systems I actually suspect you can get passwords to export (hinted at by an Apple engineer I discussed this with) but there is probably a faster and more straightforward solution.
    What I have done is export from NetInfo, clean the accounts via script and then reimport the accounts into the new system. I usually assign a password and dictate "Must change password at next login" and then email people the temporary passwords. It's been a while but I believe you can mass select and then dictate password settings so if that works for you create accounts with all the same password and then you can select by group and make changes - eg Must change password at login.
    Good luck,
    =Tod

  • TS3899 My email account has disappeared from my iphone4. No longer listed. Now won't accept my user name and or password.

    My email account has disappeared from my iphone4. No longer listed. Tried to set up new email account but now won't accept my user name and or password.

    Finally went to the Apple shop where a nice young man explained that I had to use the original password not the recently changed password - case sensitive too - and finally have installed the updated Adobe Flash player with no shaking! Maybe this helps you too. JL

  • Amanda; And creating user accounts BEFORE the build process

    I am trying to make a package for amanda (Advanced Maryland Automatic Network Disk Archiver) http://www.amanda.org.
    I have gotten everything to run fine, but the way the devs have set up their configure file (and the resulting build process),
    I HAVE to specify a user account that the program will run as. If I do not specify (and create an account) the PKGBUILD will not run. Is this normal?
    Is there a way to make the PKGBUILD create an account and a group? This account and group are need both DURING the build and during the install.
    It has to be a pre-existing user account.  Here is my PKGBUILD script:
    pkgname=amanda
    pkgver=2.6.0p1
    pkgrel=1
    pkgdesc="The Advanced Maryland Automatic Network Disk Archiver"
    url="http://www.amanda.org/"
    license=('BSD')
    depends=("glibc")
    #If you need amplot and/or samba support (for backing up windows clients) delete the line above and uncomment the line below this line
    #depends=("glibc" "samba" "gnuplot")
    install=(amanda.install)
    arch=('x86_64' 'i686')
    source=(
    http://downloads.sourceforge.net/amanda/amanda-2.6.0p1.tar.gz
    md5sums=('afadad80e0a27963a24b510755470983')
    build() {
    cd $startdir/src/amanda-2.6.0p1
    # These config options are documented at:
    # http://wiki.zmanda.com/index.php/Installation/Installing_Amanda_Source
    ./configure CFLAGS="-03 -Wall" \
    --with-user=amanda \
    --with-group=backup \
    --prefix=$startdir/pkg/usr/local \
    --with-amperldir=$startdir/pkg/usr/local/share/perl5/site_perl/5.10.0
    make || return 1
    make install prefix=$startdir/pkg/usr/local
    I would really appreciate some help (this is my first pkg)
    Also remember; this will not finish building without creating a user and a group
    #groupadd backup
    #useradd -g backup amanda
    Last edited by timetrap (2008-06-19 19:08:09)

    I didn't take it any farther than the first post. I became frustrated with the chicken/egg relationship with account/makepkg.
    The package works (as long as the user accounts are created first) if you can figure out a way around this issue feel free to update the pkg (then upload it to AUR).
    The nobody/nobody idea didn't work for me, I cannot remember the reason why. It had something to do with permissions. Let me know if you need any help.
    Last edited by timetrap (2009-01-01 03:12:17)

  • How do I create a new user account and migrate my data to it?

    I have problem with Adobe Bridge crashing when I exit Camera Raw.  I was advised by my local apple service store to create a new user account and test Bridge using the new account.  It works fine.  So what do I do now?  I don't know what in my account is causing the conflict but assume that the solution might be e newly setup user. 

    Checking the behaviour in another user account is a TEST, not a solution! You don't need to move everything over. Otherwise, every time you get a user account problem, you'll keep moving to a new user account again and again.
    If the problem does not occur in a new user account, then the cause is something IN your user account. This is usually a Preference file. Adobe Bridge seems to crash a lot, and it can usually be fixed by deleting the Bridge folder in <user>/Library/Application Support/Adobe/
    You can also try deleting the Bridge preference file, which will be in <user>/Library/Preferences, and called com.adobe.bridge5.plist (or similar).
    If that doesn't work, you can test removing a whole bunch of the various Adobe files in those folders. You can always put them back if they don't change anything. And you've got a backup, haven't you? ;-)

  • How can I find the user that created a user account and the user who last updated the account

    How can I find out who created a user account and who last updated the account. I think that this is the same information that is displayed in the description field on the General tab.
    I am using ADO commands and vbscript
    ug3j

    I should point out that there are two attributes of all AD objects that can help you track down the correct information in the system logs. These are the whenCreated and whenChanged attributes. This will tell when the object was created and when it was last
    modified, which should help when you search the logs. Also, while whenCreated is replicated to all DC's, so they will all have the exact same creation time, the whenChanged attribute is technically not replicated. The date/time on each DC reflects when
    the last modification was replicated to that DC. The values will differ slightly on each DC, reflecting how long it took for the change to replicate.
    Richard Mueller - MVP Directory Services

  • Can I Create a New User Account and Move Existing Account ???

    Lion was reinstal.
    I'm suspecting issue with one user account.
    Can I creat a new user account and move all my files to that new user?
    What are the impact?
    How about permissons on this files?
    What about the Library Folder?
    Thank you for your help and support.
    BigBlaze

    This should help you out after  you have created the new user account. You are trying to make it much more complex than it needs to be. Just follow the directions in:
    Transferring files from one User Account to another.

  • My husband plugged my iPhone into his computer, created an account and now when I want to add apps it asks for his password not mine.  How do I get my account back?  Tried plugging it into his computer again.  No prompt to change account back to mine.

    My husband plugged my iPhone into his computer, created an account and now when I want to add apps it asks for his password not mine.  How do I get my account back?  Tried plugging it into his computer again.  No prompt to change account back to mine.

    Hi Trishw,
    At the top of the iTunes Store window, you will see who is logged into iTunes. I'm guessing from your description, that it is your husband. If it is, click on the name to display the dropdown, log him out and sign yourself back in:\
    Cheers,
    GB

Maybe you are looking for