Re: AIX 5.3 disaster recovery fro AIX newbie
From: Robert Miller (rmiller_at_SMUD.ORG)
Date: 09/26/05
- Previous message: Lindsey, James: "Re: AIX 5.3 disaster recovery fro AIX newbie"
- Maybe in reply to: Kovetsky, Dmitry: "AIX 5.3 disaster recovery fro AIX newbie"
- Next in thread: Kovetsky, Dmitry: "Re: AIX 5.3 disaster recovery fro AIX newbie"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Mon, 26 Sep 2005 11:11:25 -0700 To: aix-l@Princeton.EDU
If both are toasted (which sounds like the case here, since he can't log
in), then assuming you made a mksysb before you started (if not, shame
on you!), you can boot off of the tape drive, then select option 3,
'Maintenance mode for system recovery', and access the root volume
group. You should then be able to get to your devices (CD, tape, etc),
then restore the files and boot. You *did* take a mksysb before you
started, right? ;)
If you have no mksysb's, then you'll have to boot off of the install
CD's and go through the same process to get to rootvg. Then you'll have
to lay down a new set of password files... the way I'd do it would be to
copy a set of passwd/shadow files from another AIX box to my PC, then
burn a CD with them (so you don't have to worry about mistyping
anything), and copy them off of the CD, making changes as appropriate
(UID's, GID's, etc.)... but it won't be a pretty sight, as your userid's
will be gone. If that is the case, hopefully you have them on another
machine, or at very least have the home directories available so you can
at least associate the correct userid's with the correct UID's and GID's
(the name of the home directory will give you the username, the files in
it should give you userid and group ID numbers...).
Hopefully you did do that mksysb - you said it was disaster recovery
testing, so hopefully that means you started with a backup =)
Good luck!
--rm
-----Original Message-----
From: IBM AIX Discussion List [mailto:aix-l@Princeton.EDU]On Behalf Of
Justin Bleistein
Sent: Monday, September 26, 2005 10:36 AM
To: aix-l@Princeton.EDU
Subject: Re: AIX 5.3 disaster recovery fro AIX newbie
What do you mean "to zero"? It's zero bytes? Well the "/etc/passwd" file
is not binary or any other proprietary file format. It's just ascii.
This means
you can edit it directly. Keep in mind this file only has 7 basic
fields:
user_name:!:user_UID:user_GID:User_Geco:User_Home_Dir.:User_Shell
user_name = Make sure every user stanza in the AIX shadow file:
"/etc/security/passwd" this respective line in this: "/etc/passwd" file.
! = This means that the encrypted password is set in the shadow file:
"/etc/security/passwd"
user_UID = Unique User ID number for the particular UID number.
user_GID = Unique Group ID number that a particular user belongs too.
User_Geco = The full name of the user in real life.
User_Home_Dir = The full path of the directory that you want to specify
as that user's home directory.
User_Shell = The shell/program which will be executed when a user
logins.
As long as your shadow file: "/etc/security/passwd" file is in place,
you should be able to rebuild the "/etc/passwd" file just fine.
Thanks.
--Justin Richard Bleistein
Towers Perrin - AIX Systems Administrator
(215) 246-6521 - (Desk)
(877) 402-2853 - (Pager)
(856) 912-0861 - (Cell)
justin.bleistein@towersperrin.com - (Email)
"Kovetsky, Dmitry" <Dmitry.Kovetsky@ENCANA.COM>
Sent by: IBM AIX Discussion List <aix-l@Princeton.EDU>
09/26/2005 12:27 PM
Please respond to
IBM AIX Discussion List <aix-l@Princeton.EDU>
To
aix-l@Princeton.EDU
cc
Subject
AIX 5.3 disaster recovery fro AIX newbie
Good morning everyone
Now I've got a chance to practice AIX disaster recovery: one of the
scripts smoked /etc/passwd file, to zero. Machine is micropartition,
freshly installed but due to some reasons rebuild is not an option.
Could you please advise how to I recover from this situation? (Way to
boot to single user? Mount rootvg and restore passwd from other
machine?)
Thanks in advance
Dmitry
- Previous message: Lindsey, James: "Re: AIX 5.3 disaster recovery fro AIX newbie"
- Maybe in reply to: Kovetsky, Dmitry: "AIX 5.3 disaster recovery fro AIX newbie"
- Next in thread: Kovetsky, Dmitry: "Re: AIX 5.3 disaster recovery fro AIX newbie"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|