Technical article 104797

How to use scohttp(ADM) as a World Wide Web server.

OpenServer 5.0.0

Written · Last revised

Problem

How do I use the SCO OpenServer Release 5.0 documentation server as a World Wide Web httpd server?

Solution

To use the SCO OpenServer Release 5 online documentation
server, scohttpd, as a World Wide Web (WWW) httpd server,
set up a second scohttpd.
The scohttpd documentation server normally accepts
requests on port 457.  Because the standard WWW httpd
port is port 80, configure the second scohttpd to use
port 80.

To set up a second scohttpd server on port 80:

1. If scohttp is not already installed on your system, it must be installed. To determine whether scohttp is installed on your system, enter this command:

customquery ListPackages SCO:Unix:SCOHTTPD

If this command returns a line similar to the following, scohttp is installed:

SCO:Unix:SCOHTTPD::5.0.0Ae

Otherwise scohttp is not installed on your system. To install it, see the "Installing scohttp on your system" section in the documentation.

2. Decide on a location for your publishing tree
   and create a directory for it.  For example:
# mkdir /u/myweb

3. Create a file called index.html in the root of your publishing tree (for example, /u/myweb/index.html). This file will be the "home page" for your Web site. For testing purposes, you can put any text in this file (for example, "Testing 1 2 3!").

4. As root, stop scohttp by entering:

# scohttp stop

5. Copy the scohttp server files by entering these commands:

# mkdir /var/scohttp80
# cd /var/scohttp
# ln scohttpd /var/scohttp80/scohttpd80
# cp -r conf icons /var/scohttp80
# cd /var/scohttp80
# mkdir cgi-bin logs
# ln -s /u/myweb htdocs

(Replace /u/myweb with the location of your publishing tree.)

6. Change to the conf directory for the new server.

# cd /var/scohttp80/conf

7. Edit scohttpd.conf and change the lines that follow.

Change:
Port 457
To:
Port 80
Change: (reformatted from original to fit document)
# Warning:  If this changes then the man/scohelp
# configuration needs to change as well.
To:
# This scohelp socket file must be present and
# distinct from that used by scohelp and man
# to communicate with scohttp
Change:
SocketFile /usr/tmp/scohelp.socket
To:
SocketFile /usr/tmp/scohttp80.socket
Change:
ServerRoot /var/scohttp
To:
ServerRoot /var/scohttp80
Change:
PidFile logs/scohttpd.pid
To:
PidFile logs/scohttpd80.pid

8. Edit access.conf and change the lines that follow.

Change:
<Directory /var/scohttp/cgi-bin>
To:
<Directory /var/scohttp80/cgi-bin>
Change:
<Directory /usr/lib/scohelp>
To:
<Directory /var/scohttp80/htdocs>

9. Edit srm.conf and change the lines that follow.

Change:
DocumentRoot /usr/lib/scohelp
To:
DocumentRoot /var/scohttp80/htdocs
Change:
DirectoryIndex CONTENTS.html
To:
DirectoryIndex index.html
Change:
Alias /icons/ /var/scohttp/icons/
To:
Alias /icons/ /var/scohttp80/icons/
Change:
ScriptAlias /cgi-bin/ /var/scohttp/cgi-bin/
To:
ScriptAlias /cgi-bin/ /var/scohttp80/cgi-bin/

NOTE: You do not need to change the mime.types file.

10. If you have access to the Internet:

a. Download the new http start/stop script via this URL:

http://www.sco.com/Technology/ga/etc/scohttp80
b. Save the script as /etc/scohttp80.
c. Enter:
chmod a+rx /etc/scohttp80
scohttp80 enable
d. Skip to step 12.  The scohttp80 package will
   create the appropriate links that will make
   the P93scohttp80 file unnecessary.

11. If you are unable to download the new http script:

a. Enter:
# cp /etc/scohttp /etc/scohttp80
# FILE=/etc/scohttp80
b. Enter these sed(C) commands:
# sed -e '
     s/scohttpd/PLACEHOLDER/g
     s/scohttp/scohttp80/g
     ' $FILE > /tmp/httpedit
# sed -e '
     s/PLACEHOLDER/scohttpd80/g
     s/Scohttp/Scohttp80/g
     ' /tmp/httpedit > $FILE

These sed(C) commands make the following changes to /etc/scohttp80:

changes all occurrences of "scohttpd" to
"PLACEHOLDER" (temporarily)
changes all occurrences of "scohttp" to
"scohttp80"
changes all occurrences of "PLACEHOLDER" to
"scohttpd80"
changes all occurrences of "Scohttp" to
"Scohttp80"
c. Enter the following:
# cp /etc/rc2.d/P93scohttp \
     /etc/rc2.d/P93scohttp80
# FILE=/etc/rc2.d/P93scohttp80

d. Enter the sed(C) commands from step 11b.

These sed commands make the same changes to the /etc/rc2.d/P93scohttp80 file.

e. Delete the first occurrence (in the start routine) of the following line in /etc/rc2.d/P93scohttp80:

# [ $# -ge 1 ] && kill -15 $KILL_PID
12. Start the scohttp servers:
# scohttp start
# scohttp80 start

13. Test the new scohttpd80 daemon by using scohelp(XC) or your WWW browser to access the URL for your machine. For example, the URL is either:

http://mysystem.mycompany.com
or
http://mysystem.mycompany.com/index.html
(Replace mysystem.mycompany.com with your system name.)

Accessing this URL should display your home page.

When you can display your home page using the URL, you have successfully configured your second scohttpd server on port 80.

Installing scohttp on your system:
==================================
To install scohttp:

1. Insert your SCO OpenServer media into the drive and start the custom(ADM) application.

2. Select Install New from the Software menu and indicate your media type.

3. Select the SCO OpenServer Enterprise System package, then select Partial.

4. Double-click on the following Enterprise System packages:

SCO OpenServer Enterprise System Unix SCO OpenServer Enterprise System Utilities SCO OpenServer Enterprise Optional Utilities

5. Select SCOHTTPD Client.
6. Click on Install.

Scohttp is now installed on your system.

See also

TA107564, "Information about WWW browsers and servers for SCO products."

The document available at the URL:
http://www.sco.com/Technology/internet/servers/scohttp80.html

From the Xinuos technical article database, record 104797. Reproduced with permission. The original is at www.sco.com/ta/104797, which is reachable but blocked from search engines. Xinuos marks this article against a retired product line. That refers to the product’s lifecycle, not to whether the advice still works — plenty of it still applies to running systems.

Next step

Need this fixed rather than explained?

Tell us the release, what the system runs and what it is doing. We will reply by email with what we would do next.

  • You deal with the people who do the work
  • No obligation, and no upgrade required before we will help
  • We tell you plainly if something is not worth doing

Send an enquiry

We reply by email. If a server is down, say so in the first line. You can also write to help@scoexpert.com.