Re: Recovering destroyed /etc/passwd from /etc/shadow?

From: Bit Twister (BitTwister_at_localhost.localdomain)
Date: 05/24/03


Date: Fri, 23 May 2003 22:40:29 GMT

On 23 May 2003 15:12:41 -0700, NOSPAM wrote:
> Hello,
> I managed to destroy my /etc/passwd file (don't ask ;). Is there any
> way to rebuild it with /etc/shadow (which is still intact)??

let us see

passwd: mail:x:8:12:mail:/var/spool/mail:/bin/sh
shadow: mail:*:12140:0:99999:7:::

You have your work cut out for you.
just find the everyone's home and shell is,
look in their directory to uid and group and you start vi-ing away.



Relevant Pages

  • Re: PermitRootLogin=yes versus su
    ... >all windows with a UID 0 shell get a red border or something. ... >could do that with su but sudo is a better tool for many reasons, ... >shell without having to tell them the root password. ...
    (comp.security.ssh)
  • Re: Reihenfolge bei Usern mit gleicher UID
    ... Die User bekommen nicht die UID0 zugewiesen. ... ein SUID-Programm an, dass sich selbst sie UID 0 gibt und dann eine Shell ...
    (de.comp.os.unix.linux.misc)
  • Re: Splitting the output of `id(1)
    ... I am looking for a convenient way to split the ouput of the `id ... The output of this command looks like: ... I would like to store the four informational fields (numeric uid, ... etc.) in four shell variables. ...
    (comp.unix.shell)
  • Re: Setting ulimit values in files on Redhat AS 2.1
    ... >Scott Lurndal wrote: ... The code that changes the UID to the new ... the single "-" argument which tells the shell it needs to read ... to source it with the effective UID == 0, ...
    (comp.os.linux.setup)
  • Re: Setting ulimit values in files on Redhat AS 2.1
    ... >Scott Lurndal wrote: ... The code that changes the UID to the new ... the single "-" argument which tells the shell it needs to read ... to source it with the effective UID == 0, ...
    (comp.os.linux.misc)