HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Copying the password file
Operating System - HP-UX
1827006
Members
2286
Online
109712
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-14-2006 10:52 AM
07-14-2006 10:52 AM
Copying the password file
I have a number of accounts that need to be created. I just copied the /etc/passwd and /etc/group
when I rebooted the machine (for a different reason) I couldn't log in. I had to go into single user and recover the backed up passwd file.
Any suggestions on how to copy these users? I am thinking I will have to tar the home directory?
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-14-2006 11:02 AM
07-14-2006 11:02 AM
Re: Copying the password file
What you did should have worked, unless you've got servers in trusted mode, or you're using shadow passwords.
When you say "I couldn't log in" - do you mean root? Or "your user" account?
What was the error?
Generally, one can copy the line(s) for a user or set of users into a separate file, ditto for the groups. Then, go to the new server and append these new users and then, the new groups to each of the password and group files (respectively). At that point, you should run pwck (to check the password file), and then grpck (to check the group file). If all is OK, then you should be able to survive a reboot.
When you say "I couldn't log in" - do you mean root? Or "your user" account?
What was the error?
Generally, one can copy the line(s) for a user or set of users into a separate file, ditto for the groups. Then, go to the new server and append these new users and then, the new groups to each of the password and group files (respectively). At that point, you should run pwck (to check the password file), and then grpck (to check the group file). If all is OK, then you should be able to survive a reboot.
We are the people our parents warned us about --Jimmy Buffett
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-14-2006 03:19 PM
07-14-2006 03:19 PM
Re: Copying the password file
If this is a trusted system then you must copy /etc/passwd, /etc/group, and the entire /tcb tree. You should use a utility like cpio or tar so that permissions and ownerships are properly maintained. You will also need the home directories for normal use.
You should also be logged in as root in at least two sessions so that you can get yourself out of trouble almost as fast as you got yourself in.
You should also be logged in as root in at least two sessions so that you can get yourself out of trouble almost as fast as you got yourself in.
If it ain't broke, I can fix that.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-14-2006 07:14 PM
07-14-2006 07:14 PM
Re: Copying the password file
Hi,
I agree with the two others, when you perform such a action always do the following:
To perform a check, use the following commands:
# pwck
# grpck
On a trusted system run:
# authck
See man authck
# pwconv
For updating the tcb database
Darrel
I agree with the two others, when you perform such a action always do the following:
To perform a check, use the following commands:
# pwck
# grpck
On a trusted system run:
# authck
See man authck
# pwconv
For updating the tcb database
Darrel
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Support
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP