Running Multiple REBOL/IOS Servers
Document Version 1.0 IOS Version 1.0
Contents:
1. Overview
2. Modify the CGI Proxy
3. Copy the New Proxy to CGI-Bin
4. Verify Proxy with a Web Browser
5. Modify the serve/Locations.r File
6. Start Your IOS Server
7. Start an IOS Client
8. If IOS Fails to Start
9. Other Documents
1. Overview
This document describes how to run multiple IOS server instances from a
single web server. The process is easy to perform, even if you are new
to the REBOL/IOS system.
Although it is not required that you use virtual web servers for running
multiple IOS servers, you should consider doing so if you think that you
might move one or more of the IOS servers to a different server host in
the future.
| IOS License Required | |
You must purchase additional IOS licenses to run multiple IOS servers.
Each IOS server must be separately licensed from REBOL Technologies.
|
2. Modify the CGI Proxy
REBOL/IOS uses a "CGI proxy" to route IOS connections from your web
server to your IOS server. (See the
REBOL/IOS Administrator's Guide
for details.)
As part of the REBOL/IOS distribution package, the source code for the
CGI proxy is provided in the proxy/ directory as rebolproxy.c.
You can easily modify the CGI proxy to redirect IOS connections to a
different IOS server (that is on the same system as the web server or on
a different system in your network).
For example, as the default, the cgi-proxy program connects to IOS on
port 2997. To add a second IOS server, you must create a second
cgi-proxy and use a different port number, such as 45000.
An easy way to change the CGI proxy on Linux and Unix systems is to edit
the make-proxy file to change the PORT number and the FILE name. It is a
good idea to use a filename that includes part of the IOS name. For
example, if the IOS is called Foo, then call the proxy something like
fooproxy.
PORT="45000"
FILE="fooproxy"
|
Note that the file name used here must be the same as that used in
the CGI URL path in your IOS client. See below.
3. Copy the New Proxy to CGI-Bin
If you run the make-proxy script, it will try to copy the output to your
cgi-bin. Of course, this depends on your server configuration. If it
fails to copy, then simply manually copy it to your cgi-bin location.
Be sure to set the correct permissions for the program to be executed.
cp fooproxy web/cgi-bin/foo-proxy
chmod 755 web/cgi-bin/foo-proxy
|
If you are using Windows, a similar procedure will be required.
4. Verify Proxy with a Web Browser
You can now use a web browser to check that the proxy is working
correctly:
http://www.example.com/cgi-bin/fooproxy
|
You should see the normal REBOL proxy response be returned. Note that
you do not need to have the IOS server running to see this response.
If you see a web server error, then you made a mistake in either the
name of the file, or the permissions for the file. Verify.
5. Modify the serve/Locations.r File
In your IOS /serve directory, edit your locations.r file to use the same
proxy port number that you used above.
This must be the same port number, or connections will not be
made.
6. Start Your IOS Server
When you restart your IOS server, you will see the startup message
indicate the PORT that is being used for connections (also sent to the
serve-log.txt file). It should indicate the PORT number that you
specified in locations.r.
| Important | |
Be sure to start IOS as the same user it normally runs as. If you start
it as ROOT, you might write out files IOS files owned as ROOT that will
cause problems later.
|
7. Start an IOS Client
Start an IOS client that uses the new CGI proxy in the IOS URL. It
should connect and start downloading the IOS system files, as it does
normally.
If you want to manually test the new IOS server, and your IOS client has
the correct encryption keys, see the Multiple
IOS Server Access document.
8. If IOS Fails to Start
If the IOS client fails, double check that the cgi proxy program
is running on the server (use a web browser to check it), and that
the IOS server is running. Check the server's log file for error
messages.
If those are correct, open the servers.r file on the client, and verify
that the entry for the IOS server uses the correct cgi proxy URL path
for your server.
9. Other Documents
See also Multiple IOS Server Access and
REBOL/IOS Administrator's Guide
for more information.
| | REBOL/MakeDoc 2.0 | REBOL is a registered trademark of REBOL Technologies Copyright 2004 REBOL Technologies | 10-Sep-2004 |
|