HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: script to transfer users from SCO to HPUX
Operating System - HP-UX
1836623
Members
2141
Online
110102
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
08-18-2008 04:01 PM
08-18-2008 04:01 PM
script to transfer users from SCO to HPUX
hi guys,
i did my first script for adding all the printers (fun) to hpux but i am having issues figuring out the users.
we have about 200 users that i need their user_name, shell_dir and the content of the home_dir (.profile)
so i was thinking there must me a way to export the above to a space delimitated file:
example:
david /bin/sh
and a "david" dir will contain the ".profile" file.
then on the import side as each user is created with the correct name and shell the .profile will also me copied to the corrisponding folder.
any ideas?
thanks,
amir
i did my first script for adding all the printers (fun) to hpux but i am having issues figuring out the users.
we have about 200 users that i need their user_name, shell_dir and the content of the home_dir (.profile)
so i was thinking there must me a way to export the above to a space delimitated file:
example:
david /bin/sh
and a "david" dir will contain the ".profile" file.
then on the import side as each user is created with the correct name and shell the .profile will also me copied to the corrisponding folder.
any ideas?
thanks,
amir
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-18-2008 04:14 PM
08-18-2008 04:14 PM
Re: script to transfer users from SCO to HPUX
This shouldn't be too hard. How are you obtaining the information from SCO? Using the HP-UX /etc/passwd format:
grep /etc/passwd | awk -F: '{print $a $b $c $d $e $f $g }' | while read 1 2 3 4 5 6 7
do
useradd [-u uid [-o] ] [-g group] [-G group [, group...]] [-d dir] [-s shell] [-c comment] [-m [-k skel_dir]] [-f inactive] [-e expire] login
done
I would first list all logins in a file and cat it though
cat list | while read a
do
grep $a /etc/passwd | awk -F: ......etc.
See above to complete
done
grep
do
useradd [-u uid [-o] ] [-g group] [-G group [, group...]] [-d dir] [-s shell] [-c comment] [-m [-k skel_dir]] [-f inactive] [-e expire] login
done
I would first list all logins in a file and cat it though
cat list | while read a
do
grep $a /etc/passwd | awk -F: ......etc.
See above to complete
done
Support Fatherhood - Stop Family Law
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
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP