- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Automate Manual Acceptance
Categories
Company
Local Language
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
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
Community
Resources
Forums
Blogs
- 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
09-05-2007 03:20 PM
09-05-2007 03:20 PM
Automate Manual Acceptance
At present in my UX shell script , I have few acceptance done manually. Could you please suggest the way I could make them automatic? Scenarios are :->
1) You are about to run Day Process. Continue (yes/no)?
2) Please enter a UID and PWD for Day Process :
User ID -
Password -
3) Confirm to continue (Y/N):
Below are the piece of script I am using:
1)
echo "\nYou are about to run Day Process. Continue (yes/no)? \c"
read ans
case "$ans" in
[Yy]*)
break
;;
*)
exit 0
;;
esac
2)
echo "\n\nEnter UserId for Day Process : \c "
read UID
echo "-U $UID" >> day.pf
stty -echo
echo "\nEnter Password for Day Process : \c "
read PWD
echo "-P $PWD" >> day.pf
stty echo
Please advice the modified commands?
Thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2007 03:39 PM
09-05-2007 03:39 PM
Re: Automate Manual Acceptance
You can get expect from:
http://hpux.connect.org.uk/hppd/hpux/Tcl/expect-5.43/
(Be sure to note the run time dependency of tcl/tk.)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2007 03:49 PM
09-05-2007 03:49 PM
Re: Automate Manual Acceptance
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2007 04:24 PM
09-05-2007 04:24 PM
Re: Automate Manual Acceptance
You might add the following code to prevent others from reading the file?
chmod 400 day.pf
what is your umask ? 002 ?
just thinking you do not want others to read the $PWD and $UID found in this day.pf (file).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2007 04:34 PM
09-05-2007 04:34 PM
Re: Automate Manual Acceptance
i am trying to remove or automate these 'read' commands from script. please advice if could there be a way?
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-05-2007 08:24 PM
09-05-2007 08:24 PM
Re: Automate Manual Acceptance
Well, where do you expect to get the info?
You could squirrel it away in a . file.
Or you could use the LOGNAME for UID, if they mean the same to you.