Solved

Executing remote CGI's

Posted on 1998-11-05
2
195 Views
Last Modified: 2013-12-25
Hi,
I have to update 5 sites daily with the same info:
Max temp, min temp. Dollar, etc. etc.
I wrote 6 little program in C which print out a string.
If I call these scripts locally there is no prob.
I use <!--#exec cgi="/cgi-bin/daily/dollar" -->
and get "460.52"

Can they be executed from a remote server? If I try to execute them as
<!--#exec cgi="http://www.santiago.cl/cgi-bin/daily/dollar" -->
I get:  [an error occurred while processing this directive]
If I go directly to http://www.santiago.cl/cgi-bin/daily/dollar I also get the number expected.

The servers from which I am trying to execute them from are NT and unix.

Is there any way that I can execute these remote CGi's from within the HTML/ASP files?

Thanks for your help.

Marcelo
0
Comment
Question by:sinner052397
2 Comments
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 1829444
You will need to use a socket connection if you want a server program to call them. This will not be HTML (or ASP - unless somebody has a socket interface for ASP - one never knows) Have a look around for this in your favorite language (thre are tons of socket examples out there...)

Michel
0
 

Accepted Solution

by:
Eck earned 100 total points
ID: 1829445
if files (.html, or otherwise) have to be update on th 5 'clone' servers A quick & dirty way to do this is with rcp(1).
Just create the 'master .html'  then do the shell command:

'rcp master.html login@myhost1.com:/webdir'

for each of the 5 hosts you have to update.

Dirty, kinda nsucure and ulgy... but quick:]


0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Batch, VBS, and scripts in general are incredibly useful for repetitive tasks.  Some tasks can take a while to complete and it can be annoying to check back only to discover that your script finished 5 minutes ago.  Some scripts may complete nearly …
This article is meant to give a basic understanding of how to use R Sweave as a way to merge LaTeX and R code seamlessly into one presentable document.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
The viewer will learn how to count occurrences of each item in an array.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now