- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Script help needed
Operating System - HP-UX
1820271
Members
3426
Online
109622
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
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
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
11-17-2008 05:16 AM
11-17-2008 05:16 AM
Script help needed
Hi,
I need to write a script which will login to all servers(hpunix, linux, solaris) and get the login message and shell prompt and also the output for the commands like uptime etc.
Can anyone help me regarding this.
I tried like this:
for i in $SERVER
do
ssh -t $i >>/tmp/logfile <<-ENDTAG
hostname
uptime
exit
ENDTAG
done
But this gives only the login message and not the prompt for the hpux and for linux, itis just throwing the output.
And it is having some unknown characters like ^E ^B etc i mean it is related pseudo terminal i think.
Please help me out.
thanks!!
regards,
sanwin.
I need to write a script which will login to all servers(hpunix, linux, solaris) and get the login message and shell prompt and also the output for the commands like uptime etc.
Can anyone help me regarding this.
I tried like this:
for i in $SERVER
do
ssh -t $i >>/tmp/logfile <<-ENDTAG
hostname
uptime
exit
ENDTAG
done
But this gives only the login message and not the prompt for the hpux and for linux, itis just throwing the output.
And it is having some unknown characters like ^E ^B etc i mean it is related pseudo terminal i think.
Please help me out.
thanks!!
regards,
sanwin.
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-17-2008 06:19 AM
11-17-2008 06:19 AM
Re: Script help needed
It would be better to continue your questions in your other thread, rather than start a new thread:
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1287664
>not the prompt for the hp-ux and for linux, it is just throwing the output.
What's wrong with that? The output is all you need if you aren't logging in interactively.
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1287664
>not the prompt for the hp-ux and for linux, it is just throwing the output.
What's wrong with that? The output is all you need if you aren't logging in interactively.
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
Learn About
News and Events
Support
© Copyright 2025 Hewlett Packard Enterprise Development LP