- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- In script, how to remote run a script
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
04-04-2008 10:06 AM
04-04-2008 10:06 AM
I have being writing a script, there is a action need remote start a script, how to do it, details as below:
Server A: rp5470 11i v1 scriptA
Server B: rp4440 11i v1 have been writing scriptB
Server A - B connect allow SSH, telnet, remsh.
In scriptB I wanna add a action that run remote run scriptA, how to do it.
Any answers, will be very appreciate.
-G
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 10:09 AM
04-04-2008 10:09 AM
Re: In script, how to remote run a script
How to remote start another script that located in another server in a script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 10:16 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 10:20 AM
04-04-2008 10:20 AM
Re: In script, how to remote run a script
Thank you very much for your fast reply, Does you mean:
In ServerB, scriptB I just add below items and could remote start scriptA on serverA?
serverB > # cat scriptB
...
remsh serverA /home/oracle/scriptA.sh
exit
that's everyting? what't the remsh passwd?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 10:36 AM
04-04-2008 10:36 AM
Re: In script, how to remote run a script
2) In order for remsh to work without a password prompt you need to correctly configure the trust relationship. i.e. configure ./rhosts in users home directory.
For ssh you need to configure .ssh/authorized_keys file.
trust access is a different subject from your topic but can describe if needed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 10:46 AM
04-04-2008 10:46 AM
Re: In script, how to remote run a script
thanks a lot.
It works now,
BTW,
the file should be .rhosts not ./rhost right?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 10:49 AM
04-04-2008 10:49 AM
Re: In script, how to remote run a script
$HOME/.rhosts
format:
hostname username
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 11:19 AM
04-04-2008 11:19 AM
Re: In script, how to remote run a script
One more question,
If I remote access to serverA but this server need enter some enviroment parameter like d0 [DEV50] d1 [DEV51], normally, the oracle user will enter d0 or d1 after input username and passwd and then in the DEV50, oralce could run the script serverA.
How to write this in scriptB, in other words, how to let the script execute d0
remsh serverA
d0 ???
sh scriptA
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 12:07 PM
04-04-2008 12:07 PM
Re: In script, how to remote run a script
I would recommend passing variables into the script. You will have to mod the script to accept these args and set the vars you want.
i.e.
remsh serverA "script.ksh arg1 arg2"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 03:49 PM
04-04-2008 03:49 PM
Re: In script, how to remote run a script
remsh machine -n command
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-04-2008 10:03 PM
04-04-2008 10:03 PM
Re: In script, how to remote run a script
in case, you decide to use SSH, below an extrace from a script that we currently use here:
...
ssh applnuser@SRV1 << EOF
/home/yogeeraj/compile.sh /appln/$4/$2/$3/$1
EOF
else
...
hope this helps too!
kind regards
yogeeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-07-2008 09:53 AM
04-07-2008 09:53 AM
Re: In script, how to remote run a script
Thank you very much for your detail reply.
Have a good day.
-G