Professional Web Applications Themes

Will anytime /etc/passwd change due to 'pwconv' command? - Linux / Unix Administration

In my understanding, 'pwconv' command synchronizes the /etc/shadow file according to the entries in /etc/passwd i.e it results into changes only in /etc/shadow file and not in /etc/passwd due to the invocation of 'pwconv' command. Am I right? In any case, does 'pwconv' also result into some changes in /etc/passwd file?...

  1. #1

    Default Will anytime /etc/passwd change due to 'pwconv' command?

    In my understanding, 'pwconv' command synchronizes the /etc/shadow
    file according to the entries in /etc/passwd i.e it results into
    changes only in /etc/shadow file and not in /etc/passwd due to the
    invocation of 'pwconv' command. Am I right? In any case, does 'pwconv'
    also result into some changes in /etc/passwd file?
    qazmlp Guest

  2. #2

    Default Will anytime /etc/passwd change due to 'pwconv' command?

    In my understanding, 'pwconv' command synchronizes the /etc/shadow
    file according to the entries in /etc/passwd i.e it results into
    changes only in /etc/shadow file and not in /etc/passwd due to the
    invocation of 'pwconv' command. Am I right? In any case, does 'pwconv'
    also result into some changes in /etc/passwd file?
    qazmlp Guest

  3. #3

    Default Re: Will anytime /etc/passwd change due to 'pwconv' command?

    qazmlp wrote:
    > In my understanding, 'pwconv' command synchronizes the /etc/shadow
    > file according to the entries in /etc/passwd i.e it results into
    > changes only in /etc/shadow file and not in /etc/passwd due to the
    > invocation of 'pwconv' command. Am I right? In any case, does 'pwconv'
    > also result into some changes in /etc/passwd file?
    Any actual hashed passwords in /etc/passwd will be
    replaced with 'x'. Ordinarily, this only happens the
    very first time pwconv is run.

    You've posed a couple questions about making changes
    to the "user account" files. What are you trying to do,
    and is there a reason you can't do it through standard
    interfaces? The days of hand-editing /etc/passwd are
    (or ought to be) behind us ...

    --
    [email]Eric.Sosmansun.com[/email]

    Eric Sosman Guest

  4. #4

    Default Re: Will anytime /etc/passwd change due to 'pwconv' command?

    Eric Sosman wrote: 
    [snip] 

    NOT!

    Please, don't discourage people from understanding core concepts
    like the format of really simple/basic files (/etc/passwd)! Sure,
    people have made all sorts of whizzy, flashy tools for maintaining
    this stuff, and now the average luser has no clue where to look
    when something gets corrupted and suddenyl they can no longer login.
    *Every* unix programmer|user should understand how to read the
    /etc/passwd file, or don't bother using unix!

    On a related note, if you don't understand the format, read the man
    page first, understand the fields, and by no means do any editting
    of the /etc/passwd file unless/until you've got a clue about what
    the stuff is there for.

    [Okay, maybe knowing what "GECOS" means is superfluous, but the
    rest is pretty relevant! Consider all the questions in this group
    about "why does user so-and-so have /bin/false as a login shell?"
    and you realize the fundamental importance of retaining the knowledge
    about basic file layouts in unix.]

    Sorry to respond to such an old thread, but this is a touchy issue.

    -fjb
    --
    Colorless Green Ideas Sleep Furiously, and so do I....

    Fred Guest

  5. #5

    Default Re: Will anytime /etc/passwd change due to 'pwconv' command?

    In article <net>,
    "Fred J. Bourgeois, III" <net> wrote:
     
    > [snip] 
    >
    > NOT!
    >
    > Please, don't discourage people from understanding core concepts
    > like the format of really simple/basic files (/etc/passwd)! Sure,
    > people have made all sorts of whizzy, flashy tools for maintaining
    > this stuff, and now the average luser has no clue where to look
    > when something gets corrupted and suddenyl they can no longer login.
    > *Every* unix programmer|user should understand how to read the
    > /etc/passwd file, or don't bother using unix!
    >
    > On a related note, if you don't understand the format, read the man
    > page first, understand the fields, and by no means do any editting
    > of the /etc/passwd file unless/until you've got a clue about what
    > the stuff is there for.
    >
    > [Okay, maybe knowing what "GECOS" means is superfluous, but the
    > rest is pretty relevant! Consider all the questions in this group
    > about "why does user so-and-so have /bin/false as a login shell?"
    > and you realize the fundamental importance of retaining the knowledge
    > about basic file layouts in unix.]
    >
    > Sorry to respond to such an old thread, but this is a touchy issue.
    >
    > -fjb
    > --
    > Colorless Green Ideas Sleep Furiously, and so do I....[/ref]

    OK, you get to respond to *ALL* the Linux script kiddies who've changed
    the Solaris root shell to /usr/bin/bash and can no longer login as root
    (unless they're on Solaris 9--yeah!).

    In this day and age of dumbing down (just look at the current
    President), general advise to use the "standard tools" rather than vi
    seems a good idea.

    Come to think of it, if we followed your lead, there's be a lot less
    people out there doing damage to machines.

    ***NEVERMIND** (spoken with the voice of Gilda Radner)

    --
    DeeDee, don't press that button! DeeDee! NO! Dee...



    Michael Guest

  6. #6

    Default Re: Will anytime /etc/passwd change due to 'pwconv' command?

    "Michael Vilain " wrote: 
    >>
    >>[snip]
    >> 
    >>
    >>NOT!
    >>
    >>Please, don't discourage people from understanding core concepts
    >>like the format of really simple/basic files (/etc/passwd)! Sure,
    >>people have made all sorts of whizzy, flashy tools for maintaining
    >>this stuff, and now the average luser has no clue where to look
    >>when something gets corrupted and suddenyl they can no longer login.
    >>*Every* unix programmer|user should understand how to read the
    >>/etc/passwd file, or don't bother using unix!
    >>
    >>On a related note, if you don't understand the format, read the man
    >>page first, understand the fields, and by no means do any editting
    >>of the /etc/passwd file unless/until you've got a clue about what
    >>the stuff is there for.
    >>
    >>[Okay, maybe knowing what "GECOS" means is superfluous, but the
    >>rest is pretty relevant! Consider all the questions in this group
    >>about "why does user so-and-so have /bin/false as a login shell?"
    >>and you realize the fundamental importance of retaining the knowledge
    >>about basic file layouts in unix.]
    >>
    >>Sorry to respond to such an old thread, but this is a touchy issue.
    >>
    >> -fjb
    >>--
    >>Colorless Green Ideas Sleep Furiously, and so do I....[/ref]
    >
    >
    > OK, you get to respond to *ALL* the Linux script kiddies who've changed
    > the Solaris root shell to /usr/bin/bash and can no longer login as root
    > (unless they're on Solaris 9--yeah!).[/ref]

    Really?! All of them?!! Does that mean everybody else will ignore them
    from now on? ;-)
     

    I constantly feel the pain of dumbed-down unix admins (e.g. the guy who
    bugged me for a week about his DNS zone not resolving, claimed to have
    changed nothing, and finally added that his ISP had changed his IP
    addresses!).
     

    Yup.

    --
    Fred J. Bourgeois, III FREDNET Corporation
    Colorless Green Ideas Sleep Furiously, and so do I....
    FREDNET is a registered service mark of FREDNET Corporation, Scotts
    Valley, CA.
    [E-mail address in header intentionally mangled ... remove "bonzo"
    part]

    Fred Guest

  7. #7

    Default Re: Will anytime /etc/passwd change due to 'pwconv' command?

    In article <dca.giganews.com>,
    Michael Vilain <net> wrote: 
    >> [snip] 
    >>
    >> NOT!
    >>
    >> Please, don't discourage people from understanding core concepts
    >> like the format of really simple/basic files (/etc/passwd)! Sure,
    >> people have made all sorts of whizzy, flashy tools for maintaining
    >> this stuff, and now the average luser has no clue where to look
    >> when something gets corrupted and suddenyl they can no longer login.
    >> *Every* unix programmer|user should understand how to read the
    >> /etc/passwd file, or don't bother using unix![/ref][/ref]
     [/ref]
     [/ref]
     [/ref]
     

    Reminds me of the time a client in our colo-rack had a problem
    and restarted or something crashed it and it needed to be fsck'd
    which failed.

    I went in and connected a serial link and when it went to single
    user prompt it couldn't find the root home directory and wanted to
    start over.

    I tried the install CD and it wouldn't do a thing because there
    was an OS already installed.

    Luckily they had two HD's in that box. As I recall when you
    came into the system it went to the Netra, and then an Apple G4
    running WebObjects and the database resided on a multi-sparc
    Sun under Oracle.

    But the admins had only used Linux.

    root's home was moved onto /usr/local as I recall.

    I found the easiest way to recover that was to pull out the drives
    - and those were designed to do that - put the second drive which
    had nothing on it into the first slot and install a fresh solaris.
    Then I could fsck the original HD which was now in position 2.

    Once I did that I swapped them back and all was ok.

    So he had the root home on the wrong partition, had bash installed
    that wanted shared libraries which were not avaiable, and sh
    appeared to be moved.

    So this was worse than not being able to login in as root, it was
    not being able to even get into single user mode.

    And I've cleaned up a couple of other poorly admined Linux system
    with some of the strangest scripts running out of cron that I've
    ever seen.

    Brings in a few bux now and then however.
     

    I thought vi was a standard tool :-). Actually the first *n*x
    system I used had only ed, so I learned the regex's pretty well.
     

    If you undestand the concepts you can admin almost any Unix machine
    made. But too many [from my observations] are of the 'I need to
    know what key to press' and once they get on a system with an
    interface different than they one they learned on, they get lost.

    Sometimes they even lose the data :-(

    Bill

    --
    Bill Vermillion - bv wjv . com
    Bill Guest

  8. #8

    Default Re: Will anytime /etc/passwd change due to 'pwconv' command?

    "Michael Vilain " wrote: 
    >>
    >>[snip]
    >> 
    >>
    >>NOT!
    >>
    >>Please, don't discourage people from understanding core concepts
    >>like the format of really simple/basic files (/etc/passwd)![/ref][/ref]

    I wasn't going to re-enter this old thread, but since
    three or four new posts have appeared I thought I'd try to
    clear up what seems to be a misunderstanding.

    I was *not* attempting to discourage anybody from a
    study of the format of anything whatsoever. Instead, I was
    trying to find out what "qazmlp" was up to, and to encourage
    him to use the available tools unless there was a compelling
    reason not to. This, I think, was and is good advice.

    Note that "qazmlp" didn't appear (in this and other
    threads started at about the same time) to be asking how to
    use vi to manipulate these files; he seemed to be seeking
    advice on how to write a brand-new program to massage them.
    I somewhat suspected he'd been tasked with developing some
    kind of user-management facility that would tie into an
    external registry: Give Unix accounts to all the incoming
    freshmen while expunging all the graduated seniors, that
    sort of thing. If that turned out to be the gist of the
    matter, I was going to suggest that he write wrappers
    around existing tools like useradd rather than try to
    incorporate the password-hashing and suchlike right into
    the middle of his own program.

    ... but as far as I can tell he never came back. Maybe
    he got scared off, or maybe he learned enough to enable him
    to do -- well, to do whatever it was he was up to.

    --
    com

    Eric Guest

  9. #9

    Default Re: Will anytime /etc/passwd change due to 'pwconv' command?

    Eric Sosman <com> wrote in message news:<cjrtnt$e07$Central.Sun.COM>... [/ref]
    >
    > I wasn't going to re-enter this old thread, but since
    > three or four new posts have appeared I thought I'd try to
    > clear up what seems to be a misunderstanding.
    >
    > I was *not* attempting to discourage anybody from a
    > study of the format of anything whatsoever. Instead, I was
    > trying to find out what "qazmlp" was up to, and to encourage
    > him to use the available tools unless there was a compelling
    > reason not to. This, I think, was and is good advice.
    >
    > Note that "qazmlp" didn't appear (in this and other
    > threads started at about the same time) to be asking how to
    > use vi to manipulate these files; he seemed to be seeking
    > advice on how to write a brand-new program to massage them.
    > I somewhat suspected he'd been tasked with developing some
    > kind of user-management facility that would tie into an
    > external registry: Give Unix accounts to all the incoming
    > freshmen while expunging all the graduated seniors, that
    > sort of thing. If that turned out to be the gist of the
    > matter, I was going to suggest that he write wrappers
    > around existing tools like useradd rather than try to
    > incorporate the password-hashing and suchlike right into
    > the middle of his own program.
    >
    > ... but as far as I can tell he never came back. Maybe
    > he got scared off, or maybe he learned enough to enable him
    > to do -- well, to do whatever it was he was up to.[/ref]

    I got the answer from your previous post itself! That's I did not come
    back in this thread!

    Thanks for all! The contributions from all of you are commendable.
    qazmlp Guest

Similar Threads

  1. Replies: 2
    Last Post: February 28th, 02:54 PM
  2. Blue Screen / Recovery / Admin Passwd not Assgnd / User Passwd Assgnd
    By Terry B. in forum Windows Setup, Administration & Security
    Replies: 2
    Last Post: July 20th, 02:49 AM
  3. Change XP Password Command Line
    By Miha Pihler in forum Windows Setup, Administration & Security
    Replies: 1
    Last Post: July 17th, 06:30 PM
  4. Replies: 1
    Last Post: July 11th, 02:50 AM
  5. [OS X] change network prefs from command line?
    By yoadrian in forum Mac Applications & Software
    Replies: 0
    Last Post: July 1st, 07:23 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139