user creation in HP-UX

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • prasadshete
    New Member
    • Feb 2007
    • 19

    user creation in HP-UX

    hello everybody,

    i tried to create a user on HP-UX by this command..

    useradd -m test..

    but it did not work..

    please help me in this regard..
  • prn
    Recognized Expert Contributor
    • Apr 2007
    • 254

    #2
    I guess I should preface this with a comment to the effect that I have had very little experience with HP-UX. However, I have had a lot more with Solaris and Linux and I don't really think that useradd should be all that different on the various flavors of *ix.

    What kind of "did not work" are you seeing? Is there an error message? Did you check /etc/passwd to see if the new user is there? Did you check /home (or is it /export/home on HP-UX?) What are you seeing that you didn't expect and what are you not seeing that you did expect?

    Have you read the man page for useradd? If you are just planning to take all the defaults, perhaps you would be better off with

    useradd -D test

    and say explicitly that you want all the defaults. Personally, I normally believe in specifying all or most of what I care about, e.g.:

    useradd -c "A test account" -u 512 -g staff -G printer-admin -s /bin/tcsh -m -d /home/test test

    and then I control all the variables in the account-creation process, especially the group(s) that the user is assigned to.

    Let us know what you can find that went wrong in the creation process. It's hard to help without any additional information beyone "It didn't work".

    Best Regards,
    Paul

    Comment

    • eggi
      New Member
      • Nov 2007
      • 9

      #3
      Hey There,

      The previous post was dead-on. useradd works almost exactly the same way in HP-UX as it does in Solaris.

      The issue you had (I'm surprised you didn't get an error message) is that you told useradd (with the -m flag) that you wanted to make the home directory, but not what that directory you wanted created.

      The problem was that, by adding the option you were being just specific enough for HP-UX to expect you to a lot of other info and not give you the defaults.

      As above - useradd -D user1 - or just - useradd user1

      should do the trick for you. If you want to modify attributes later, you can use usermod - same as Solaris also.

      Best Wishes,

      , Mike

      Dedicated to keeping Linux, Unix and scripting Languages Alive!

      Comment

      • PaqoMex
        New Member
        • Dec 2007
        • 3

        #4
        Originally posted by eggi
        Hey There,

        The previous post was dead-on. useradd works almost exactly the same way in HP-UX as it does in Solaris.

        The issue you had (I'm surprised you didn't get an error message) is that you told useradd (with the -m flag) that you wanted to make the home directory, but not what that directory you wanted created.

        The problem was that, by adding the option you were being just specific enough for HP-UX to expect you to a lot of other info and not give you the defaults.

        As above - useradd -D user1 - or just - useradd user1

        should do the trick for you. If you want to modify attributes later, you can use usermod - same as Solaris also.

        Best Wishes,

        , Mike

        http://linuxshellaccount.blogspot.com
        Hi you seem to be an expert compared to what I know of HP-UX, do you know where I can find a nice tutorial, or what should I read to know more commands for HP-UX, I'm not very good with UNIX, so any tutorial which would help me is more than welcome!

        Comment

        Working...