473,396 Members | 2,029 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

using shell script connect another machines run the script result shown in web page

11
i am in critical position please help
we have machines a,b,c,d
in each machine application servers are running
but each machine have 40 application server are running
result of 40 application servers are running or not shown in the web page.


but i am in z machine
when run the script (http://172.30.98.91:/cgi/health.ksh) in web page
Result will show in the web page .

Resultant in web page


Server a machine b machine c machine d machine
--------------------------------------------------------------------------------------------
trowe running running running running
republic running not running running running
universal not running
. ,
.
. ,
.
.
acs running running running running


it very help full greate becaues i am trouble .please help
May 22 '08 #1
8 3882
gpraghuram
1,275 Expert 1GB
If u want to connect to another box and run a script then u should use rsh for this.

Provide more details so that people here can help u.

Raghu
May 23 '08 #2
gupta24
11
we have 4 different machines (unix)
in each machines haveing 40 servers running
and we write the shell script like go to the 4 machines run the script and result will get in to another machine( servers running or not)

Please help i am in critical position
May 24 '08 #3
docdiesel
297 Expert 100+
Hi,

if I understand your needs right, you want to have one script which
  1. is maintained on machine z
  2. is sent to system a,b,c,d
  3. is remotely executed there while
  4. you need the output on machine z.

Try something like

Expand|Select|Wrap|Line Numbers
  1. cat check.sh | ssh checkusr@${rmtsys} >${rmtsys}.out 2>${rmtsys}.err
where rmtsys is a variable containing the remote systems name (you could try to use a for() loop). The output of the script is stored in the .out and .err files. If setup right by exchanging keys, the ssh enters [a,b,c,d] without prompting for a password.

Regards,

Bernd
May 25 '08 #4
gupta24
11
Thanks very much

once check the below code and update it will work or not



Hi,

if I understand your needs right, you want to have one script which
  1. is maintained on machine z
  2. is sent to system a,b,c,d
  3. is remotely executed there while
  4. you need the output on machine z.

Try something like

Expand|Select|Wrap|Line Numbers
  1. cat check.sh | ssh checkusr@${rmtsys} >${rmtsys}.out 2>${rmtsys}.err
where rmtsys is a variable containing the remote systems name (you could try to use a for() loop). The output of the script is stored in the .out and .err files. If setup right by exchanging keys, the ssh enters [a,b,c,d] without prompting for a password.

Regards,

Bernd
May 28 '08 #5
gupta24
11
i try below code , is not working (it will going another machine but not running in that machine and out put also not comeing in that machine)

please help help ......................

Regards,
gutpa


Thanks very much

once check the below code and update it will work or not
May 28 '08 #6
docdiesel
297 Expert 100+
Hi,

try the following:

Expand|Select|Wrap|Line Numbers
  1. echo "test" | ssh youruser@rmtsystem "cat >/tmp/test.txt"
and replace youruser@rmtsystem with appropriate username and servername. This line should ask for youruser's password and afterwards a file /tmp/test.txt on rmtsystem should contain the text "test". Does this work at your site?

Regards,

Bernd
May 29 '08 #7
gupta24
11
sorry not working

still in critical please help....................


Hi,

try the following:

Expand|Select|Wrap|Line Numbers
  1. echo "test" | ssh youruser@rmtsystem "cat >/tmp/test.txt"
and replace youruser@rmtsystem with appropriate username and servername. This line should ask for youruser's password and afterwards a file /tmp/test.txt on rmtsystem should contain the text "test". Does this work at your site?

Regards,

Bernd
Jun 3 '08 #8
docdiesel
297 Expert 100+
Hi,

sorry not working
is a very detailed answer. What error message did the command display, if any? Btw., are you sure there's ssh software installed on clients and servers?

To enable anybody to help you any further you've got to give more information, especially about your environment (operating system(s), shell(s) used, ...).

Regards,

Bernd
Jun 6 '08 #9

Sign in to post your reply or Sign up for a free account.

Similar topics

121
by: typingcat | last post by:
First of all, I'm an Asian and I need to input Japanese, Korean and so on. I've tried many PHP IDEs today, but almost non of them supported Unicode (UTF-8) file. I've found that the only Unicode...
4
by: George Lake | last post by:
Hi, I need to run a few commands from the shell and display the output via ASP (VB) Any ideas?
2
by: azmiza | last post by:
Hi everybody, I need your help. I want to view my sql database and its work very well which is display in my web browser but once I want to press button yes, its not working, I check the...
9
by: sohan | last post by:
Hi, I want to know how to connect and execute a db2 query from inside a UNIX shell script. Details: We have a unix shell script. We need to execute multiple db2 sql queries from this shell...
3
by: Siong.Ong | last post by:
Dear all, my PHP aims to update a MySQL database by selecting record one by one and modify then save. Here are my PHP, but I found that it doesnt work as it supposed to be, for example, when...
9
by: madhu3437 | last post by:
help ,please using shell script i want know the all process are running or not in a particular path. the result will shown in web page (html). process name = running ( server is running)...
1
by: =?Utf-8?B?Sm9obkJhdGVz?= | last post by:
Problem: I need to backup and clear the security event log. I have this working via a vbsscript which I will post below. However while I can use this script manually it is not user friendly and...
7
by: Samuel A. Falvo II | last post by:
I have a shell script script.sh that launches a Java process in the background using the &-operator, like so: #!/bin/bash java ... arguments here ... & In my Python code, I want to invoke...
2
jhoborg
by: jhoborg | last post by:
Hello all, So I'm having trouble using sendmail in a CGI script as the topic title says. Here's what I'm trying to accomplish: User fills out a form, submits it, my CGI script receives this...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.